
21 Nov
2004
21 Nov
'04
8:26 p.m.
Wayne Rooney wrote:
On Mon, 22 Nov 2004 19:45, async wrote:
Once the list is ordered, run the data through another loop that takes each piece of data (one subnet at a time) and compares it with the previous piece of data and if they are the same - remove one of the entries.
man uniq
Example; (from metanet, not the real world) 10.0.0.0/8 10.1.0.0/16 10.2.0.0/16 10.10.0.0/16 10.192.0.0/16 uniq or sort -u wouldn't detect any of these but the first entry covers all the other subnets, the second two could have been joined into a /15, etc. It's a little more complicated than just removing exact duplicates. There are probably already tools to do this automatically, I'd check sourceforge or ask the ape/wix people on nznog...