commit c717a6365c1aecb0e3957f0857a06f2334f99d5d
Author: Matthew Thode <email address hidden>
Date: Mon Feb 9 11:02:58 2015 -0600
replaces enumeration method used to get a list of interfaces
ip_lib was parsing tunnel links incorrectly. We can create interface
names with any character the filesystem supports (not '..', '/', ':').
Given this we do not know what to delimit on so parsing iproute2 output
is probably not a good idea.
I asked the iproute2 devs what the proper way we should get interface
names is and was told NOT to parse iproute2 output but to use something
like sysfs instead. http://www.spinics.net/lists/netdev/msg316577.html
This patch pulls interfaces from sysfs (/sys/class/net) and verifies them
via checking if they are links (bonding creates files for instance and
needs to be skipped).
Currently it is not possible without jumping through a ton of hoops to
access a network namespace without iproute2 or cython, so we use ip to
run find to find the correct sysfs directory. We also only call out to
iproute2 _ONLY_ if needed.
Reviewed: https:/ /review. openstack. org/154128 /git.openstack. org/cgit/ openstack/ neutron/ commit/ ?id=c717a6365c1 aecb0e3957f0857 a06f2334f99d5d
Committed: https:/
Submitter: Jenkins
Branch: master
commit c717a6365c1aecb 0e3957f0857a06f 2334f99d5d
Author: Matthew Thode <email address hidden>
Date: Mon Feb 9 11:02:58 2015 -0600
replaces enumeration method used to get a list of interfaces
ip_lib was parsing tunnel links incorrectly. We can create interface
names with any character the filesystem supports (not '..', '/', ':').
Given this we do not know what to delimit on so parsing iproute2 output
is probably not a good idea.
I asked the iproute2 devs what the proper way we should get interface www.spinics. net/lists/ netdev/ msg316577. html
names is and was told NOT to parse iproute2 output but to use something
like sysfs instead. http://
This patch pulls interfaces from sysfs (/sys/class/net) and verifies them
via checking if they are links (bonding creates files for instance and
needs to be skipped).
Currently it is not possible without jumping through a ton of hoops to
access a network namespace without iproute2 or cython, so we use ip to
run find to find the correct sysfs directory. We also only call out to
iproute2 _ONLY_ if needed.
Change-Id: I07d1d297f07857 d216649cccf7178 96574aac301
Closes-Bug: 1374663