Inhaltsverzeichnis

OpenVPN configuration for Linux

Due to the many different Linux distributions availible, it ist not possible for us to provide suitable instructions for every distribution. However, the following instructions should work without problems in most cases.

NOTE

For a stable connection you should use at least OpenVPN >= 2.5.2 If your Linux distribution does not provide a version >= 2.5.2, please refer to OpenvpnSoftwareRepos for information on how to use the OpenVPN software repository.

Ubuntu Linux

With this command you can determine your Ubuntu version:

lsb_release -a

Ubuntu 22.04

Ubuntu 22.04 and later includes a sufficently recent version of the OpenVPN package.You can install it via the package management with the following commands:

sudo apt-get update
sudo apt-get install openvpn

Then proceed to the "Configuration" section.

Ubuntu <=20.04

First configure the package source of the official OpenVPN packages with the following commands:

wget -O - https://swupdate.openvpn.net/repos/repo-public.gpg | sudo apt-key add -

echo "deb http://build.openvpn.net/debian/openvpn/stable <osrelease> main" | sudo tee /etc/apt/sources.list.d/openvpn-aptrepo.list

Replace <osrelease> with the name of your Ubuntu version. The currently supported versions are:

Then install the software package openvpn via your package management:

sudo apt-get update
sudo apt-get install openvpn

Configuration

Download our OpenVPN configuration file with this command:

sudo wget -O /etc/openvpn/RUBvpn_Standard.ovpn https://noc.rub.de/download/openvpn/RUBvpn_Standard.ovpn

You will find the downloaded file in /etc/openvpn/.

Connecting and disconnecting

To start the OpenVPN connection, enter this command in your terminal:

sudo openvpn /etc/openvpn/RUBvpn_Standard.ovpn

You will be asked for LoginID and password. Then the connection is established. Please do not close the terminal window. You can minimize it if it bothers you.

To end the connection, simply press CTRL+C in the terminal or close the window.