Re:The lack of a good command line way to sort IPv6 addresses
by Ekaros on Wednesday May 21, 2025 @09:40AM
(#44051338)
Also IPv4 does have some allowed weird notations. Like 127.1 is equal to 127.0.0.1 or can represent it as decimal number. Or hex notation. Or some tools support octal...
Which some also do not sort nicely. Specially when combined.
Re:The lack of a good command line way to sort IPv6 addresses
by andix on Wednesday May 21, 2025 @11:19AM
(#44052446)
Those representations for 127.0.0.1 work too, just try to ping them:
0177.1 (octal, 2 stripped 0s, decimal one)
017700000001 (octal)
2130706433 (decimal)
127.0.0x1
0x7f.0x0.0x0.0x1
127.000.000.001
Re:The lack of a good command line way to sort IPv6 addresses
by monster_truck on Wednesday May 21, 2025 @09:48AM
(#44051430)
If you think these are weird I have bad news about ipv6
Re:The lack of a good command line way to sort IPv6 addresses
by mystified5016 on Wednesday May 21, 2025 @11:13AM
(#44052366)
Anecdata but I have never seen shortened IPv4 notation. I've only ever seen the full decimal notation.
Re:The lack of a good command line way to sort IPv6 addresses
by nimbius on Wednesday May 21, 2025 @09:47AM
(#44051418)
the sheer size of ipv6 alone means a lot of the 'old ways' get left behind.
"sorting by ip" for example is eschewed in favor of router advertisements where hosts pick their own subnet delegations.
one of the ways you track all of this is using a dhcp6 server with dns updates turned on. the subnet delegation is picked up by the client, which in turn pings dhcp6 and reports its IP for update in the DNS server.
This post also highlights a major thing I discovered when deploying and using IPv6, which is that you don't "Lift and shift" IPv4 to IPv6.
This is one of the reason its hard to deploy, because people cannot use the same IPv4 concepts to IPv6. For unknown reason they do, they will find the same problem they had with v4.