When I changed netstart(8) in r1.172 to re-add the default route, when
an interface was given as argument, I introduced a regression.
The problem occurs if multiple default routes were previously configured.
In this case executing "route delete default" without argument might
remove the wrong route. Yes, it's a multipath problem.
Since removing an address now remove all the routes attached to it, it
shouldn't be necessary to call "route delete" inside netstart(8).
I'd appreciate if people could test the diff below with their setup and
report back.
Index: netstart
===================================================================
RCS file: /cvs/src/etc/netstart,v
retrieving revision 1.178
diff -u -p -r1.178 netstart
--- netstart 25 Apr 2017 19:17:33 -0000 1.178
+++ netstart 27 Apr 2017 22:26:24 -0000
@@ -170,12 +170,10 @@ ifv6autoconf() {
defaultroute() {
[[ -z $dhcpif ]] && stripcom /etc/mygate | while read gw; do
[[ $gw == @(*:*) ]] && continue
- route -qn delete default >/dev/null 2>&1
route -qn add -host default $gw && break
done
[[ -z $rtsolif ]] && stripcom /etc/mygate | while read gw; do
[[ $gw == !(*:*) ]] && continue
- route -qn delete -inet6 default >/dev/null 2>&1
route -qn add -host -inet6 default $gw && break
done
}