PR241792 dhclient trivial fix + MFC request
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 05 Oct 2022 08:07:47 UTC
TLDR cloud providers expect FreeBSD to behave like linux, and assign a default interface route to a /32 lease. Without this, images start up without a default interface. Very inconvenient. Index: sbin/dhclient/dhclient-script =================================================================== --- sbin/dhclient/dhclient-script (revision 354408) +++ sbin/dhclient/dhclient-script (working copy) @@ -173,6 +173,9 @@ if [ "$new_ip_address" = "$router" ]; then route add default -iface $router >/dev/null 2>&1 else + if [ "$new_subnet_mask" = "255.255.255.255" ]; then + route add "$router" -iface "$interface" >/dev/null 2>&1 + fi route add default $router >/dev/null 2>&1 fi fi https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=241792 for more details. Would be great to have this in CURRENT and MFC'd to 13.x and 12.x too if possible. A+ Dave