[lxc-users] Determine which vethXXX interface is connected to particular LXC container
Rahul Rege
rahul.rege at sungardas.com
Tue Feb 9 03:31:30 UTC 2016
yea, as suggested by Luis, set it beforehand so you know what connects
where.
if you are using the default stuff then on host run run :
ethtool -S <vethif>
Which will give you the ifindex of veth peer inside container which can be
matched using :
lxc-attach -n <name> -s NETWORK -- /sbin/ip link show eth0
You'd need to iterate though through all and then match them up. Or may be
there could be an easier way which'd directly give you that
Thanks
Rahul Rege
On Tue, Feb 9, 2016 at 6:32 AM, Luis Michael Ibarra <
michael.ibarra at gmail.com> wrote:
> Hi,
>
> In /var/lib/lxc/[container]/config, use lxc.network.veth.pair = [name] to
> assign a particular name for a veth.
>
> Regards,
>
>
>
>
>
> 2016-02-08 19:36 GMT-05:00 tapczan <tapczan at unx.pl>:
>
>> Hello
>>
>> Is there any way to determine which vethXXX interface is connected to
>> a particular running LXC container?
>>
>> Or even more precisely, which vethXXX interface is connected to a
>> particular interface inside LXC container, eg.:
>>
>> vethL6OCF0 <-> container1: eth0
>> vethGMSWTE <-> container1: eth1
>> vethMEG0ME <-> container2: eth0
>>
>> Is it possible to get that kind of information?
>>
>> Thanks.
>>
>> --
>> Best Regards
>> Robert J. (tapczan)
>> _______________________________________________
>> lxc-users mailing list
>> lxc-users at lists.linuxcontainers.org
>> http://lists.linuxcontainers.org/listinfo/lxc-users
>
>
>
>
> --
> Luis Michael Ibarra
>
> _______________________________________________
> lxc-users mailing list
> lxc-users at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/lxc-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20160209/59e8a7c2/attachment.html>
More information about the lxc-users
mailing list