# 安装shadowsocks
# Debian/Ubuntu
apt-get install python-pip
pip install shadowsocks
# CentOS
yum install -y python-setuptools
easy_install pip
pip install shadowsocks
# 创建配置文件
mkdir /etc/shadowsocks
vi /etc/shadowsocks/config.json
{
"server":"0.0.0.0",
"port_password":{
"8989":"qwer1234"
},
"timeout":300,
"method":"aes-256-cfb",
"fast_open":false
}
# 启动shadowsocks
ssserver -c /etc/shadowsocks/config.json -d start
# 开端口(视环境而定)
service iptables start/stop/restart/status
chkconfig iptables on/off
firewall-cmd --zone=public --add-port=8989/tcp --permanent
firewall-cmd --reload
# shadowsocks启动还可以直接使用命令带参数的方式启动
#-p 端口, -k 密码, -m 加密方式 -d 以守护进程模式运行start/stop/restart
ssserver -p 443 -k password -m aes-256-cfb --user nobody -d start
#另配置文件也可以这样写, 推荐直接使用命令带参数的方式运行吧
{
"server":"0.0.0.0",
"server_port":8388,
"local_port":1080,
"password":"123456",
"methos":"aes-256-cfb"
}