Comment 19 for bug 925145

Revision history for this message
James Hogarth (james-hogarth) wrote :

A quick update on this ...

My branch has iproute2 (the ip command) used as a preference, but falls back to the net-tools commands if it's not present to maintain compatibility.

I've added tests to cover both net-tools and iproute2 code paths.

I've fixed up the invalid route_info() tests that ignored that the ipv6 route table appears different to the ipv4 one. I've fixed the ipv6 route table generation to actually generate and parse the routes as opposed to printing current socket information. I've added metric to the route table printed as that's useful to determine the actual path.

For the sake of compatibility the net-tools and iproute2 code paths both produce identical output - obviously it'd be nice in future to provide more detail if iproute2 is installed and providing it, but for the sake of a minimal patch to remove the net-tools dependency this seems the best route.

Last thing I need to add is parsing multiple addresses on a single interface.

Once that is done by my count at least the following bugs will be taken care of by the merge: 925145, 1616616 and 1401965 ...