Topic: openvpn client

in a configuration with a openvpn client on a router, how to reach the devices connected to the router?

To explain:
lan 1: 192.168.1.x
lan 2: 192.168.0.x

vpn server on pc connected to lan1
vpn client  on router openwrt on lan2
ipcamera 192.168.0.122 connected to lan2

from pc i can connect to the router but i cant reach the ipcamera

Re: openvpn client

A picture if the network is always helpful.

3 (edited by gamba47 2017-08-12 03:27:02)

Re: openvpn client

Take a look at this
https://community.openvpn.net/openvpn/wiki/RoutedLans

OpenVPN need to know how to send you to the other network

In the Router on Lan1 you need to see a route sending to tun0.
You can check router doing this:

route -n

Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         x.x.x.x              0.0.0.0         UG    20     0        0 eth0.2
0.0.0.0         192.168.1.1     0.0.0.0         UG    30     0        0 eth0.3
10.18.0.0       10.18.0.2       255.255.255.0   UG    0      0        0 tun0
10.18.0.0       0.0.0.0         255.255.255.0   U     0      0        0 tun0
192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0 br-lan
192.168.1.0     0.0.0.0         255.255.255.0   U     30     0        0 eth0.3
192.168.1.1     0.0.0.0         255.255.255.255 UH    30     0        0 eth0.3
192.168.11.0    10.18.0.2       255.255.255.0   UG    0      0        0 tun0       <---- this line is the important!
xxx.xxx.xxx.xxx     0.0.0.0         255.255.255.248 U     20     0        0 eth0.2

In this case. 192.168.11.x is going to tun0 (the vpn interface)

Best regards

gamba47