Today I’ll show you how to set up any version of Ubuntu using OpenVPN using the OpenVPN Network Manager. Ubuntu 20.04 and 22.04 come with OpenVPN Network Manager GUI built-in, so now it’s easy to connect a VPN on Ubuntu (see my other guide to setup using command line). For earlier versions of Ubuntu (18.04 and 16.04) see preliminary step below to install network-manager-openvpn package before starting step 1.
Contents
- Recommended Books
- Prerequisites
- Preliminary step for Ubuntu 16.04 and 18.04
- Connect OpenVPN with Ubuntu Network Manager
- Video: Connect OpenVPN with Ubuntu Network Manager
- Conclusion
- See Also
- Further Reading
Recommended Books
I can highly recommend these books on Linux Administration if you want to go further.
- The Linux Bible 10th Edition
- The Linux Command Line, 2nd Edition: A Complete Introduction
- Linux Administration: The Linux Operating System and Command Line Guide for Linux Administrators
Prerequisites
- You’ll need a VPN service that supports the OpenVPN Protocol like NordVPN, ExpressVPN or IPVanish VPN
- You’ll also need to login to your VPN service provider and find your OpenVPN credentials (username and password) and
.ovpn
config files
Preliminary step for Ubuntu 16.04 and 18.04
Skip this step if you’re running Ubuntu 20.04 or 22.04
You need to install the OpenVPN Network Manager GUI package before we begin this guide, so open up a Terminal window and enter the following code:
sudo apt install network-manager-openvpn -y
Connect OpenVPN with Ubuntu Network Manager
- Click the Network icon top-right of your screen, then click Settings:
- Click the Plus + icon under the VPN heading, then click OpenVPN:
- Visit your VPN service providers website (I always use IPVanish VPN) and look for the ‘Help’ or ‘Setup’ section, and download the CA Certificate for OpenVPN. Once you have the CA cert, enter the following information in the Add VPN window:
- Name: Enter a descriptive name for your VPN connection, mine is BTGuard
- Gateway: Enter the URL of your VPN providers VPN server. Mine is
sg.vpn.btguard.com
which is BTGuard’s Singapore server - Authentication Type: Password
- User name: MyVPNUserName
- Password: MyVPNPassword
- CA certificate: (you will need to get this from your VPN provider)
- Click the green Add button (top-right)
- To start your new VPN connection, toggle to on-off button on the Settings window. Once connected, you should see a small VPN icon top-right.
Video: Connect OpenVPN with Ubuntu Network Manager
Conclusion
You should now be connected to your service providers VPN using OpenVPN. If you had any issues, hit me up in the comments or socials/email.
See Also
- Set permanent DNS nameservers on Ubuntu/Debian with resolv.conf
- Set custom DNS servers on Ubuntu 18.04 or 20.04
Comments
There are currently no comments on this article.
Comment