Archlinux – rolling release & setting up openvpn

Reading Time: 2 minutes

Installing Archlinux for the benefits of rolling updates which does not require full upgrades, which most likely will break some stuffs.  Refer to following URL explaining top reasons for using arch linux over ubuntu:

For fixed IP address, change:

# vim /etc/systemd/network/


Migrating software packages from 1 machine to another, listing all software from source machine:

# pacman -Qqen > Packages

Installing all software on target machine:

# xargs -a Packages pacman -S --noconfirm --needed

Changing hostname:

#vim /etc/hostname

Setting up Openvpn server:

Ensure tun kernel module is loaded:

# vim /etc/modules-load.d/tun.conf
# Load tun module at boot tun

Reboot, and check if tun module automatically loaded on startup:

[root@u3 ~]# lsmod |grep tun
tun 49152 0
[root@u3 ~]#

Install openvpn and easy-rsa, initialize a new PKI and generate a CA keypair that will be used to sign certificates:

# pacman -S openvpn easy-rsa

# cd /etc/easy-rsa
# export EASYRSA=$(pwd)
# easyrsa init-pki
# easyrsa build-ca

get the openvpn install script for arch linux:

# curl -O
# chmod +x
# ./

then you will get a file with <name>.ovpn,  use the file to configure for your client openvpn client, and you have a openvpn tunnel from client to server.

You have to troubleshoot using either iptables (iptables -L) commands to check firewall rules and journalctl -xe (server logs).

Adding firewall rules to allow openvpn incoming traffice:

# iptables -A INPUT -p udp --destination-port 1194 -j ACCEPT








Leave a Reply