1、一键安装 shadowsocks-go 版
wget –no-check-certificate https://tangyuecan.com/shadowsocks-go.sh
chmod +x shadowsocks-go.sh
./shadowsocks-go.sh 2>&1 | tee shadowsocks-go.log
2、开始配置Shadowsock相关的密码、端口号、加密方式
#############################################################
# One click Install Shadowsocks-Python server #
# Intro: https://tangyuecan.com #
# Author: tangyuecan #
# Github: https://github.com/shadowsocks/shadowsocks-go #
#############################################################
3、在上访提示中输入你的密码6666
Please input password for shadowsocks-go
(Default password: teddysun.com):6666
4、在上方提示中输入你的端口号,注意端口号最好想个比较特殊的
Please input port for shadowsocks-go [1-65535]
(Default port: 8989):8888
5、在上方选择你的加密方式,通常用默认的,如果用默认可以直接回车
Please select stream cipher for shadowsocks-python:
1) aes-256-gcm
2) aes-192-gcm
3) aes-128-gcm
4) aes-256-ctr
5) aes-192-ctr
6) aes-128-ctr
7) aes-256-cfb
8) aes-192-cfb
9) aes-128-cfb
10) camellia-128-cfb
11) camellia-192-cfb
12) camellia-256-cfb
13) chacha20-ietf-poly1305
14) chacha20-ietf
15) chacha20
16) rc4-md5
Which cipher you'd select(Default: aes-256-gcm):
6、然后在本地下载并安装(影梭)Shadowsock的win版本,在手机上也有对应的Android和IOS版本,可自行下载安装, 配置时候只要输入IP、端口号、密码即可
Windows
https://github.com/shadowsocks/shadowsocks-windows/releases
Mac OS X
https://github.com/shadowsocks/ShadowsocksX-NG/releases
linux
https://github.com/shadowsocks/shadowsocks-qt5/wiki/Installation
https://github.com/shadowsocks/shadowsocks-qt5/releases
iOS
https://itunes.apple.com/app/apple-store/id1070901416?pt=2305194&ct=shadowsocks.org&mt=8
https://github.com/shadowsocks/shadowsocks-iOS/releases
https://play.google.com/store/apps/details?id=com.github.shadowsocks
https://github.com/shadowsocks/shadowsocks-android/releases
7、Centos 配置防火墙端口
# 开启端口号8888
$ firewall-cmd --permanent --zone=public --add-port=8888/tcp
$ firewall-cmd --reload
8、添加systemctl服务
vi shadowsocks.service
[Unit]
Description=shadowsocks
After=network.target
[Service]
Type=forking
ExecStart=/etc/init.d/shadowsocks start
ExecReload=/etc/init.d/shadowsocks restart
ExecStop=/etc/init.d/shadowsocks stop
PrivateTmp=true
[Install]
WantedBy=multi-user.target
9、常用命令
# start | stop | restart | status
# 重启
/etc/init.d/shadowsocks restart
#卸载
./shadowsocks.sh uninstall
#重载系统服务:
systemctl daemon-reload
#设置开机启动:
systemctl enable shadowsocks.service
#启动服务:
systemctl start shadowsocks.service
#停止服务:
systemctl stop shadowsocks.service
#重启服务:
systemctl reload shadowsocks.service
[为了能够提高上网速度,YouTube从480 体验为1080。我们接下来进行安装加速软件(速锐、BBR两者选其一,不可共存)。]
BBR加速特别简单,复制下面脚本代码即可。 谷歌BBR加速脚本:
第一个指令:wget --no-check-certificate https://github.com/teddysun/across/raw/master/bbr.sh
第二个指令:chmod +x bbr.sh
第三个指令:./bbr.sh
重新连接后,输入 lsmod | grep bbr 查看BBR是否启动,可以看到已经启动了。