Static Route + VPN Force Internet Traffic Through Tunnel: Yes

  • ATTENTION! As of November 1, 2020, you are not able to reply to threads 6 months after the thread is opened if there are more than 500 posts in the thread.
    Threads will not be locked, so posts may still be edited by their authors.
    Just start a new thread on the topic to post if you get an error message when trying to reply to a thread.

Lynx

Senior Member
I have this setup:

asus router (192.168.1.1) -> modem (192.168.8.1)

If I have OpenVPN set to on and 'Force Internet Traffic Through Tunnel: Yes' (which works the way I want everything to),

is it possible for me to set a static route between 192.168.1.0 and 192.168.8.1 so that I can still access the web gui of my modem?
 

Lynx

Senior Member
My problem is that I do not know how I would.

Should it be something like this under LAN->Route:
Network hostMaskGatewayMetricInterface
192.168.8.1255.255.255.255192.168.8.1?WAN

I can achieve what I want by applying these commands:

ifconfig eth0:0 192.168.8.2 netmask 255.255.255.0
iptables -t nat -l POSTROUTING -o eth0 -j MASQUERADE

This seems to set up a router between my router (192.168.1.1) and modem (192.168.8.1)

Can I not do this using the LAN->Route page on the GUI?
 
Last edited:

Lynx

Senior Member
Ah... any idea what form this should take?

Update: looks like the following works:

route 192.168.8.1 255.255.255.255 net_gateway

Does this seem right?
 
Last edited:

john9527

Part of the Furniture
Does this seem right?
That's right....good searching :)

I assumed that you were using Policy based routing, so adding a 'rule' would work (need to use regular Policy and not Policy Strict).
The route statement you added will work as well.
 

Lynx

Senior Member
Yes - this allows me to avoid policy based routing which I want because I don't like the way the policy based routing makes WAN the default on the router. I prefer that everything on router defaults to VPN, which I think is enabled via Force traffic through tunnel: Yes.
I noticed that Amazon Prime Video does not detect VPN so long as the pushed DNS from NordVPN is used so under LAN DNS Filter I make the global default CleanBrowsing Family and my television clients exceptions that use 'no filtering' so that they go through the pushed NordVPN DNS and Amazon Prime is happy. This seems to work very well and feels like an elegant and simple solution for my needs.
 

Lynx

Senior Member
@john9527 and others - using:
route 192.168.8.1 255.255.255.255 net_gateway
Indeed allows me to connect to my 4G modem over my WAN port when the VPN tunnel is UP, but I have found that if my 4G modem internet is down and the VPN tunnel is down, then I cannot access the GUI of my 4G modem.
What would be the correct route to ensure that I always am able to access my 4G modem (192.168.8.1) over WAN from my ASUS Router (192.168.1.1) regardless of the VPN tunnel state?
 

Similar threads

Latest threads

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top