Hi folks,
I have a proxmox host, who runs the ovpn server on bridge mode. The client connects to the openvpn server and gets the IP address from the pool correctly (10.42.41.41), but when I want to ping the server 10.42.42.1 it is not reachable.
My server.conf file:
port 443
proto udp
dev tap
ca /etc/openvpn/my_ca/keys/ca.crt
cert /etc/openvpn/my_ca/keys/server.crt
key /etc/openvpn/my_ca/keys/server.key
dh /etc/openvpn/my_ca/keys/dh4096.pem
# on 10.8.0.1. Comment this line out if you are
# ethernet bridging. See the man page for more info.
;server 10.42.41.0 255.255.255.0
ifconfig-pool-persist ipp.txt
server-bridge 10.42.41.1 255.255.255.0 10.42.41.41 10.42.41.49
# Configure server mode for ethernet bridging
# using a DHCP-proxy, where clients talk
# to the OpenVPN server-side DHCP server
# to receive their IP address allocation
# and DNS server addresses. You must first use
# your OS's bridging capability to bridge the TAP
# interface with the ethernet NIC interface.
# Note: this mode only works on clients (such as
# Windows), where the client-side TAP adapter is
# bound to a DHCP client.
server-bridge
push "redirect-gateway def1 bypass-dhcp"
push "dhcp-option DNS 8.8.4.4"
push "dhcp-option DNS 8.8.8.8"
client-to-client
keepalive 10 120
persist-key
persist-tun
status openvpn-status.log
verb 3
My /etc/network/interfaces is this:
### Hetzner Online GmbH - installimage
# Loopback device:
auto lo
iface lo inet loopback
iface lo inet6 loopback
#Please ignore vmbr0 as it is working - local host
auto vmbr0
iface vmbr0 inet static
address 1.2.3.4
netmask 255.255.255.224
pointtopoint 1.2.3.254
gateway 1.2.3.254
bridge_ports eth0
bridge_stp off
bridge_fd 0
bridge_hello 2
bridge_maxage 12
#VM Containers
up route add -host 5.6.7.8 dev vmbr0
iptables -t nat -A POSTROUTING -s 5.6.7.8/24 -o vmbr0 -j MASQUERADE
#openVPN
up route add -net 10.42.41.0 netmask 255.255.255.0 gw 10.42.41.1 vmbr0
iptables -t nat -A POSTROUTING -s 10.42.41.0/24 -o vmbr0 -j MASQUERADE
# VMs
auto vmbr10
iface vmbr10 inet static
address 192.168.0.1
netmask 255.255.255.0
bridge_ports none
bridge_stp off
bridge_fd 0
post-up echo 1> /proc/sys/net/ipv4/ip_forward
up route add -net 192.168.0.0 netmask 255.255.255.0 gw 192.168.0.1 vmbr10
post-up iptables -t nat -A POSTROUTING -s 192.168.0.0/24 -o vmbr0 -j MASQUERADE
Does anyone has an idea, please?
Thanks.