debian 安装shadowsocks manyuser 后端
请先准备好mysql,phpmyadmin等工具,推荐oneinstack
apt-get install python-pip python-m2crypto git supervisor
pip install cymysql
git clone -b manyuser https://github.com/mengskysama/shadowsocks-rm.git
请在phpmyadmin上创建好数据库与相应的用户,并设置好权限。然后导入shadowsocks-rm/shadowsocks目录下的shadowsocks.sql到创建的数据库中
vi /shadowsocks-rm/shadowsocks/config.py
#Config
MYSQL_HOST = ‘127.0.0.1’ #这一行是服务器IP,127.0.0.1表示本机
MYSQL_PORT = 3306 #数据库端口号
MYSQL_USER = ‘ss’ #数据库用户名
MYSQL_PASS = ‘ss’ #数据库密码
MYSQL_DB = ‘shadowsocks’ #数据库名称
MANAGE_PASS = ‘ss233333333’
#if you want manage in other server you should set this value to global ip
MANAGE_BIND_IP = ‘127.0.0.1’
#make sure this port is idle
MANAGE_PORT = 23333
vi /etc/superviso/conf.d/shadowsocks.conf
添加如下内容:
[program:shadowsocks]
command=python /root/shadowsocks-rm/shadowsocks/servers.py
autorestart=true
user=root
vi /etc/profile
添加以下三行
ulimit -n 51200
ulimit -Sn 4096
ulimit -Hn 8192
同上面一样修改/etc/default/supervisor
启动supervisor
service supervisor start #启动
supervisorctl reload #重载
参与连接:http://www.cmsky.com/shadowsocks-manyuser-sspanel/