Is there a way to dynamically update the gateway ip address on the dhcp interface along with ip address in the load balancing rules?

http://www.openbsd.org/faq/pf/pools.html has a sample pf.conf file

ext_if1 = "fxp0"
ext_if2 = "fxp1"
ext_gw1 = "68.146.224.1"
ext_gw2 = "142.59.76.1"

pass out on $ext_if1 route-to ($ext_if2 $ext_gw2) from $ext_if2 to any


In this pass out rule it's my understanding that if the $ext_if2 or fxp1 ip address changes the firewall rules will be updated automatically. However, it looks to me like the $ext_gw2 will not be updated if it changes since the variable points to an explicit ip address. Is there a way to update the gateway ip address for that interface without writing some script to modify the pf.conf file and then reload the rule set?

Thank You.

Reply via email to