Shadowsocks-libev: Failed upgrade from 2.6.1 to 3.0.0. Service doesnt work!

Created on 1 Feb 2017  ·  33Comments  ·  Source: shadowsocks/shadowsocks-libev

Please answer these questions before submitting your issue. Thanks!

What version of shadowsocks-libev are you using?

2.6.1

What operating system are you using?

Ubuntu 16.10 Linux kernek 4.10

What did you do?

Installed ss-libev from git source and applying this command sudo dpkg -i shadowsocks-libev_3.0.0*.deb

What did you expect to see?

I want to see upgrade from 2.6.1 to 3.0.0

What did you see instead?

shadowsocks-libev.service - Shadowsocks-libev Default Server Service
Loaded: loaded (/lib/systemd/system/shadowsocks-libev.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2017-02-01 20:24:24 CET; 2s ago
Docs: man:shadowsocks-libev(8)
Process: 15493 ExecStart=/usr/bin/ss-server -c $CONFFILE $DAEMON_ARGS (code=exited, status=255)
Main PID: 15493 (code=exited, status=255)

Feb 01 20:24:24 vps-116 systemd[1]: Started Shadowsocks-libev Default Server Service.
Feb 01 20:24:24 vps-116 systemd[1]: shadowsocks-libev.service: Main process exited, code=exited, status=255
Feb 01 20:24:24 vps-116 systemd[1]: shadowsocks-libev.service: Unit entered failed state.
Feb 01 20:24:24 vps-116 systemd[1]: shadowsocks-libev.service: Failed with result 'exit-code'.

What is your config in detail (with all sensitive info masked)?

Basic json config

@eastmalon @madeye @lcdtyph Guys who can help to me? Please.

Most helpful comment

@asmadeus08 Get everything latest and working should be:

apt update
apt upgrade

Period. Full stop.

All 33 comments

please try to remove old version( remember to back up your config file) :

sudo apt-get purge shadowsocks-libev

Please attach the config with sensitive info masked.

@eastmalon i did that of course:
apt-get remove shadowsocks-libev and apt purge shadowsocks-libev but when i'm compiled from github source new version and trying to upgrade using this sudo dpkg -i shadowsocks-libev_3.0.0*.deb then i recieve thqat error:
shadowsocks-libev.service - Shadowsocks-libev Default Server Service
Loaded: loaded (/lib/systemd/system/shadowsocks-libev.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2017-02-01 20:24:24 CET; 2s ago
Docs: man:shadowsocks-libev(8)
Process: 15493 ExecStart=/usr/bin/ss-server -c $CONFFILE $DAEMON_ARGS (code=exited, status=255)
Main PID: 15493 (code=exited, status=255)
Feb 01 20:24:24 vps-116 systemd[1]: Started Shadowsocks-libev Default Server Service.
Feb 01 20:24:24 vps-116 systemd[1]: shadowsocks-libev.service: Main process exited, code=exited, status=255
Feb 01 20:24:24 vps-116 systemd[1]: shadowsocks-libev.service: Unit entered failed state.
Feb 01 20:24:24 vps-116 systemd[1]: shadowsocks-libev.service: Failed with result 'exit-code'.

@anonymous-contributor this is my user.json config for ss-libev 2.6.1

"server":"0.0.0.0",
"server_port":*,
"local_address":"127.0.0.1",
"local_port":1080,
"password":"
**
",
"timeout":120,
"method":"camellia-256-cfb",
"fast_open": true,
"auth":true

When i'm trying to change config.json on my data it's breaking. But generated version is working:
"server":"127.0.0.1",
"server_port":8388,
"local_port":1080,
"password":"HocEetoc",
"timeout":60,
"method":"rc4-md5"

So what to do with that?

Set auth to false and try again.

@madeye please look on my previous comment. Problem on whole config.json and conflict there.

@madeye @eastmalon Almost all config data working fine. Justs tested:

"server":"0.0.0.0",
"server_port":*,
"local_address":"127.0.0.1",
"local_port":1080,
"password":"
**
",
"timeout":120,
"method":"camellia-256-cfb",
"fast_open": true,
"auth":false

Except server port cause when i'm trying to change it from 8388 to 995 ss-libev service breaking. And i need server port only 995-996. All other ports is closed.

I will try to build new version of ss-libev from the start on clean Ubuntu 16.10 system with 4.10rc6 linux kernel and let's what will happened.. I think there is some conflict cause somewhere files of ss-libev stay that's why there is port conflict. So let's see.

@madeye
May I know why OTA is deprecated...

Maybe cause it's conflict with new ciphers?

@madeye and what to do with my problem? Do you have any suggestions?

@lcdtyph In short, OTA is flawed by design.

@Mygod do you have ny thought's about my problem?

@madeye @asmadeus08 @Mygod
Got it, thanks for replying!

@madeye @Mygod Problem was in ss-libev config file. After removing old version or upgrading over old one it's generated and applying as it must to be. But when user trying to change port it's failing. But i did the same on clean ubuntu 16.10 with linux kernel 4.10rc6 right now and all is working perfect! Please try to check this problem and fix it.

@madeye I think we should make version upgrade as smooth as possible.
Is it possible to add a script in postinst to handle auth=null thing?

@rogers0 I think it's doable. Also show warnings in the script.

@madeye Good to hear that.
My limited shell script knowledge don't allow me to change the setting in json. So could you provide the script, or give me an example, please?

If just shows the warning, we only need to write a NEWS.Debian file under debian/ folder.

I think warning is already enough. To detect auth in the config, we can simply grep auth /etc/shadowsocks-libev/config.json and show a warning.

So that

@madeye So that's what i did:
1 Upgrade the system to 16.10
2 Install ss-libev from ubuntu repository - sudo apt install shadowsocks-libev
3 Then:
git clone https://github.com/shadowsocks/shadowsocks-libev.git
cd shadowsocks-libev
git reset --hard origin/master
git pull
git submodule init && git submodule update
sudo apt-get install --no-install-recommends build-essential autoconf libtool libssl-dev \
gawk debhelper dh-systemd init-system-helpers pkg-config asciidoc xmlto apg libpcre3-dev zlib1g-dev \
libev-dev libudns-dev libsodium-dev
sudo apt-get install --no-install-recommends gettext build-essential autoconf libtool libpcre3-dev asciidoc xmlto libmbedtls-dev libev-dev libudns-dev libsodium-dev
./autogen.sh && dpkg-buildpackage -b -us -uc -i
cd ..
sudo dpkg -i shadowsocks-libev*.deb

Change all my config.jso to what i need and auth set to false. Now all is working fine and https sites working too. Is it enough to do that for upgrading? And how to check if i have the latest version now?

@asmadeus08 you can simply remove the line with "auth" from config.json.

@rogers0 i dont have problem with auth param cause i'm already removed that. I'm interest only about this one: Is it enough to do that for upgrading from ubuntu repository to source repository? And how to check if i have the latest version now?

@asmadeus08 If you ask so, I have to recommend you to install pkg from official repository.
Don't build your own DEB when it's not necessary. Because usually you don't have time and resource to maintain all the packages you build yourself. It's easily for you to miss an important security patch released by upstream.

If you really want to build local package, build only the minimized, most necessary one.

@rogers0 thanks for your advance but how to check now if i'm using last version of ss-libev right now?
And what do you think about this auto-install script https://github.com/Aurwen/shadowsocks-libev ?

@asmadeus08 Get everything latest and working should be:

apt update
apt upgrade

Period. Full stop.

@rogers0 i'm asking not about ubuntu but about how to check is there last version of ss-libev installed or not?

@asmadeus08 in case you didn't know, ss-libev is already in ubuntu reposiroty

@rogers0 yes and when i apply this - sudo apt install shadowsocks-libev it's show 2.6.3
But then i'm do that:
git clone https://github.com/shadowsocks/shadowsocks-libev.git
cd shadowsocks-libev
git reset --hard origin/master
git pull
git submodule init && git submodule update
sudo apt-get install --no-install-recommends build-essential autoconf libtool libssl-dev
gawk debhelper dh-systemd init-system-helpers pkg-config asciidoc xmlto apg libpcre3-dev zlib1g-dev
libev-dev libudns-dev libsodium-dev
sudo apt-get install --no-install-recommends gettext build-essential autoconf libtool libpcre3-dev asciidoc xmlto libmbedtls-dev libev-dev libudns-dev libsodium-dev
./autogen.sh && dpkg-buildpackage -b -us -uc -i
cd ..
And after applying this cmd sudo dpkg -i shadowsocks-libev*.deb it show that ss-libev upgrading 3.0.0 over 2.6.3. So i'm suppose now i have latest version after that?

@asmadeus08 it's by your definition of word "latest".
Lastest version for ubuntu 16.10 is 2.6.3+ds-1 from my side.

@rogers0 @madeye Yes that's right but i did upgrade with that sudo dpkg -i shadowsocks-libev*.deb and log show that 3.0.0 was installed over 2.6.3 so that's why i'm asking if i have now last version? Cause i'm installed from github repo over ubuntu repo...

@asmadeus08 the log shows it worked as you expected.

Was this page helpful?
0 / 5 - 0 ratings