在我的环境中,桥中有三个 veth:
$ brctl show virbr1
bridge name bridge id STP enabled interfaces
virbr1 8000.52540071337a yes eth1
virbr1-nic
vnet1
我可以得到他们的mac地址:
$ brctl showmacs virbr1
port no mac addr is local? ageing timer
3 52:54:00:25:7a:ab yes 0.00
3 52:54:00:25:7a:ab yes 0.00
3 52:54:00:99:67:68 no 9.15
2 52:54:00:99:d8:05 no 8.48
2 fe:54:00:99:d8:05 yes 0.00
2 fe:54:00:99:d8:05 yes 0.00
但是我怎样才能得到bridge中那些veth的IP地址呢?目前,我可以通过以下方式获取IP地址arp
:还有其他方法可以获得更多详细信息吗?
~$ sudo arp
Address HWtype HWaddress Flags Mask Iface
192.168.252.246 ether 52:54:00:99:d8:05 C virbr1
192.168.252.254 ether 52:54:00:99:67:68 C virbr1
192.168.252.83 ether 52:54:00:99:d8:05 C virbr1
...