搭建vpn

来源:互联网 发布:淘宝客服是销售吗 编辑:程序博客网 时间:2024/05/06 16:56

参考文章:http://blog.csdn.net/noahsun1024/article/details/52206369

  1. apt-get install python-pip  
  2. pip install shadowsocks  

vi /etc/shadowsocks.json


  1. {  
  2.     "server":"0.0.0.0",  
  3.     "server_port":8388,  
  4.     "local_address""127.0.0.1",  
  5.     "local_port":1080,  
  6.     "password":"mypassword",  
  7.     "timeout":300,  
  8.     "method":"aes-256-cfb",  
  9.     "fast_open"false  
  10. }  

多个账号:

  1. {  
  2.     "server":"0.0.0.0",  
  3.     "port_password":{  
  4.      "8381":"xxxxxxx",  
  5.      "8382":"xxxxxxx",  
  6.      "8383":"xxxxxxx",  
  7.      "8384":"xxxxxxx"  
  8.      },  
  9.     "timeout":300,  
  10.     "method":"aes-256-cfb",  
  11.     "fast_open": false  
  12. }  

  1. ssserver -c /etc/shadowsocks.json  

后台启动:


  1. ssserver -c /etc/shadowsocks.json -d start  
  2. ssserver -c /etc/shadowsocks.json -d stop  


最重要的一步,还需要将端口打开

iptables -A INPUT -p tcp --dport 10080 -j ACCEPT