-
Install the the
shadowsocks-libev
package from apt repository.sudo apt update sudo apt install shadowsocks-libev
-
Save
ss.json
as/etc/shadowsocks-libev/config.json
. -
Replace server_port and password in
ss.json
with your own choices. -
Restart the
shadowsocks-libev
service.sudo systemctl restart shadowsocks-libev sudo systemctl status shadowsocks-libev
-
Install shadowsocks with pip.
sudo apt update sudo apt install python-pip sudo pip install shadowsocks
-
Save
ss.json
under/etc/shadowsocks/
. -
Replace server_port and password in
ss.json
with your own choices. -
Save
ssserver.service
under/usr/lib/systemd/system/
-
Enable the systemd service.
sudo systemctl enable ssserver sudo systemctl start ssserver sudo systemctl status ssserver
-
Install shadowsocks with pip.
sudo apt-get update sudo apt-get install python-pip sudo pip install shadowsocks
-
Save
ss.json
,start.sh
,stop.sh
under/etc/shadowsocks/
. -
Replace server_port and password in
ss.json
with your own choices. -
Put the following in
/etc/rc.local
to start ssserver upon server start.# Start shadowsocks server /etc/shadowsocks/start.sh
This will install linux kernel 4.9 and enable TCP BBR congestion control algorithm to improve network bandwidth utilization (10x improvement is not uncommon).
URL=http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.9.9/linux-image-4.9.9-040909-generic_4.9.9-040909.201702090333_amd64.deb
wget $URL
sudo dpkg -i $(basename $URL)
sudo reboot
echo "net.core.default_qdisc=fq" | sudo tee -a /etc/sysctl.conf
echo "net.ipv4.tcp_congestion_control=bbr" | sudo tee -a /etc/sysctl.conf
sudo sysctl -p
sysctl net.ipv4.tcp_available_congestion_control
sysctl net.ipv4.tcp_congestion_control
lsmod | grep bbr