Date: Mon, 2 Dec 2019 09:03:50 -0800 From: Michael Sierchio <kudzu@tenebras.com> To: FreeBSD Questions <freebsd-questions@freebsd.org> Subject: Re: Network Aggregation Message-ID: <CAHu1Y71J3iEF_4LzsumBj3b4p2cQB_8HDhEHXqp7xZkcC%2BNJCg@mail.gmail.com> In-Reply-To: <20191202060719.000059a1@seibercom.net> References: <20191202060719.000059a1@seibercom.net>
next in thread | previous in thread | raw e-mail | index | archive | help
The python library netaddr? import netaddr import sys cidr_list =3D [] for line in sys.stdin: cidr_list.append(netaddr.IPNetwork(line)) ec2_nets =3D netaddr.cidr_merge(cidr_list) for net in ec2_nets: sys.stdout.write(str(net)+'\n') On Mon, Dec 2, 2019 at 3:07 AM Jerry <jerry@seibercom.net> wrote: > I am looking for a program that will automate combining IP addresses, > usually referred to as aggregation. I have been doing it by hand, and > it is a real PIA. > > Thanks! > > -- > Jerry > --=20 "Well," Brahm=C4=81 said, "even after ten thousand explanations, a fool is = no wiser, but an intelligent person requires only two thousand five hundred." - The Mah=C4=81bh=C4=81rata
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAHu1Y71J3iEF_4LzsumBj3b4p2cQB_8HDhEHXqp7xZkcC%2BNJCg>