请问一下怎么开启多用户/How to open multi-user?
onlyJinx opened this issue · 8 comments
Please answer these questions before submitting your issue. Thanks!
(Please mention that if the issue you filed is solved, you may wish to close it by yourself. Thanks again.)
(PS, you can remove 3 lines above, including this one, before post your issue.)
What version of shadowsocks-libev are you using?
latest version
What operating system are you using?
centos7
What did you do?
open multi-user
What did you expect to see?
What did you see instead?
What is your config in detail (with all sensitive info masked)?
{
"server":"0.0.0.0",
"server_port":443,
"local_port":1080,
"password":"passm",
"timeout":60,
"method":"chacha20-ietf-poly1305",
"plugin":"obfs-server",
"plugin_opts":"obfs=http"
}
怎么开启多用户?我看到是用不同的配置文和的PID来开启的,格式为
ss-server -c config1.json -f pid1
ss-server -c config2.json -f pid2
ss-server -c config3.json -f pid3
现在有个疑问,这个pid是什么?怎么用 ?我Google了一下好像是一个文件,能具体说说怎么开启多用户吗?我是一个Linux新手!谢谢各位了。
You should use ss-manager to launch multiple ss-server process for listen to multiple ports.
example command line:
ss-manager -c /etc/shadowsocks-libev/manager.json --manager-address 127.0.0.1:8000 -u
manager.json
{
"port_password": {
"8001": "password1",
"8002": "password2",
"8003": "password3"
},
"timeout": 120,
"method": "chacha20-ietf-poly1305"
}
call 'man ss-manager' for details.
你好,我是小小白。有个问题想请教下。
前天刚入的Vultr的VPS,现在使用的是CentOs7最新系统,安装的是SS-libev一键安装,(https://github.com/iMeiji/shadowsocks_install/wiki/shadowsocks-libev-%E4%B8%80%E9%94%AE%E5%AE%89%E8%A3%85)
但是现在的问题是不知道怎么开多用户,有按照楼上的方法实验,还是不行。
输入
ss-manager -c /etc/shadowsocks-libev/manager.json --manager-address 127.0.0.1:8000 -u
manager.json
后显示如下
[root@vultr ~]# ss-manager -c /etc/shadowsocks-libev/manager.json --manager-address 127.0.0.1:8000 -u
2018-03-14 07:25:14 ERROR: Invalid config path.
[root@vultr ~]# manager.json
-bash: manager.json: command not found
不知道能否解答下问题
The ss-manager -c /etc/shadowsocks-libev/manager.json --manager-address 127.0.0.1:8000 -u manager.json
is a single command, so do not split it.
表示那个方法无效会提示 fast_open 必须是Bool 值,我索性改回去了。。。
Upstart for CentOS 6
cat > /etc/init/shadowsocks-manager.conf <<EOF
description "Shadowsocks Mult-User Upstart Script"
author "Shadowsocks-libev"
start on runlevel [2345]
stop on shutdown
respawn
script
exec ps -ef | grep ss > /var/log/shadowsocks-manager.log
exec ss-manager -c /etc/shadowsocks-libev/manager.json --manager-address 127.0.0.1:8000 -u 2>&1 >> /var/log/shadowsocks-manager.log
end script
pre-start script
echo "[date
] Shadowsocks Mult-User Starting" >> /var/log/shadowsocks-manager.log
end script
pre-stop script
rm /var/run/nodetest.pid
echo "[date
] Shadowsocks Mult-User Stopping" >> /var/log/shadowsocks-manager.log
end script
EOF
initctl reload-configuration
initctl start shadowsocks-manager
如何使用一个守护进程守护下面的命令呢?否则只要commd + c 停止使用manager,就不行了,无法长时间运行
ss-manager -c /etc/shadowsocks-libev/manager.json --manager-address 127.0.0.1:8000 -u
manager.json
如何使用一个守护进程守护下面的命令呢?否则只要commd + c 停止使用manager,就不行了,无法长时间运行
ss-manager -c /etc/shadowsocks-libev/manager.json --manager-address 127.0.0.1:8000 -u
manager.json
找到了,使用nohup
和 &
即可:
nohup ss-manager -c /etc/shadowsocks-libev/manager.json --manager-address 127.0.0.1:8000 -u manager.json &