[Bug 172532] service routing restart always fails

From: <bugzilla-noreply_at_freebsd.org>
Date: Sun, 22 Jan 2023 20:06:52 UTC

Graham Perrin <grahamperrin@freebsd.org> changed:

           What    |Removed                     |Added
                 CC|                            |grahamperrin@freebsd.org
           Keywords|patch                       |
            Summary|[rc] [patch] service        |service routing restart
                   |routing restart always      |always fails
                   |fails                       |
           Assignee|bugs@FreeBSD.org            |net@FreeBSD.org
           Severity|Affects Only Me             |Affects Many People

--- Comment #4 from Graham Perrin <grahamperrin@freebsd.org> ---
I can't guess whether the patch here is still applicable, I do know that I'm
always left without Internet connectivity after running the command: 

service routing restart


root@mowa219-gjp4-8570p-freebsd:~ # uname -KU
1400078 1400078
root@mowa219-gjp4-8570p-freebsd:~ # service routing restart
delete host gateway lo0
default              -fib 0   done
delete host ::1: gateway lo0
delete net fe80::: gateway ::1
delete net ff02::: gateway ::1
delete net ::ffff: gateway ::1
delete net :: gateway ::1
delete net default: gateway 2001:470:1f1c:a0::1
add host gateway lo0
add host ::1: gateway lo0
add net fe80::: gateway ::1
add net ff02::: gateway ::1
add net ::ffff: gateway ::1
add net :: gateway ::1
add net default: gateway 2001:470:1f1c:a0::1
root@mowa219-gjp4-8570p-freebsd:~ # 


A longhand workaround that I found, through many hours of trial and error (my
current use case includes em(4) and iwn(4), with wired network service nearly
always available): 

ls /var/run/resolvconf/interfaces/ ; route delete default ; ifconfig wlan0 down
&& ifconfig em0 down && sleep 5 ; ls /var/run/resolvconf/interfaces/ ; ifconfig
em0 up && sleep 15 ; ls /var/run/resolvconf/interfaces/ ; cat /etc/resolv.conf
; ping -c 2 -6 freshports.org

You are receiving this mail because:
You are the assignee for the bug.