Re: sockstat & jid patch

From: Mateusz Guzik <mjguzik_at_gmail.com>
Date: Wed, 16 May 2012 11:59:09 +0200
On Wed, May 16, 2012 at 03:12:50PM +1200, Andrew Thompson wrote:
> Hi,
> 
> 
> Here is a quick patch to limit the sockstat output to a specific jail
> id, this is useful to verify which sockets a jail has open. A jid of 0
> will show the host system.
> 
> This will result in an extra syscall per socket when -j is set but I
> do not think warrants a process cache.
> 
> Any objections?

I think you should extend struct xsocket with jid. Unfortunately this
breaks ABI so MFC is not possible.

That being said, IMHO this patch can be committed to -STABLE if this
feature is that important, but -CURRENT should get implementation
mentioned earlier.

I can try to write a patch in a couple of days (or this evening if I
find the time).

-- 
Mateusz Guzik <mjguzik gmail.com>
Received on Wed May 16 2012 - 07:59:19 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:27 UTC