shadowsocks / simple-obfs

A simple obfuscating tool (Deprecated)
GNU General Public License v3.0
2.37k stars 561 forks source link

obfs plugin service exit unexpectedly #160

Open YahangWu opened 6 years ago

YahangWu commented 6 years ago

shadowsocks-libev version 3.1.2

tried the solution in https://github.com/shadowsocks/shadowsocks-libev/issues/1139 and https://github.com/shadowsocks/shadowsocks-libev/issues/1166

neither of them work...

2018-01-12 12:02:09 INFO: using tcp fast open 2018-01-12 12:02:09 INFO: plugin "obfs-server" enabled 2018-01-12 12:02:09 INFO: initializing ciphers... chacha20-ietf-poly1305 2018-01-12 12:02:09 INFO: tcp server listening at 127.0.0.1:47005 2018-01-12 12:02:09 INFO: running from root user 2018-01-12 12:02:09 [simple-obfs] INFO: obfuscating enabled 2018-01-12 12:02:09 [simple-obfs] INFO: tcp port reuse enabled 2018-01-12 12:02:09 [simple-obfs] ERROR: bind: Address already in use 2018-01-12 12:02:09 [simple-obfs] ERROR: Could not bind 2018-01-12 12:02:09 [simple-obfs] ERROR: bind() error 2018-01-12 12:02:09 ERROR: plugin service exit unexpectedly

privatevpnsupportguy commented 6 years ago

It would work if I run the command directly:

ss-server -c config.json --plugin obfs-server --plugin-opts "obfs=http" But it won't if I put it inside config.json and run with systemctl start for example. It gives:

systemctl status shadowsocks-libev.service ● shadowsocks-libev.service - Shadowsocks-libev Default Server Service Loaded: loaded (/lib/systemd/system/shadowsocks-libev.service; enabled; vendor preset: enabled) Active: inactive (dead) since Sun 2018-02-18 16:17:41 CET; 2s ago Docs: man:shadowsocks-libev(8) Process: 5816 ExecStart=/usr/bin/ss-server -c $CONFFILE $DAEMON_ARGS (code=exited, status=0/SUCCESS) Main PID: 5816 (code=exited, status=0/SUCCESS)

Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 [simple-obfs] ERROR: Could not bind Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 [simple-obfs] ERROR: bind() error Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 ERROR: plugin service exit unexpectedly Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 INFO: plugin "obfs-server" enabled Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 INFO: UDP relay enabled Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 INFO: enable TCP no-delay Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 INFO: initializing ciphers... chacha20-ietf-poly1305 Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 INFO: using nameserver: 8.8.8.8 Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 INFO: tcp server listening at 127.0.0.1:60180 Feb 18 16:17:41 SS ss-server[5816]: 2018-02-18 16:17:41 INFO: udp server listening at 1.x.x.x:80

What could be the problem?