[TriLUG] IPv6 equivalent to dhclient list
Alan Porter
porter at trilug.org
Tue Jan 6 22:46:40 EST 2015
My current first-pass experiment:
- Read the /var/lib/dnsmasq.leases for lease+MAC+IPv4+hostname
- Run "ip -6 neighbor show" for MAC+IPv6
- Correlate MAC addresses.
- Show it all in a table, using dnsmasq leases as the master.
So I am looping over the IPv4 addresses and then looking for
IPv6 addresses with matching MAC addresses. The disadvantage
of that logic is that an IPv6-only host will not show up in the
list.
Overall, it's hard to predict which hosts will have IPv6 addresses
and which will not. It just has to do with which hosts have been
doing IPv6 stuff recently.
It's also weird to see that a few hosts have IPv6 addresses in the
fe80::0/10 (link-local) range.
And weirdest of all, my MacBook has two 2001::0/16 addresses! OSX
"ifconfig" says that one of them is "autoconf" and the other is
"autoconf temporary". I was NOT expecting that!
Alan
More information about the TriLUG
mailing list