Subject: bin/34640: netstat is utterly broken
To: None <gnats-admin@netbsd.org, netbsd-bugs@netbsd.org>
From: None <mlelstv@serpens.de>
List: netbsd-bugs
Date: 09/27/2006 12:30:00
>Number: 34640
>Category: bin
>Synopsis: netstat is utterly broken
>Confidential: no
>Severity: serious
>Priority: high
>Responsible: bin-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Sep 27 12:30:00 +0000 2006
>Originator: Michael van Elst
>Release: NetBSD 3.1_RC1
>Organization:
--
Michael van Elst
Internet: mlelstv@serpens.de
"A potential Snark may lurk in every tree."
>Environment:
System: NetBSD fud 4.0_BETA NetBSD 4.0_BETA (FUD) #0: Sun Sep 24 19:51:39 CEST 2006 mlelstv@henery:/home/netbsd4/obj/home/netbsd4/src/sys/arch/i386/compile/FUD i386
Architecture: i386
Machine: i386
>Description:
When netstat(1) was changed to use a sysctl() interface instead
of peeking at /dev/mem the task was never completed.
E.g. netstat -r doesn't print the refcnt and pksent columns.
Destination Gateway Flags Refs Use Mtu Interface
10.24.5/24 link#1 UC - wm0
and it segfaults when using the -P option. Reason is that it doesn't
open then kvm interface anymore but relies on it when printing
the data (that part hasn't been changed yet).
And all this was pulled up to netbsd-4.
>How-To-Repeat:
Run netstat -rn or netstat -P xxx on a netbsd-4 system.
>Fix:
>Unformatted: