<p>I'm trying to locate a performance issue that might be network related. Therefore I want to inspect all packets entering and leaving a pod.</p>

<p>I'm on kubernetes 1.8.12 on GKE. I ssh to the host and I see the bridge called <code>cbr0</code> that sees all the traffic. I also see a ton of interfaces named like <code>vethdeadbeef@if3</code>. I assume those are virtual interfaces that are created per container. Where do I look to find out which interface belongs to which container, so I can get all a list of all the interfaces of a pod. </p>

<p>If you have <code>cat</code> available in the container, you can compare the interface index of the containers <code>eth0</code> with those of the <code>veth*</code> devices on your host. For example:</p>

<pre><code># grep ^ /sys/class/net/vet*/ifindex | grep ":$(docker exec aea243a766c1 cat /sys/class/net/eth0/iflink)"
/sys/class/net/veth1d431c85/ifindex:92
</code></pre>

<p><code>veth1d431c85</code> is what your are looking for.</p>
