How to How to setup Shadowsocks on your Ubuntu/Debian server
Your school or company network may block the access to a few specific websites. To solve this problem, I'd highly recommend Shadowsocks, since it is the easiest proxy tool I've ever found, and it's FREE (of course iff you have your own server running).
First, ssh to your server, and make sure you have Python and pip installed. If you have Python but not pip, install it using the following command
$ sudo apt-get install python3-pip
Then, install Shadowsocks using pip
$ sudo pip install shadowsocks
No shadowsocks.json ,create a file .
Create configuration file at /etc/shadowsocks.json, with the following content,
{
"server":"[Ip Address]",
"server_port":443,
"local_port":0,
"password":"[password]",
"timeout":600,
"method":"aes-256-cfb"
}
Don't forget to change the [server ip address] and [password] in the block above.
Finally, we're ready to start the shadowsocks server that runs in the background by
$ sudo ssserver -c /etc/shadowsocks.json -d start
$ nohup ssserver -c /etc/shadowsocks.json -d start
If you wish to stop the Shadowsocks server, do this
$ sudo ssserver -c /etc/shadowsocks.json -d stop
BBR
安装Google BBR算法
使用root登录,逐行执行以下命令。
使用root用户登录,运行以下命令:
wget --no-check-certificate https://github.com/teddysun/across/raw/master/bbr.sh
chmod +x bbr.sh
./bbr.sh
安装完成后,脚本会提示需要重启 VPS,输入 y 并回车后重启。
重启完成后,进入 VPS,验证一下是否成功安装最新内核并开启 TCP BBR,输入以下命令:
uname -r
查看内核版本,含有 4.11 就表示 OK 了
sysctl net.ipv4.tcp_available_congestion_control
返回值一般为:
net.ipv4.tcp_available_congestion_control = bbr cubic reno
sysctl net.ipv4.tcp_congestion_control
返回值一般为:
net.ipv4.tcp_congestion_control = bbr
sysctl net.core.default_qdisc
返回值一般为:
net.core.default_qdisc = fq
lsmod | grep bbr
返回值有 tcp_bbr 模块即说明bbr已启动。
网友评论