Boot to any [Manjaro] live GUI disk. Use manjaro-chroot 1. Start by identifying the partition where your Manjaro installation controlling the active Grub menu resides and needs repairing. If you are in Graphical mode you can use an application called GPartEd , which should be in Menu > System > GPartEd. This will provide a simple visual illustration of the partitions on your hard drive(s). To do the same thing from terminal or TTY you can use this command lsblk -f 2. manjaro-chroot is a tool to easily setup a functional chroot into an installed Linux installation from a live boot of a Manjaro Installation Media. To setup the chroot use the command sudo manjaro-chroot -a You will be presented with a terminal. Wait until it shows a list with the available system partitions on your computer and choose the one you want to repair. 1.) First of all check the partition for the ESP (EFI System Partition). An ESP is a fat32 partition and contains .efi ...
Connect to the Server
Disable root login
Use nano to change PermitRootLogin to no. Ctrl+O to save and Ctrl+X to quit afterward.
It’s better, less hassle and a lot safer. You should use it.
Install libtorrent
Install rtorrent
Create new user to run rtorrent and required folders
For rtorrent config, you can copy the default one and mess around. It’s simple and straight forward. I won’t go into details here.
or use this .rtorrent.rc
change 7.1 to 7.0 or compatible
Check php.ini location
Change Ownership of folders
Edit the file using your favorite text editor:
Make the following changes:
Then, restart the PHP-FPM service:
Install Nginx on Ubuntu 16.04
Installing Nginx on Ubuntu VPS is very easy. Run the following command to install it:
Create Nginx virtual server block for your domain name:
Paste the following content:
or rtorrent tested:
Of course, you should replace example.com with your actual domain name. Save and close the file. To enable the server block in Nginx you need to create a symbolic link to site-enabled. Use the following command to create a symbolic link:
Check if there are errors with the configuration:
If the syntax is OK and there are no errors you can restart Nginx.
Enable Nginx and PHP-FPM on system boot:
Download rutorrent
Inside, at the bottom of the file, add a ServerName directive, pointing to your primary domain name. If you do not have a domain name associated with your server, you can use your server's public IP address:
Since we added the global ServerName directive, all you should see is:
Download rutorrent
Theme Black:
And next?
Select it in your ruTorrent's settings...
ssh root@SERVER_IP_ADDRESS
adduser USER_NAME
gpasswd -a USER_NAME sudo
Disable root login
Use nano to change PermitRootLogin to no. Ctrl+O to save and Ctrl+X to quit afterward.
nano /etc/ssh/sshd_configSetup key authentication
service ssh restart
It’s better, less hassle and a lot safer. You should use it.
# at your local machine: gen key and upload it to your vpsSetup rtorrent
ssh-keygen -t rsa
cat ~/.ssh/id_rsa.pub | ssh USER_NAME@YOUR_SERVER_IP_ADDRESS 'cat >> .ssh/authorized_keys'
# install libraries required to build rtorrent
sudo apt-get update
sudo apt-get install subversion build-essential automake libtool libcppunit-dev libcurl3-dev libsigc++-2.0-dev unzip unrar-free curl libncurses-dev libxml2-dev
# download source and install
cd ~
mkdir src
cd src
svn checkout https://svn.code.sf.net/p/xmlrpc-c/code/super_stable xmlrpc
cd xmlrpc
./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server --disable-cplusplus
make
sudo make install
Install libtorrent
cd ~
wget http://rtorrent.net/downloads/libtorrent-0.13.4.tar.gz
tar xvf libtorrent-0.13.4.tar.gz
cd libtorrent-0.13.4
./autogen.sh
sudo apt-get install libssl-dev
./configure --prefix=/usr
make
sudo make install
Install rtorrent
cd ~ # back to home
wget http://rtorrent.net/downloads/rtorrent-0.9.4.tar.gz
tar xvf rtorrent-0.9.4.tar.gz
cd rtorrent-0.9.4
./autogen.sh
./configure --prefix=/usr --with-xmlrpc-c
make
sudo make install
sudo ldconfig
Create new user to run rtorrent and required folders
useradd -d /home/shah/ shah
mkdir /home/shah
mkdir /home/shah/downloads
mkdir /home/shah//downloads/watch
mkdir /home/shah//downloads/completed
mkdir /home/shah/.session
mkdir /home/shah/watch
mkdir /home/shah/.sockets
touch /home/shah/.sockets/rpc-socket
nano /home/shah/.rtorrent.rc
# update permission
sudo chown -R www-data:www-data /usr/share/nginx/html
or
sudo chown -R www-data:www-data /var/www/html
For rtorrent config, you can copy the default one and mess around. It’s simple and straight forward. I won’t go into details here.
cp /usr/share/doc/rtorrent/rtorrent.rc ~/.rtorrent.rc
or use this .rtorrent.rc
# enable/modify the options as needed. Remember to
# uncomment the options you wish to enable.
scgi_port = 127.0.0.1:5000
# Maximum and minimum number of peers to connect to per torrent.
#
#throttle.min_peers.normal.set = 40
#throttle.max_peers.normal.set = 100
# Same as above but for seeding completed torrents (-1 = same as downloading)
#throttle.min_peers.seed.set = 10
#throttle.max_peers.seed.set = 50
# Maximum number of simultanious uploads per torrent.
#
#throttle.max_uploads.set = 15
# Global upload and download rate in KiB. "0" for unlimited.
#
#throttle.global_down.max_rate.set_kb = 0
#throttle.global_up.max_rate.set_kb = 0
# Default directory to save the downloaded torrents.
#
directory.default.set = ~/downloads/completed
# Default session directory. Make sure you don't run multiple instance
# of rtorrent using the same session directory. Perhaps using a
# relative path?
#
session.path.set = ~/.session
# Watch a directory for new torrents, and stop those that have been
# deleted.
#
schedule2 = watch_directory,5,5,load.start=~/downloads/watch/*.torrent
#schedule2 = untied_directory,5,5,stop_untied=
# Close torrents when diskspace is low.
#
schedule2 = low_diskspace,5,60,close_low_diskspace=100M
# The ip address reported to the tracker.
#
#network.local_address.set = 127.0.0.1
#network.local_address.set = rakshasa.no
# The ip address the listening socket and outgoing connections is
# bound to.
#
#network.bind_address.set = 127.0.0.1
#network.bind_address.set = rakshasa.no
# Port range to use for listening.
#
#network.port_range.set = 6890-6999
# Start opening ports at a random position within the port range.
#
#network.port_random.set = no
# Check hash for finished torrents. Might be usefull until the bug is
# fixed that causes lack of diskspace not to be properly reported.
#
#pieces.hash.on_completion.set = no
# Set whether the client should try to connect to UDP trackers.
#
#trackers.use_udp.set = yes
# Alternative calls to bind and ip that should handle dynamic ip's.
#
#schedule2 = ip_tick,0,1800,ip=rakshasa
#schedule2 = bind_tick,0,1800,bind=rakshasa
# Encryption options, set to none (default) or any combination of the following:
# allow_incoming, try_outgoing, require, require_RC4, enable_retry, prefer_plaintext
#
# The example value allows incoming encrypted connections, starts unencrypted
# outgoing connections but retries with encryption if they fail, preferring
# plaintext to RC4 encryption after the encrypted handshake
#
# protocol.encryption.set = allow_incoming,enable_retry,prefer_plaintext
# Enable DHT support for trackerless torrents or when all trackers are down.
# May be set to "disable" (completely disable DHT), "off" (do not start DHT),
# "auto" (start and stop DHT as needed), or "on" (start DHT immediately).
# The default is "off". For DHT to work, a session directory must be defined.
#
# dht.mode.set = auto
# UDP port to use for DHT.
#
#dht.port.set = 6881
# Enable peer exchange (for torrents not marked private)
#
#protocol.pex.set = yes
# Set downlad list layout style. ("full", "compact")
#
#ui.torrent_list.layout.set = "full"
Now Install Webserver:
Nginx
sudo service apache2 stopif not works use latest version
sudo apt-get install nginx php5-fpm php5-cli
change 7.1 to 7.0 or compatible
sudo apt-get install php7.1
sudo apt-get install php7.1 php7.1-cli php7.1-common php7.1-json php7.1-opcache php7.1-mysql php7.1-mbstring php7.1-mcrypt php7.1-zip php7.1-fpm
Check php.ini location
php --ini |grep Loaded
Loaded Configuration File: /etc/php/7.1/cli/php.ini
Change Ownership of folders
sudo chown -R www-data:www-data /usr/share/nginx/html
or
sudo chown -R www-data:www-data /var/www/html
Edit the file using your favorite text editor:
sudo nano /etc/php/7.1/cli/php.ini
Make the following changes:
cgi.fix_pathinfo=0
Then, restart the PHP-FPM service:
sudo systemctl restart php7.1-fpm.service
Install Nginx on Ubuntu 16.04
Installing Nginx on Ubuntu VPS is very easy. Run the following command to install it:
sudo apt-get install nginx
Create Nginx virtual server block for your domain name:
sudo nano /etc/nginx/sites-available/example.com
Paste the following content:
server {
listen 80;
server_name example.com www.example.com;
root /var/www/example.com;
index index.php;
location / {
try_files $uri $uri/ =404;
}
location ~ \.php$ {
fastcgi_pass unix:/run/php/php7.1-fpm.sock;
include snippets/fastcgi-php.conf;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
location ~ /\.ht {
deny all;
}
}
or rtorrent tested:
server {
listen 80;
listen [::]:80 default_server ipv6only=on; ## listen for ipv6
root /usr/share/nginx/html;
index index.php index.html index.htm;
server_name localhost;
location / {
try_files $uri $uri/ /index.html;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
# php5-fpm
location ~ \.php$ {
try_files $uri =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
# With php5-fpm:
fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
#fastcgi_pass unix:/run/php/php-fpm7.0.sock;
fastcgi_index index.php;
#include fastcgi_params;
include fastcgi.conf;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
}
Of course, you should replace example.com with your actual domain name. Save and close the file. To enable the server block in Nginx you need to create a symbolic link to site-enabled. Use the following command to create a symbolic link:
sudo ln -s /etc/nginx/sites-available/example.com /etc/nginx/sites-enabled/example.com
Check if there are errors with the configuration:
sudo nginx -t
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
If the syntax is OK and there are no errors you can restart Nginx.
sudo systemctl restart nginx.service
Enable Nginx and PHP-FPM on system boot:
sudo systemctl enable nginx.service
sudo systemctl enable php7.1-fpm.service
or
sudo systemctl enable php7.0-fpm.service
Download rutorrent
cd /usr/share/nginx/html
svn checkout http://rutorrent.googlecode.com/svn/trunk/rutorrent
svn checkout http://rutorrent.googlecode.com/svn/trunk/plugins
rm -r rutorrent/plugins
mv plugins rutorrent/
Apache:
sudo apt-get update
sudo apt-get install apache2
sudo apache2ctl configtest
OutputOpen up the main configuration file with your text edit:
AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message
Syntax OK
sudo nano /etc/apache2/apache2.conf
Inside, at the bottom of the file, add a ServerName directive, pointing to your primary domain name. If you do not have a domain name associated with your server, you can use your server's public IP address:
. . .
ServerName server_domain_or_IP
sudo apache2ctl configtest
Since we added the global ServerName directive, all you should see is:
Output
Syntax OK
sudo systemctl restart apache2
Install PHP Modules:
sudo apt-get install php libapache2-mod-php php-mcrypt php-mysql
sudo systemctl restart apache2
Download rutorrent
cd /usr/share/nginx/html
svn checkout http://rutorrent.googlecode.com/svn/trunk/rutorrent
svn checkout http://rutorrent.googlecode.com/svn/trunk/plugins
rm -r rutorrent/plugins
mv plugins rutorrent/
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cd /var/www/html
git clone https://github.com/Novik/ruTorrent.git
sudo chown -R www-data:www-data /var/www/html
Theme Black:
cd /var/www/html/ruTorrent/plugins/theme/themes
git clone https://github.com/Micdu70/QuickBox-Dark.git
chown -R www-data:www-data QuickBox-Dark
And next?
Select it in your ruTorrent's settings...
Comments
Post a Comment