Setup PIA VPN on Cooker or ROME (updated 2024-02-24)

This procedure updated for 2023 since the way things look in NetworkManager (aka: Connectiions - SystemSettings) has changed.

To do this you will need an account at PIA VPN and there is a fee for that.

Install these:

sudo dnf in lib64nl-idiag3_200 lib64nl-xfrm3_200 iptables lib64nsl-static-devel

Select “Download VPN for Linux” here.

Next we need to download the openvpn files from here. I used the 3rd entry OPENVPN CONFIGURATION FILES (STRONG).

In folder where you downloaded these you need to make the first thing you downloaded pia-linux-3.5.2-07877.run executable like this:

$ sudo chmod +x pia-linux-3.5.2-07877.run

Next install the .run file as user like this:

$ ./pia-linux-3.5.2-07877.run

You will see a window with an error:

Don’t worry, that is normal for this installation. Exit that window and we’ll fix that.

Next we want to copy the installer for the ovpn files to /etc/openvpn:

$ sudo cp openvpn-strong.zip /etc/openvpn

Then I list several steps here:

$ cd /etc/openvpn

$ sudo unzip openvpn-strong.zip

$ sudo rm openvpn-strong.zip

Now go to the network icon in your system tray click on it and click on the circle icon at top right to open “Configure Network Connections”. Click on the + sign and we shall create something. Scroll down until you find “VPN Connections” under that find “OpenVPN” and select “create”. That opens this window:

You can use any name you wish under ‘Connection name’. Under ‘Gateway’ you enter one of the .ovpn entries in /etc/openvpn. I used one relativly close to my physical location.

Next in the “CA Certificate” line navigate again to /etc/openvpn and fine the .crt file and select that.

Next in the same window click"Advanced". Under “General” tab select “Use custom gateway port” and set that to 1197.

Next under “Security” tab for Cipher select “AES-256-CBC” then for “HMAC Authentication” select “SHA-256”.

Select OK to save the Advanced settings. Select Save to create our VPN Connection.

Now in Konsole to open and start this connection:

cd /opt/piavpn/bin/
sudo ./pia-client

You will see a window that offers a quick tour, I recommend you do that, and then login with your PIA VPN account user name and password. (You will need to start the VPN from terminal every time you login.)

Under “Quick Connect” you will see some flags. Each one of those will change your location and IP address. For more choices where you see “VPN Server” select the >. I selected the Panama flag for this test.

Now to check if this is working open a browser and go to whatismyip.com.

My Public IPv6 is: Not Detected >>> because my IP provider does not have that.

Now we need to add an environment variable to the entry in Application Launcher>Internet for Private Internet Access so it will start. To get PIA VPN to start from the Application Launcher>Internet>Private Internet Access just add this environment variable to /usr/share/applications/piavpn.desktop:

The environment variable: QT_PLUGIN_PATH=/opt/piavpn/plugins:/usr/lib64/qt5/plugins

If you want PIA VPN to launch on desktop startup you then go to Settings in PIA VPN and select “Launch on System Startup”. The go to /home/your_user_name/.config/autostart/pia-client.desktop. And add the same environment variable there.

The environment variable: QT_PLUGIN_PATH=/opt/piavpn/plugins:/usr/lib64/qt5/plugins

Reboot.

Note: I have done this in Cooker, ROME, and Rock/5.0 partitions this works in all.

Credit to user @clfitz for the setup part of this. Credit user @peter-power-594 for the environment variable that enables this application to start.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.

Original post update 2023-12-09.

These steps should work in ROME when Plasma6 hits ROME. Just got this working in Cooker Plasma6. To do so I needed to install:

dnf in lib64nl-idiag3_200 lib64nl-xfrm3_200 iptables lib64nsl-static-devel libgthread2.0_0 lib64gthread2.0_0.

Which is two more packages than I needed to install for Plasma5. And also needed to:

cp /usr/share/applications/piavpn.desktop /home/ben79/.config/autostart/

Still need to test that it starts automatically after I login to Plasma6 desktop.