Re: Problem with iflink in netns
From: Cong Wang <hidden>
Date: 2014-05-13 18:20:59
On Tue, May 13, 2014 at 8:39 AM, Stephen Hemminger [off-list ref] wrote:
There have been a couple of bugzilla reports already about cases where a macvlan or vlan is moved into another namespace. In these cases the parent device ifindex (iflink) is no longer valid. Normally it is not a big issue, until another device is created using the ifindex of the parent Does anyone have a suggested fix? Marking iflink as 0 won't work then the devices no longer appear as slaves. Another possibility would be to make block creation of device where ifindex matches existing iflink of other devices; but this would slow down device creation.
I have a pending fix which converts ->iflink to a pointer to struct net_device, this is a suggested fix from Ben. And so, when the lower device is not in the same namespace with the upper device, we should not display the iflink information. I will send it soon.