Hello Everyone,
For a long time now, I have been using OpenVPN and had successfully set up routing to access my LAN with an OpenVPN client. I am writing "had" because two days ago I replaced my modem/router, and it routing is not working properly since then.
So, in my quest to figure out what is going wrong, I have learned many things, but I need your help to determine if indeed it is just an issue of the static route function in the router.
Well, my configuration is the following:
Modem/Router/Gateway IP: 192.168.0.1
OpenVPN server IP: 192.168.0.1
OpenVPN client IP: 10.8.0.x
Subnet mask is 255.255.255.0
My OpenVPN server configuration:
port 1194
proto tcp
dev tun
ca ca.crt
cert server.crt
key server.key
dh dh1024.pem
server 10.8.0.0 255.255.255.0
push "route 192.168.0.0 255.255.255.0"
push "dhcp-option DNS 192.168.0.253"
persist-key
persist-tun
client-to-client
management 192.168.0.254 7505
keepalive 10 120
comp-lzo
status openvpn-status.log
log-append openvpn.log
max-clients 4
verb 3
and one of my client's:
client
proto tcp
dev tun
remote xxx.xxx.xxx.xxx xxxx
ca ca.crt
cert hab-notebook.crt
key hab-notebook.key
resolv-retry infinite
nobind
persist-key
persist-tun
comp-lzo
verb 3
In my modem/router I have added the following:
So, when I connect the client to the server, I can ping 192.168.0.254, but I cannot ping any other IP in the network (for example 192.168.0.110).
Moreover, if i use the tracert command I only seem to find 10.8.0.1 which is the OpenVPN server:
What is strange, is that from the modem/router there is a Trace Route Diagnosis tool, which give the following result when I input the address 10.8.0.10 (IP the OpenVPN client gets when connected):
So, it seems the modem/router is reaching the OpenVPN client through the OpenVPN server (192.168.0.254), but after that nothing...
Furthermore, I read a very nice tutorial in the forum
https://forums.openvpn.net/topic9465.html, with some different methods of connecting the LAN to the OpenVPN, and when I try Method 3, with static routes on a host PC in the LAN (for example route add 10.8.0.0 mask 255.255.255.0 192.168.0.110), I can ping the host (192.168.0.110) from the OpenVPN client.
So, from all the above, I have the feeling that something is wrong with the static route function in the router....
Am I configuring something the wrong way? Is there anything else I can check in order to figure out exactly what is going wrong?