Last active
May 18, 2018 17:42
-
-
Save vizee/cc8432a654b1d9a7f53aa8896def7801 to your computer and use it in GitHub Desktop.
setup ss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if [ -z `lsmod | grep bbr` ]; then | |
modprobe tcp_bbr | |
echo "tcp_bbr" >> /etc/modules-load.d/modules.conf | |
fi | |
if [ -z `sysctl net.ipv4.tcp_congestion_control | grep bbr` ]; then | |
echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf | |
echo "net.ipv4.tcp_congestion_control=bbr" >> /etc/sysctl.conf | |
sysctl -p | |
fi | |
sysctl net.ipv4.tcp_available_congestion_control | |
sysctl net.ipv4.tcp_congestion_control |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pip install --upgrade pip | |
pip install setuptools | |
pip install git+https://github.com/shadowsocks/shadowsocks.git@master | |
echo '{ | |
"server":"0.0.0.0", | |
"server_port":8388, | |
"local_address": "127.0.0.1", | |
"local_port":1080, | |
"password":"mypassword", | |
"timeout":300, | |
"method":"aes-256-cfb", | |
"fast_open": false | |
}' > ss.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apt update | |
apt upgrade -y | |
apt install -y python-pip libsodium-dev | |
sed -i 's/#Port 22/Port 2222/' /etc/ssh/sshd_config | |
systemctl reload ssh.service |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
image_amd64="http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.15.13/linux-image-4.15.13-041513-generic_4.15.13-041513.201803250910_amd64.deb" | |
wget "$image_amd64" | |
dpkg -i linux-image-4.*.deb | |
apt autoremove | |
reboot |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment