yellow team mailing list archive
-
yellow team
-
Mailing list archive
-
Message #00691
Re: lxc-ip script
Sory, my original email had an explanation, which I somehow cut
from the final email:
The simple solution would be to use lxc-attach to call ifconfig in the
container. lxc-attach does not work yet because some namespaces do not
support it. However, /proc/self/ns/net exists. It can be used to
switch to the container's network namespace, and then use
ioctl(SIOCGIFADDR) on the result of socket(PF_INET, SOCK_DGRAM, IPPROTO_IP).
See setns(2).
-serge
Follow ups
References