Date: Wed, 14 Mar 2007 15:48:54 +0100 (BST) From: Robert Watson <rwatson@FreeBSD.org> To: Julian Elischer <julian@elischer.org> Cc: =?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?= <des@des.no>, FreeBSD Current <current@freebsd.org> Subject: Re: netstat wierdness? Message-ID: <20070314154728.Y47292@fledge.watson.org> In-Reply-To: <45F706A2.5020106@elischer.org> References: <45F388D4.2080900@elischer.org> <45F45172.8070601@elischer.org> <86r6rt6z27.fsf@dwp.des.no> <45F706A2.5020106@elischer.org>
next in thread | previous in thread | raw e-mail | index | archive | help
This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --0-348664937-1173883734=:47292 Content-Type: TEXT/PLAIN; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE On Tue, 13 Mar 2007, Julian Elischer wrote: > Dag-Erling Sm=F8rgrav wrote: >> Julian Elischer <julian@elischer.org> writes: >>> answering myself.. comes from having options LOCK_PROFILING in my kerne= l.=20 >>> adding the same to /etc/make.conf and recompiling netstat and libkvm=20 >>> helped. (not sure if both are needed) >>=20 >> This is very bad. LOCK_PROFILING should have no visible effect on=20 >> userland. That is precisely what xinpcb, xunpcb, xtcpcb etc. are for: t= o=20 >> isolate userland from kernel structures. They should not contain any lo= cks=20 >> or anything else which would be affected by LOCK_PROFILING or other kern= el=20 >> options. > > sockstat actually told me that all those were the wrong size, so apparent= ly=20 > they change size too.(!?) > > I haven't gone to look at their definition yet, but as you say, it sounds= =20 > like something was done wrong. The x* structures in netinet are not correctly implemented, and do incorpor= ate=20 kernel data structures. I've been meaning to fix that for ages, but haven'= t=20 had time. In the mean time, we should continue to avoid having the size of= =20 kernel data structures vary with kernel options. This is also important so= =20 that you can use /dev/kmem on core dumps, etc, so while fixing the x*=20 structures for netinet is important, it doesn't eliminate the need to avoid= =20 variable data structure sizes. Robert N M Watson Computer Laboratory University of Cambridge --0-348664937-1173883734=:47292--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070314154728.Y47292>