Page 1 of 1

[oconf] Installation with 2 interfaces

Posted: Sun Dec 10, 2023 7:31 pm
by tsiris
Good morning,

I have an old server (debian 9) with an openvpn access server version.

I would like to install openvpn on a new server (debian12).

I have never installed OpenVPN, only the AS version

I have two network interfaces, one interface with a public IP (ens192) and a second interface (ens192) which is in my internal network.

My private network is 192.168.100.0/24 and the DHCP server is on another server.

network : 192.168.100.0/24
DCHP : 192.168.100.5
GATEWAY : 192.168.100.254

I would like to be able to connect to my VPN and have an IP in my private network


here is my configuration

/etc/openvpn/server.conf

Code: Select all

local 164.x.x.x
port 1194
proto udp
dev tun

# private network
server 192.168.100.0 255.255.255.0
push "route 192.168.100.0 255.255.255.0"

ca ca.crt
cert server.crt
key server.key
dh dh.pem



push "dhcp-option DNS 8.8.8.8"
push "dhcp-option DNS 8.8.4.4"

is it ok to be in 'tun' mode ?


is my configuration ok with what I want to do?


thanks in advance