[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAHA+R7P_uqyuP4BR=zCjH1=m0pSTX3KPQd9bTuLARUa_KN0rjg@mail.gmail.com>
Date: Wed, 18 Feb 2015 10:55:54 -0800
From: Cong Wang <cwang@...pensource.com>
To: mthode@...ode.org
Cc: Stephen Hemminger <stephen@...workplumber.org>,
netdev <netdev@...r.kernel.org>
Subject: Re: getting a list of naked interface names from iproute2
On Tue, Feb 17, 2015 at 8:45 PM, Matthew Thode <mthode@...ode.org> wrote:
> Do you happen to know a way to request it for a specific namespace?
> going over the links in /sys/class/net only gets you the current
> namespace (was the easiest method to do in python2.7).
The interface is not friendly. You need to open an fd which points to the
netns proc file or the pid of a task inside the namespace, take a look at how
`ip netns exec` is implemented.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists