Start VPN in Linux Mint 18.3

Quick to answer questions about finding your way around Linux Mint as a new user.
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
Fairway Fatty
Level 2
Level 2
Posts: 57
Joined: Sun Dec 17, 2017 7:22 pm

Start VPN in Linux Mint 18.3

Post by Fairway Fatty »

I use a VPN service. I wasn’t sure how to start it in Linux.
Did a search and came across OpenVPN site and followed all of the steps listed to activate it in Terminal.
Went to Ipleak and it seems to be working.
Is there a program for Mint or easier way to start and stop my VPN in Linux other than terminal?
Thanks. FF
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
greerd
Level 6
Level 6
Posts: 1060
Joined: Sat Jul 31, 2010 10:58 am
Location: Nova Scotia, Canada

Re: Start VPN in Linux Mint 18.3

Post by greerd »

Yes, use should be able to use the Network Manager if you have the .ovpn config file.

The configuration can vary a bit depending on what your service needs but here is a guide, again from openvpn, that should give you the basic idea.

Please post your results.
User avatar
jameskga
Level 4
Level 4
Posts: 220
Joined: Sat Jun 04, 2016 8:23 pm

Re: Start VPN in Linux Mint 18.3

Post by jameskga »

It looks like you've already created a VPN connection, so that's good. You want it automatically logged in at the beginning of each session, right? Like as soon as you're online. VPN all day, every DAY, son!

Do this:

Click your network icon in the lower right panel.

Click the network connection you use to connect to the Internet. For me, this is under Wi-Fi. It could be under Ethernet or Wi-Fi for you. You might also notice the VPN connection you created in this list as well, and that's where it belongs.

Click Edit.

Click General tab.

Check the box 'Automatically connect to VPN when using this connection'

Select your VPN connection in the dropdown menu.

Restart your Wi-Fi connection and watch it automatically connect to the VPN as its first order of business.

Let me know if this helps. I read your post but I don't know if you've already taken these steps; however, if so then I feel like I might be having the same issue.

Here's the trouble I am having:

On Xfce this method (the preferred method most VPNs ask Linux users to implement, and the one I described above) works 100% of the time, starting the instant I log into the desktop environment. But on Cinnamon, there is a tremendous delay. Every day when I log in, it takes like an additional 5 or 10 minutes before finally accepting the VPN connection. During this time I can't click the VPN to manually log into the VPN, either. I can't tell it NOT to use VPN so I can at least access the web without protection. I have to wait for whatever's going wrong to finish, and then it works automatically after some time.
They say your favorite Mint edition was the one you installed when you still went to school with your friends.
I am out there
Fairway Fatty
Level 2
Level 2
Posts: 57
Joined: Sun Dec 17, 2017 7:22 pm

Re: Start VPN in Linux Mint 18.3

Post by Fairway Fatty »

greerd -
I used the link and tried the first portion ended up disconnecting my network connection and had to reset it. Then I tired the steps after the initial and ended up locking up Mint and had to re-boot.
I’m sure this is attributed to my lack of knowledge as to what I am doing etc.
jameskga-
I tried yours as well and it doesn’t seem to do anything. When I re-boot I'm connecting to WiFi but doesn’t sign into the VPN and I have to run the "script" below in terminal.
As above, I’m sure this is attributed to my lack of knowledge as to what I am doing etc.

This is what I am doing and its not so bad as it is copy and paste and I am using Terminal and it makes me think I know some sh*t :)
Open Terminal
cd /etc/openvpn/ovpn_tcp
sudo openvpn us123.nordvpn.com.tcp.ovpn
enter my PW
enter my UN
enter my PW
I know I'm using US and I change "123" with one of the config files in the list. This seems to work every time and I have to do it whenever I reboot.
One thing that I notice is that if I attempt to close terminal I get the message in screen shot below so I'm just leaving it open and minimize it.
Screenshot from 2017-12-21 12-55-52.png
I guess I could try closing it and see what happens. I'll try that next time I reboot.
I'm still open to suggestions but at this point I'm happy with the fact it is working!
Thanks. FF
User avatar
greerd
Level 6
Level 6
Posts: 1060
Joined: Sat Jul 31, 2010 10:58 am
Location: Nova Scotia, Canada

Re: Start VPN in Linux Mint 18.3

Post by greerd »

Here's a link for setting up NordVPN specifically, you'd probably want to jump down to step 4. As I mentioned in my earlier post, configurations can vary a bit, so hopefully this will work.
Fairway Fatty
Level 2
Level 2
Posts: 57
Joined: Sun Dec 17, 2017 7:22 pm

Re: Start VPN in Linux Mint 18.3

Post by Fairway Fatty »

OK greerd - I set-up per the link provided though it took me a couple of attempts. I don’t have the fancy GUI Terminal and "Network Manager" is a different in GUI with the miscellaneous Tabs but I got it all set-up. I auto connect to my WiFi on reboot but I haven’t figured out how to get the VPN to auto connect (I go to lower right and turn on after re-boot). No big deal as it works great and I was getting tired of starting in Terminal!
I noticed that my DL speed is ~5Mbs with VPN on and ~15Mbs with it off. The UL speed is ~1 to 1.4 which is about normal. I went to my VPN services website and used their "determine best server for your location" feature and I am using the config file recommended.
There is ~1000 servers to select for US but the file names don’t give any detail on vicinity until I actually connect to the web and run my IP location. The one suggested is showing me about 1000 miles away so I don’t know if that distance impacting my DL speed that much (assuming it is). When I use my VPN on my Win 10 install it kicks me about 400 miles away and I get ~15 to 20Mbs DL speed (my ISP is up to ~20Mbs DL 1.5Mbs UL).
Anyway - if anyone has any insight on selecting a VPN config file that can get me up closer to my bandwidth capabilities I would appreciate it.
Thanks for all the help! FF
User avatar
Pippin
Level 4
Level 4
Posts: 441
Joined: Wed Dec 13, 2017 11:14 am
Location: The Shire

Re: Start VPN in Linux Mint 18.3

Post by Pippin »

Try adding to the config file:

Code: Select all

fast-io
sndbuf 524288
rcvbuf 524288
Restart the client and test.
Try various speedtest sites.
You can play with the buffer values.
I gloomily came to the ironic conclusion that if you take a highly intelligent person and give them the best possible, elite education, then you will most likely wind up with an academic who is completely impervious to reality.
Halton Arp
User avatar
greerd
Level 6
Level 6
Posts: 1060
Joined: Sat Jul 31, 2010 10:58 am
Location: Nova Scotia, Canada

Re: Start VPN in Linux Mint 18.3

Post by greerd »

Pippin wrote:Try adding to the config file:
Do you mean to the .ovpn file?

@FF, I would suggest taking note of which servers Win10 uses and setup individual VPN entries for some of the better ones. You can have multiple servers setup and ready to use in Network Manager, just give them unique names.

You can setup Network Manager to auto connect the VPN by checking the 'Automatically connect to VPN when using this connection' box, picking the VPN from the drop down box in Edit connections using the main (wired and/or wireless) connection - Edit - General tab.

VPN speeds varies a lot depending on server load so speedtests will most likely vary significantly throughout the day.

EDIT: Also, I've read that udp is faster than tcp.
User avatar
Pippin
Level 4
Level 4
Posts: 441
Joined: Wed Dec 13, 2017 11:14 am
Location: The Shire

Re: Start VPN in Linux Mint 18.3

Post by Pippin »

greerd wrote:
Pippin wrote:Try adding to the config file:
Do you mean to the .ovpn file?
Yes, correct.
I gloomily came to the ironic conclusion that if you take a highly intelligent person and give them the best possible, elite education, then you will most likely wind up with an academic who is completely impervious to reality.
Halton Arp
Locked

Return to “Beginner Questions”