I have 2 networks and I want to build a VPN tunnel between these networks. Currently this is how it looks like:
On the main side, the vpn server is on its own linux device separate from the router! On the secondary side, the vpn client is on the router itself. The router is an OpenWRT router and is intended only for the purpose as a VPN router. I'm having trouble configuring the server and server lan to build a full site to site connection between the two.
Every client in the main network should reach every client in the secondary network and vice versa.
The OpenWRT/openWRT router connects to the main site and it reaches each device in the network (via SSH on the OpenWRT router a ping on for example 10.0.254.254 successful), but no client of this site reaches the main site, no matter which static routes I set. EXCEPT I configure the client that all requests will be redirected to the destination network (redirect-gateway def1).
In this way each connection is forwarded (which is not optimal, because I want to use the local internet connection) and I reach all clients of the secondary network, BUT, Unfortunately, it does not work the other way around. Main Site -> Secondary Site.
No matter what I've tested, a connection from the main site to the sec site I did not manage in the last few days.
many write about how to use iroute, push route and route. I can not find a suitable scenario which does the routing properly. Some say I have to write this into /etc/openvpn/ccd/clientname and some say that it is not needed.
I am getting confused now. I hope for answers that help me to solve this issues. That should not be that hard - although i've already read that wireguard is better on that subject, i would still like to try ovpn
what do I have to do to make it work?
I have already tried this:
https://openwrt.org/docs/guide-user/services/vpn/openvpn/extra#site-to-site https://forum.openwrt.org/t/openvpn-site-to-site-vpn/37259 https://openwrt.org/docs/guide-user/services/vpn/openvpn/client