Check an active connection

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

Rieder

Posts: 2
Joined: Thu Jan 14, 2021 10:24 pm

Post by Rieder » Tue Jan 26, 2021 5:58 am
Hi

Is there a way for a Powershell script to detect if there's a active connection present in Viscosity 1.9? We have to upgrade and we don't want to disconnect users when they are connected. So the script looks for an active connection. If it's present, it tries againn XX minutes later. When it detects that no connection is present, it runs the update with a promt to the user.

Eric

User avatar
Posts: 1146
Joined: Sun Jan 03, 2010 3:27 am

Post by Eric » Wed Jan 27, 2021 10:39 am
Hi Rieder,

You would need to iterate all your connections with the getstate command - https://sparklabs.com/support/kb/articl ... g-windows/

Alternatively, you check if an openvpn.exe process is running on the machine.

Regards,
Eric
Eric Thorpe
Viscosity Developer

Web: http://www.sparklabs.com
Support: http://www.sparklabs.com/support
Twitter: http://twitter.com/sparklabs
2 posts Page 1 of 1