netstat gets the information from:
/proc/net/tcp and /proc/net/udp
The trick must be to make this part of the /proc tree fully visible at
the host level.
How I do that is a complete mystery!
My vservers are skeletons containing only the minimum needed for the
service running in the vserver. Few (none) will have netstat available
to run via 'vserver exec' and its friends.
Therefore the need to monitor them from the host.
Greetings to all
Allan
On 06/05/13 18:38, Ghislain wrote:
> would be curious too,
>
> I tried
>
> sudo ncontext --migrate --nid 1 -- netstat -nlp
>
> sudo chcontext --silent --ctx 1 netstat -nlp
>
>
> but none give me all the sockets :), the closer i got was:
>
> sudo vsomething vserver --running -- exec netstat -nlp|sort
>
> perhaps there is not an observer context for network.
>
>
> Ghislain.
>
Received on Mon May 6 18:54:15 2013