Tuesday, June 25, 2013

The FDB Table

(Warning: highly technical post!)

Working on my project at AIST, I've encountered many problems related to networking and the kernel. One of them is that, when SR-IOV is enabled, bridged networking no longer works. Per my mentor's suggestion, I've posted a bug report onto the Linux kernel's netdev mailing list and I've got many useful replies.

One of them suggested that I add the guest's MAC address to the device's FDB table.
As Greg indicdated, this (== stetting a bridge over a PF or VF in
SRIOV moded) can actually work, if you make sure to use FDB operations
to add the VM unicast MAC to the uplink (the mellanox device) tables,
this is trivial (google for ndo_fdb_add ...) and should work, let us
know if it doesn't.
I had no idea what the FDB table was, but a bit of Googling showed me that the "bridge" utility from the "iproute2" set supports modification of the FDB table. So I've tried sudo bridge fdb add [target mac address] dev [device] on the host and sure enough, it worked!

But what exactly is the FDB table and what is it used for? The only meaningful resource I could find was on the blog "Michael McNamara". According to that post, the FDB table is the Layer 2 version of the ARP table, allowing a switch to know which port to forward a packet to. My guess would be that the FDB tables allows the SR-IOV device to know which PF or VF to forward the packet to.

No comments:

Post a Comment