Ubuntu下配置Shadowsocks服务端

来源:互联网 发布:sql查询分析器在哪 编辑:程序博客网 时间:2024/06/05 07:34
1.安装python2.7以上版本:
    sudo apt-get install python

2.安装pip:
    sudo apt-get install python-gevent python-pip

3.安装shadowsocks:
    pip install shadowsocks

4.新建一个config.json,其他名字也可,位置随意。
    此处假设放在:/home/config.json

5.配置config.json:
    {
    "server":"服务器IP地址",
    "server_port":监听端口,
    "password":"你的密码",
    "method": 加密方式,有“bf-cfb”,“aes-256-cfb”,“des-cfb”,“rc4″,推荐用“aes-256-cfb”,
    "timeout":超时时间,单位秒
    "fast_open":是否使用TCP_FASTOPEN, true / false,不理解不要写
    "workers":worker的数量,不理解不要写
    }

    例子:
    {
    "server":"1.1.1.1",
    "server_port":54321,
    "password":"12345",
    "method": "aes-256-cfb",
    "timeout":600
    }

6.开启服务:

    前台运行:
    ssserver -c /home/config.json
    
    后台运行:
    ssserver -c /home/config.json -d start
    ssserver -c /home/config.json -d stop

0 0