wiki:install_openvpn_lxc
This is an old revision of the document!
Table of Contents
Install OpenVPN in lxc
On Debian 9 Stretch host create these files for Debian 7 Wheezy container
mkdir /dev/net mknod /dev/net/tun c 10 200
Follow tutorial at https://openvpn.net/index.php/open-source/documentation/howto.html#pki
apt-get install openvpn
In server.conf plugin path for user/pass authentication:
plugin /usr/lib/openvpn/openvpn-auth-pam.so system-auth
For Jessie (Debian 8):
plugin /usr/lib/openvpn/openvpn-plugin-auth-pam.so system-auth
In case of error:
Mon Dec 18 14:48:14 2017 srv02/xxx.xxx.x.x:39658 Authenticate/Decrypt packet error: cipher final failed
make sure the ciphers are same in server.conf and client.conf.
For unprivileged container inside Proxmox for mknod to work add this to /etc/pve/lxc/lxc.conf:
lxc.mount.entry = /dev/net dev/net none bind,create=dir
Also check owner of files on host vs container.
Tested on
See also
References
wiki/install_openvpn_lxc.1625816825.txt.gz · Last modified: 2021/07/09 07:47 by antisa