Viscosity disconnects on close of laptop lid

Got a problem with Viscosity or need help? Ask here!

johnlevon

Posts: 2
Joined: Tue Feb 20, 2018 1:13 am

Post by johnlevon » Tue Feb 20, 2018 1:17 am
I have OS X set to not sleep when I close the laptop lid when on power. And this works in that I can stay ssh'd in over the wireless link when the lid is closed.

However, Viscosity still takes down the VPN connection in this case, and doesn't reconnect until I open the lid again.

This is Viscosity 1.7.6 (1425) on MacOS Sierra 10.12.6

Thanks!

James

User avatar
Posts: 2313
Joined: Thu Sep 04, 2008 9:27 pm

Post by James » Tue Feb 20, 2018 12:34 pm
Hi johnlevon,

Viscosity will only disconnect a connection if it receives a sleep notification from the operating system, or if the network connection is disconnected.

I'd recommend double-checking that your network connection isn't becoming disconnected when you close the lid, for example something like linked below. Please be aware that depending on the ClientAliveInterval/TCPKeepAlive setting on the SSH server a SSH session can remain active for quite some time even if the network is disconnected.
https://apple.stackexchange.com/questio ... ck-the-mac

If sleep notifications are still being sent to applications (unlikely if this is a macOS setting, possible if this is a third-party tool doing something exotic to prevent sleeps) I'm afraid there is nothing that can be done.

Cheers,
James
Web: https://www.sparklabs.com
Support: https://www.sparklabs.com/support
Twitter: https://twitter.com/sparklabs

johnlevon

Posts: 2
Joined: Tue Feb 20, 2018 1:13 am

Post by johnlevon » Tue Feb 20, 2018 10:45 pm
It is definitely only Viscosity that loses its network connection (i.e. I can still ls, etc. inside an ssh session to the laptop). Sounds like you are getting a kIOMessageSystemWillSleep notification or similar even though the system doesn't actually sleep :/

Tron

Posts: 2
Joined: Tue Mar 24, 2015 4:07 pm

Post by Tron » Thu Feb 22, 2018 9:38 pm
Check this out,, hope it helps

Keep Your MacBook Awake with the Display Closed;

https://mac-how-to.gadgethacks.com/how- ... d-0158152/
4 posts Page 1 of 1