You are not logged in.

#1 2017-04-13 14:37:18

kgizdov
Member
Registered: 2015-12-08
Posts: 109

Synergy Systemd Socket hand off problem

Hi all,

So I am setting up Synergy for my desktop PC and laptop. It works perfectly when I run systemctl --user start synergys.service on my host and systemctl --user start syngergyc.service on client. Where the client service is just

...
ExecStart=/usr/bin/synergyc --no-daemon --debug WARNING --enable-crypto SEVER_NAME
...

Now, when I try to instead run the equivalent socket service on the host, the client gets connection refused. The host on the other had complains like this:

$ systemctl --user status synergys.socket
● synergys.socket
   Loaded: loaded (/usr/lib/systemd/user/synergys.socket; disabled; vendor preset: enabled)
   Active: active (running) since Thu 2017-04-13 16:21:37 CEST; 22s ago
   Listen: [::]:24800 (Stream)

Apr 13 16:21:37 server systemd[788]: Listening on synergys.socket.
$ systemctl --user status synergys.service
● synergys.service - Synergy Server Daemon
   Loaded: loaded (/usr/lib/systemd/user/synergys.service; disabled; vendor preset: enabled)
  Drop-In: /home/username/.config/systemd/user/synergys.service.d
           └─override.conf
   Active: active (running) since Thu 2017-04-13 16:21:49 CEST; 19s ago
 Main PID: 32546 (synergys)
   CGroup: /user.slice/user-1000.slice/user@1000.service/synergys.service
           └─32546 /usr/bin/synergys --no-daemon --config /etc/synergy.conf --enable-crypto

Apr 13 16:21:49 host synergys[32546]: [2017-04-13T16:21:49] WARNING: cannot listen for clients: cannot bind address: Address already in use
Apr 13 16:21:49 host synergys[32546]:         /build/synergy/src/synergy-1.8.8-stable/src/lib/synergy/ServerApp.cpp,554
Apr 13 16:21:49 host synergys[32546]: [2017-04-13T16:21:49] DEBUG: retry in 10 seconds
Apr 13 16:21:49 host synergys[32546]:         /build/synergy/src/synergy-1.8.8-stable/src/lib/synergy/ServerApp.cpp,568
Apr 13 16:21:49 host synergys[32546]: [2017-04-13T16:21:49] DEBUG: event queue is ready
Apr 13 16:21:49 host synergys[32546]:         /build/synergy/src/synergy-1.8.8-stable/src/lib/base/EventQueue.cpp,118
Apr 13 16:21:59 host synergys[32546]: [2017-04-13T16:21:59] WARNING: cannot listen for clients: cannot bind address: Address already in use
Apr 13 16:21:59 host synergys[32546]:         /build/synergy/src/synergy-1.8.8-stable/src/lib/synergy/ServerApp.cpp,554
Apr 13 16:21:59 host synergys[32546]: [2017-04-13T16:21:59] DEBUG: retry in 10 seconds
Apr 13 16:21:59 host synergys[32546]:         /build/synergy/src/synergy-1.8.8-stable/src/lib/synergy/ServerApp.cpp,568

So somehow the socket steals the address bind or something, even though is has 'Accept=false'? How can I work around this. I am using the vanilla services present in the synergy package apart from the client service, which I had to write myself (incl. above).


Dell XPS 13 (9350): Core i7, 16GB, 512GB NVMe

Offline

#2 2017-09-18 13:54:52

Unb0rn
Member
Registered: 2017-04-28
Posts: 4

Re: Synergy Systemd Socket hand off problem

Have you resolved this issue? It seems to reproduce on latest synergy for me...

Offline

#3 2017-09-18 14:28:46

kgizdov
Member
Registered: 2015-12-08
Posts: 109

Re: Synergy Systemd Socket hand off problem

No, unfortunately, I was not able to.


Dell XPS 13 (9350): Core i7, 16GB, 512GB NVMe

Offline

#4 2018-03-08 11:11:13

ismo
Member
From: Italy
Registered: 2010-11-21
Posts: 6
Website

Re: Synergy Systemd Socket hand off problem

Hi All,

probably you have to change the line 2 of synergys.socket file.

[Unit]
Conflicts=synergys@.service

[Socket]
ListenStream=24800
Accept=false

[Install]
WantedBy=sockets.target

Specify the service name avoiding the @ character

Conflicts=synergys.service

instead of

Conflicts=synergys@.service

Last edited by ismo (2018-03-08 11:12:02)

Offline

Board footer

Powered by FluxBB