WAN has higher priority over VPN client. Regardless of the sequence of rule creation, higher priority rule will always sorted on top in GUI and applied first. There should be no issue for OP requirement.@Mikey3 And to add just one last tidbit to this... make sure your exception rule is located at the top of your rules list, as rules are processed top-down... So your more global VPN rule should be #2.
Thanks for this @chongnt ... but if something starts acting wonky, it's probably best to sort them in order of importance top-down... as a best practice.WAN has higher priority over VPN client. Regardless of the sequence of rule creation, higher priority rule will always sorted on top in GUI and applied first. There should be no issue for OP requirement.
VPN Director
Third party firmware for Asus routers (newer codebase) - RMerl/asuswrt-merlin.nggithub.com
Yes, it seems there is no straight forward way of doing this. You can split LAN and WiFi to different subnet, say manually assign IP for your LAN devices to say 192.168.50.2 -192.168.50.127 (192.168.50.0/25) and let WiFi devices get their IP from DHCP pool 192.168.50.129 - 192.168.50.254 (192.168.50.128/25). This way you can do it with two rules in VPN Director.A related question about VPN Director:
Is there any way to specify that traffic from all WiFi-connected devices go through a VPN (but devices wired to the LAN continue to go through the WAN interface)? The VPN Director GUI only seems to allow client definition by IP, not by interface.
Thanks.
In 386.9, there is no option to sort it manually. I suppose the same for 388.x? The rules are automatically sorted by Interface priority as we create it.Thanks for this @chongnt ... but if something starts acting wonky, it's probably best to sort them in order of importance top-down... as a best practice.
Jeez... you're absolutely right. Maybe I was confusing the vpn director with something else where you could change its order. Thank you!In 386.9, there is no option to sort it manually. I suppose the same for 388.x? The rules are automatically sorted by Interface priority as we create it.
@chongntYes, it seems there is no straight forward way of doing this. You can split LAN and WiFi to different subnet, say manually assign IP for your LAN devices to say 192.168.50.2 -192.168.50.127 (192.168.50.0/25) and let WiFi devices get their IP from DHCP pool 192.168.50.129 - 192.168.50.254 (192.168.50.128/25). This way you can do it with two rules in VPN Director.
Another option I can think of is use Guest Network with YazFi addons. It has option to route it over VPN.
GitHub - jackyaz/YazFi: Feature expansion of guest WiFi networks on AsusWRT-Merlin, including SSID -> VPN, separate subnets per guest network, pinhole access to LAN resources (e.g. DNS) and more!
Feature expansion of guest WiFi networks on AsusWRT-Merlin, including SSID -> VPN, separate subnets per guest network, pinhole access to LAN resources (e.g. DNS) and more! - jackyaz/YazFigithub.com
Thanks. Much appreciatedClick on Add new rule in VPN director. Choose your VPN client in the interface section and add the clients you want to go through the VPN.
You should be able to set 192.168.50.0/24 as a choice instead of one client per rule. Name that rule "all clients" or something.
Then add a second rule with the client you want to go through the WAN interface
View attachment 47611
View attachment 47612
Great. Thanks@Mikey3 And to add just one last tidbit to this... make sure your exception rule is located at the top of your rules list, as rules are processed top-down... So your more global VPN rule should be #2.
Not sure, but you can add several instances of VPN's. And set up rules for each one, so if one goes down 2nd comes as backup and so forth.A question regarding VPN Director.
Does it automatically re-connect to the VPN after it goes down and comes back on again? Or does it continue to stay disconnected?
I've read that the normal behaviour for Asus routers are that it stays disconnected: https://www.asus.com/en/support/FAQ/1011232/
This is a huge problem for me. I don't need a killswitch, as long as VPN is on 99% of the time I'm fine as I want to have internet connection no matter what. But if it somehow goes down for a while, I would want it to automatically re-connect when the VPN is online again. Does VPN Director achieve this?
Alright that's a shame, perhaps someone else knows otherwise I will be forced to go with OpenWRT because you can scheduele wireguard-watchdog every few mintues to check. Seems there is no similar feature for Asus if the VPN Client stays disconnected even when the VPN goes back online again.Not sure, but you can add several instances of VPN's. And set up rules for each one, so if one goes down 2nd comes as backup and so forth.
Alright that's a shame, perhaps someone else knows otherwise I will be forced to go with OpenWRT because you can scheduele wireguard-watchdog every few mintues to check. Seems there is no similar feature for Asus if the VPN Client stays disconnected even when the VPN goes back online again.
@RMerlin can a vpn-watchdog be implemented that re-connects the client if it's been disconnected?
#!/bin/sh
if [ -z "$(pidof vpnserver1)" ]
then
service restart_vpnserver1
fi
cru l
cru a RestartVPNCliente1 "30 5 * * * service restart_vpnclient1"
cru a RestartVPNCliente2 "40 5 * * * service restart_vpnclient2"
#!/bin/sh
if [ -z "$(pidof vpnclient2)" ]
then
service restart_vpnclient2
fi
cru a CheckVPNClient2 "* * * * * /jffs/scripts/vpn_client2-watchdog.sh"
It's the whole reason I wrote VPNMON-R2. Let me know if you have any questions... This will make your connection stay up 100% of the time... 99% wasn't good enough for me.A question regarding VPN Director.
Does it automatically re-connect to the VPN after it goes down and comes back on again? Or does it continue to stay disconnected?
I've read that the normal behaviour for Asus routers are that it stays disconnected: https://www.asus.com/en/support/FAQ/1011232/
This is a huge problem for me. I don't need a killswitch, as long as VPN is on 99% of the time I'm fine as I want to have internet connection no matter what. But if it somehow goes down for a while, I would want it to automatically re-connect when the VPN is online again. Does VPN Director achieve this?
Welcome To SNBForums
SNBForums is a community for anyone who wants to learn about or discuss the latest in wireless routers, network storage and the ins and outs of building and maintaining a small network.
If you'd like to post a question, simply register and have at it!
While you're at it, please check out SmallNetBuilder for product reviews and our famous Router Charts, Ranker and plenty more!