desktop icon indicating copy to clipboard operation
desktop copied to clipboard

Feature Request: Connect on System Boot

Open 8227846265 opened this issue 4 years ago • 7 comments

Hello, I would like to request a cool feature that will make PIA VPN more awesome.

There's a feature in VyprVPN called "Connect on System Boot" on the Startup Options of their app. image

Based on experience, it's really effective in tandem with kill switch wherein during login process on Windows. The VPN is already connected before their VPN application opens.

Thus, the user doesn't really have to worry about applications not loading properly due to internet connection anymore if the kill switch is enabled and the VPN is trying to connect during boot up process.

Reference Articles related to Connect on System Startup/System Boot https://openvpn.net/community-resources/configuring-openvpn-to-run-automatically-on-system-startup/

https://openvpn.net/vpn-server-resources/use-openvpn-connect-v3-on-windows-in-service-daemon-mode/

8227846265 avatar Mar 05 '21 11:03 8227846265

This feature has always been available, titled "Launch on System Startup" in the UI.

faireOwl avatar May 28 '21 14:05 faireOwl

That's different. That's a "Launch on Startup" wherein you have to see the "Sign In Page" on Windows before the VPN program starts.

The "Connect on System Boot" on the other hand loads the VPN program earlier before the login page on Windows even appears.

PIA right now on the auto-start on launch functionality will have few seconds upon login that it kills the internet connection while it's connecting when you have Kill Switch to "Always".

This causes "cannot connect / no internet" errors on other startup programs that doesn't have auto-reconnect feature.

Back to the feature being requested.

If "Connect on System Boot" is enabled as a feature on PIA, you won't see those few seconds of disconnection when booting up your computation while Kill Switch is set to "Always"

And ensures other startup program gets connected on a VPN every boot up of your computer even before you logged in.

8227846265 avatar May 28 '21 14:05 8227846265

In short. "Launch on Startup" = VPN connects after login page appears image

While "Connect on System Boot" = VPN is allowed to have the connection up and running right after system boot even when nobody is logged on (e.g. early startup) image

8227846265 avatar May 28 '21 14:05 8227846265

I am also trying to find a way to make this work.

archerallstars avatar Jun 04 '21 08:06 archerallstars

I found the solution. The magic is that you will have to enable the PIA daemon to run in the background. Otherwise, you won't be able to make PIA's connection.

I can enable the background daemon (in my session while the client GUI is running) with this:

piactl background enable

Now, I can log out of my session (PIA will be disconnected). Then, I log in to my session locally through an SSH tunnel. Since I already enabled the background daemon with the code above, now I can run this:

piactl connect

Next, I check the connection with this:

piactl get connectionstate

If the above command returned "Connected", it should be OK.

Now, in order to connect to my session over the internet, I will have to know both my VPN's IP and forward port number. I can do it with this code respectively:

piactl get vpnip          
piactl get portforward

Now, I can get PIA running and remote my session through RDP without ever having to log in again. Moreover, PIA won't disconnect even after I logged out of my session. Extremely happy!

I am very happy with the service. However, I hope this feature will be implemented in the GUI client soon. I am on Ubuntu by the way.

archerallstars avatar Jun 04 '21 10:06 archerallstars

Indeed, this is only the feature missing to ensure Kill Switch is fully working without disconnection upon startup.

8227846265 avatar Jun 04 '21 10:06 8227846265

Indeed, this is only the feature missing to ensure Kill Switch is fully working without disconnection upon startup.

With the above setup, not only PIA will connect at boot but it won't disconnect even after I logged out of my session. Extremely happy!

archerallstars avatar Jun 04 '21 10:06 archerallstars

Closing as solved in comments, thanks!

banister avatar Aug 28 '23 19:08 banister