Hi guys.
I need someone help with this; I'm not that good in networking, but I try to get an OpenVPN setup to work.
Here is my setup:
I have 2 Debian 9 servers (running ProxMox) with public IP 158.69.246.61 (let's call it MASTER) and public ip 158.69.246.107 (let's call it CLIENT).
Here are some of my files:
[oconf=MASTER /etc/network/interfaces]
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
iface lo inet loopback
# for Routing
auto vmbr1
iface vmbr1 inet manual
bridge_ports dummy0
bridge_stp off
bridge_fd 0
# vmbr0: Bridging. Make sure to use only MAC adresses that were assigned to you.
auto vmbr0
iface vmbr0 inet static
address 158.69.246.61
netmask 255.255.255.0
network 158.69.246.0
broadcast 158.69.246.255
gateway 158.69.246.254
bridge_ports eth0
bridge_stp off
bridge_fd 0
iface vmbr0 inet6 static
address 2607:5300:0120:063d::
netmask 64
post-up /sbin/ip -f inet6 route add 2607:5300:0120:06ff:ff:ff:ff:ff dev vmbr0
post-up /sbin/ip -f inet6 route add default via 2607:5300:0120:06ff:ff:ff:ff:ff
pre-down /sbin/ip -f inet6 route del default via 2607:5300:0120:06ff:ff:ff:ff:ff
pre-down /sbin/ip -f inet6 route del 2607:5300:0120:06ff:ff:ff:ff:ff dev vmbr0
auto openvpnbr0
iface openvpnbr0 inet static
address 192.168.192.10
netmask 255.255.255.0
network 192.168.192.0
broadcast 192.168.192.255
bridge_ports dummy1
bridge_stp off
bridge_fd 0
post-up route add -net 224.0.0.0 netmask 240.0.0.0 dev openvpnbr0
[/oconf]
[oconf=CLIENT /etc/network/interfaces]
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
iface lo inet loopback
# for Routing
auto vmbr1
iface vmbr1 inet manual
bridge_ports dummy0
bridge_stp off
bridge_fd 0
# vmbr0: Bridging. Make sure to use only MAC adresses that were assigned to you.
auto vmbr0
iface vmbr0 inet static
address 158.69.246.107
netmask 255.255.255.0
network 158.69.246.0
broadcast 158.69.246.255
gateway 158.69.246.254
bridge_ports eth0
bridge_stp off
bridge_fd 0
iface vmbr0 inet6 static
address 2607:5300:0120:066b::
netmask 64
post-up /sbin/ip -f inet6 route add 2607:5300:0120:06ff:ff:ff:ff:ff dev vmbr0
post-up /sbin/ip -f inet6 route add default via 2607:5300:0120:06ff:ff:ff:ff:ff
pre-down /sbin/ip -f inet6 route del default via 2607:5300:0120:06ff:ff:ff:ff:ff
pre-down /sbin/ip -f inet6 route del 2607:5300:0120:06ff:ff:ff:ff:ff dev vmbr0
auto openvpnbr0
iface openvpnbr0 inet static
address 192.168.192.11
netmask 255.255.255.0
network 192.168.192.0
broadcast 192.168.192.255
bridge_ports dummy1
bridge_stp off
bridge_fd 0
post-up route add -net 224.0.0.0 netmask 240.0.0.0 dev openvpnbr0
[/oconf]
Both OPENVPNBR0 interfaces where added when I followed a 2013 tutorial to connect two ProxMox via OpenVPN, I'm not sure it's even required now.
I want my CLIENT from it's private IP (192.168.192.11) to be able to connect to my MASTER on it's private IP (192.168.192.10), and be able to ping it's private IP and vice versa. Both server still need to be accessible from their public IPs when VPN is connected.
Here are some more files:
root@ns535320.ip-158-69-246.net:/etc/openvpn# cat server.conf | grep -v -e '^;' | grep -v -e '^#' | grep -v -e '^$'
port 1194
proto udp
dev tun
ca /etc/openvpn/certs/keys/ca.crt
cert /etc/openvpn/certs/keys/server.crt
key /etc/openvpn/certs/keys/server.key # This file should be kept secret
dh dh4096.pem
server 192.168.192.0 255.255.255.0
ifconfig-pool-persist ipp.txt
client-to-client
duplicate-cn
keepalive 10 120
tls-auth /etc/openvpn/certs/keys/ta.key 0 # This file is secret
cipher AES-256-CBC
user openvpn
group nogroup
persist-key
persist-tun
status openvpn-status.log
log-append openvpn.log
verb 3
explicit-exit-notify 1
auth SHA512
tls-cipher TLS-DHE-RSA-WITH-AES-256-GCM-SHA384:TLS-DHE-RSA-WITH-AES-128-GCM-SHA256:TLS-DHE-RSA-WITH-AES-256-CBC-SHA:TLS-DHE-RSA-WITH-CAMELLIA-256-CBC-SHA:TLS-DHE-RSA-WITH-AES-128-CBC-SHA:TLS-DHE-RSA-WITH-CAMELLIA-128-CBC-SHA
root@ns535576:/etc/openvpn# cat openvpn.conf | grep -v -e '^;' | grep -v -e '^#' | grep -v -e '^$'
client
dev tun
proto udp
remote 158.69.246.61 1194
resolv-retry infinite
nobind
user nobody
group nogroup
persist-key
persist-tun
ca ca.crt
cert ns535576.crt
key ns535576.key
remote-cert-tls server
tls-auth ta.key 1
cipher AES-256-CBC
verb 3
auth SHA512
tls-cipher TLS-DHE-RSA-WITH-AES-256-GCM-SHA384:TLS-DHE-RSA-WITH-AES-128-GCM-SHA256:TLS-DHE-RSA-WITH-AES-256-CBC-SHA:TLS-DHE-RSA-WITH-CAMELLIA-256-CBC-SHA:TLS-DHE-RSA-WITH-AES-128-CBC-SHA:TLS-DHE-RSA-WITH-CAMELLIA-128-CBC-SHA
It connect and all, but I can't ping the MASTER from the CLIENT nor the CLIENT from the MASTER.
OpenVPN CLIENT LIST
Updated,Sat Apr 7 19:45:40 2018
Common Name,Real Address,Bytes Received,Bytes Sent,Connected Since
ns535576,158.69.246.107:55923,7233,7290,Sat Apr 7 19:45:29 2018
ROUTING TABLE
Virtual Address,Common Name,Real Address,Last Ref
192.168.192.6,ns535576,158.69.246.107:55923,Sat Apr 7 19:45:29 2018
GLOBAL STATS
Max bcast/mcast queue length,0
END
Any suggestion for me please? And thanks in advance for your help.
David.