I know this is a FAQ as configuration problem, but I can't have it working in my installation (a very similar configuration
works fine for other 2 couple of nets)
Situation:
_________ NET _______
/ a.b.c.d \ e.f.g.h
RTR-FW1 RTR-FW2
/ \
/ 192.168.189.1/24 \ 192.168.117.5/24
LinuxGW1 (10.8.0.1/24) LinuxGW2 (10.8.0.2/24)
| 10.0.0.250/24 | 192.168.107.5/24
/ \ / \
Win11 Lin12 Win21 Win22
Obviously I want the servers into the 2 LANs behind the LinuxGW1 & 2 can freely communicate.
At the moment I have that from LinuxGW1 I can reach all the hosts in LAN2, but from the hosts in LAN2 (that have LinuxGW2 as
default GW), I can't reach LAN1. And LAN1 can't reach LAN2
If I install an OpenVPN client into Win11 I can access the LAN2 without problems
LinuxGW1 & 2 are Debian 9 + openvpn. I use 10.8.0.0/24 for the tunnel
>From LAN1 I can ping 10.8.0.2, but not 10.8.0.1
>From LAN1 I can ping both 10.8.0.1 and 10.8.0.2
I am missing something but can't understand what.
Any hints appreciated.
Below configs.
Thanks, P.
LinxGW2(Server)
# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 192.168.117.1 0.0.0.0 UG 0 0 0 ens18
10.0.0.0 10.8.0.2 255.255.255.0 UG 0 0 0 tun0
10.8.0.0 0.0.0.0 255.255.255.0 U 0 0 0 tun0
192.168.107.0 0.0.0.0 255.255.255.0 U 0 0 0 ens19
192.168.117.0 0.0.0.0 255.255.255.0 U 0 0 0 ens18
port 1194
proto udp
dev tun
sndbuf 0
rcvbuf 0
ca ca.crt
cert server.crt
key server.key
dh dh.pem
auth SHA512
tls-auth ta.key 0
topology subnet
server 10.8.0.0 255.255.255.0
ifconfig-pool-persist ipp.txt
keepalive 10 120
cipher AES-256-CBC
comp-lzo
user nobody
group nogroup
persist-key
persist-tun
client-config-dir /etc/openvpn/ccd
status openvpn-status.log
verb 3
crl-verify crl.pem
log-append openvpn.log
route 10.0.0.0 255.255.255.0
push "route 192.168.107.0 255.255.255.0"
push "route 10.0.0.0 255.255.255.0"
client-to-client
In /etc/openvpn/ccd/wpcl01.conf
iroute 10.0.0.0 255.255.255.0
Client wpcl01
# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 192.168.189.254 0.0.0.0 UG 0 0 0 vmbr1
10.0.0.0 0.0.0.0 255.255.255.0 U 0 0 0 vmbr0
10.8.0.0 0.0.0.0 255.255.255.0 U 0 0 0 tun0
192.168.107.0 10.8.0.1 255.255.255.0 UG 0 0 0 tun0
192.168.189.0 0.0.0.0 255.255.255.0 U 0 0 0 vmbr1
client
dev tun
proto udp
sndbuf 0
rcvbuf 0
remote e.f.g.h 1194
resolv-retry infinite
nobind
persist-key
persist-tun
remote-cert-tls server
auth SHA512
cipher AES-256-CBC
comp-lzo
key-direction 1
verb 3
push "route 192.168.107.0 255.255.255.0"
status openvpn-status.log
log-append openvpn.log
<ca>
...