[Bridge] physical interface on a bridge

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



----- Original Message ----- 
From: "Stephen Hemminger" <shemminger@xxxxxxxx>


>
> The old way is to do ioctl() SIOCDEV_PRIVATE with BRCTL_GET_BRIDGES
> and that gives a table of ifindices, you can use that to map port -> 
> ifindex -> etherdevice
>
> Newer way is to look in directory:
> /sys/class/net/brX/brif
> It has symlinks to the devices that are being bridged.
> /sys/class/net/eth0/brport/port_id
> contains the portid of eth0 in what ever bridge it is in.
>

Works perfectly.
Thanks

Joergen 


[Index of Archives]     [Netdev]     [AoE Tools]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]     [Video 4 Linux]

  Powered by Linux