Usingthis information, I've set it so that the WiFi doesn't disconnect when I lock my mac. To lock the mac, I'm using this alias to lock my screen from the command line: alias lockscreen='/System/Library/CoreServices/"Menu Extras"/User.menu/Contents/Resources/CGSession -suspend' obtained from this article.

Unfortunately, when I lock my screen and come back, the WiFi stays connected but Viscosity, the VPN client I use, doesn't. I went to this website and it gave me the advice to keep my network adapter always on and linked to the same StackOverflow link I linked at the top. Is there a way I can keep Viscosity connected? I'm open to other VPN clients as well, I just need a good one that stays connected when I lock the screen and the wireless is connected.

I'm running Viscosity version 1.7 and my Mac information is as follows:

enter image description here

Could it be that the VPN adapter is using a different interface than ens0 and therefore I need to set the DisconnectLogout line in /System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources to NO for that interface as well?

Edit: The wireless adapter still disconnects upon screen lock, so disregard my earlier claim. It worked fine when I slept it but when I used the screen lock alias, it didn't work. Not sure why this would be, so I'll need to look into this as well.

  • Have you asked the developers of Viscosity directly? They are best placed to answer your question and provide support. – Graham Miln Feb 20 at 16:37
  • I haven't but will do so. Thank you for the advice! – AndreasKralj Feb 20 at 17:21
  • 1
    Feel free to point the developer at this question, so they can provide an answer. Alternatively, you can add your own answer when they respond to help others. – Graham Miln Feb 20 at 17:43

You must log in to answer this question.

Browse other questions tagged .