I really love this firmware. I've been able to find simple solutions for every situation I've come across so far.
My most recent issue was that I needed to set a specific DNS only for clients using VPN. I already have the OpenVPN client working on my router, and I've specified that only certain IP addresses on my LAN are to use the VPN (basically my Roku and other media servers).
At first I thought it was as simple as setting the DNS on the OpenVPN server and then setting "Exclusive" on the router's OpenVPN client. Well that didn't work well at all. It turns out that the DNS setting on the router affects only the DNS for the router, not the router clients (though indirectly it affects them too if they use the router for DNS). And even that is weird because the router was sending its DNS queries over the WAN, not the VPN, probably because I have "Redirect Internet Traffic" set to "Policy Rules" instead of "All Traffic" (though this still happened even if I listed the local IP of the router as one that should use VPN).
Since the VPN DNS I want to use (getflix.com.au) is restricted to a single user specified IP, and the allowed IP is that of my VPN server, the DNS wasn't working correctly.
So how was I to set the DNS for the router and most clients to be the DNS provided by my ISP, but set a different DNS for my VPN clients?
Turned out it was super easy. First I set the router's OpenVPN client "Accept DNS Configuration" to "Disabled". This leaves the router (which the clients default to using for DNS) setup with the DNS settings provided by the ISP.
Then I added these lines to file /jffs/configs/dnsmasq.conf.add:
dhcp-host=12:34:56:78:9A:BC,set:vpnhost
dhcp-option=tag:vpnhost,6,AA.BB.CC.DD
Where 12:34:56:78:9A:BC is the MAC of one of the VPN clients (I can add multiple dhcp-host lines as needed), and AA.BB.CC.DD is the DNS I want the VPN clients to use.
Rebooted and it worked perfectly. Awesome! Love this firmware.
My most recent issue was that I needed to set a specific DNS only for clients using VPN. I already have the OpenVPN client working on my router, and I've specified that only certain IP addresses on my LAN are to use the VPN (basically my Roku and other media servers).
At first I thought it was as simple as setting the DNS on the OpenVPN server and then setting "Exclusive" on the router's OpenVPN client. Well that didn't work well at all. It turns out that the DNS setting on the router affects only the DNS for the router, not the router clients (though indirectly it affects them too if they use the router for DNS). And even that is weird because the router was sending its DNS queries over the WAN, not the VPN, probably because I have "Redirect Internet Traffic" set to "Policy Rules" instead of "All Traffic" (though this still happened even if I listed the local IP of the router as one that should use VPN).
Since the VPN DNS I want to use (getflix.com.au) is restricted to a single user specified IP, and the allowed IP is that of my VPN server, the DNS wasn't working correctly.
So how was I to set the DNS for the router and most clients to be the DNS provided by my ISP, but set a different DNS for my VPN clients?
Turned out it was super easy. First I set the router's OpenVPN client "Accept DNS Configuration" to "Disabled". This leaves the router (which the clients default to using for DNS) setup with the DNS settings provided by the ISP.
Then I added these lines to file /jffs/configs/dnsmasq.conf.add:
dhcp-host=12:34:56:78:9A:BC,set:vpnhost
dhcp-option=tag:vpnhost,6,AA.BB.CC.DD
Where 12:34:56:78:9A:BC is the MAC of one of the VPN clients (I can add multiple dhcp-host lines as needed), and AA.BB.CC.DD is the DNS I want the VPN clients to use.
Rebooted and it worked perfectly. Awesome! Love this firmware.