Multi instance OpenVPN binds incorrect DNS servers from other instance tunnels

I don't think you need the VPR. You can just create a rule in /etc/config/network and a static route for 0.0.0.0/0 to be forwarded to the VPN that you want to use.

config rule
        option in 'lan'
        option src '192.168.1.61/32'
        option lookup '100'

config route
        option interface 'vpn'
        option target '0.0.0.0'
        option netmask '0.0.0.0'
        option metric '200'
        option table '100'

That is one example. Create more tables (could be 101, 102, etc). Depending to which table the IP is assigned in the rule, you will use that tunnel.

You didn't use preformatted text and the code is hard to read...

1 Like