We offer ASN analytics reports capability for FastNetMon Advanced, which implements native support for per ASN bandwidth calculation and stores it into InfluxDB or Clickhouse in pre-calculated format.
It is implemented in the following way for outgoing traffic:
sudo fcli show asn_counters_v4 outgoing 28026 4810 pps 38 mbps 52374 3028 pps 25 mbps 52376 2345 pps 17 mbps 15169 1769 pps 10 mbps 20940 1285 pps 8 mbps 2906 1075 pps 8 mbps 3356 484 pps 3 mbps 15133 412 pps 3 mbps 16509 633 pps 2 mbps
And in the following way for incoming traffic:
sudo fcli show asn_counters_v4 incoming 28026 4810 pps 38 mbps 52374 3028 pps 25 mbps 52376 2345 pps 17 mbps 15169 1769 pps 10 mbps 20940 1285 pps 8 mbps 2906 1075 pps 8 mbps 3356 484 pps 3 mbps 15133 412 pps 3 mbps 16509 633 pps 2 mbps
To enable it, you will needthe following options:
sudo fcli set main enable_asn_counters enable sudo fcli set main asn_lookup enable sudo fcli commit
To get more than 10 ASNs in the top ASN output, you can use the following environment variable:
sudo HOST_COUNTERS_MAX_HOSTS=25 -i fcli show asn_counters_v4
It can read ASNs from Netflow, or we can use our own mapping tables (more details below) to enrich it, and it’s included inthe default installation of FastNetMon.
In some cases router may report wrong ASNs in network telemetry about observed traffic. In this case, you can use this flag to force overwrite ASN information from telemetry by ASNs retrieved using our own IP to ASN mapping table:
sudo fcli set main force_asn_lookup true sudo fcli commit
After this, restart FastNetMon:
sudo fcli commit
Our default installation of visual traffic includes top ASN graphs.
If you have any issues with IP to ASN number conversion, you can check our tool, which makes queries to our internal ASN database:
sudo fcli show ip_asn 11.22.33.44
Starting from 2.0.362, you can get a list of networks (IPv4+IPv6) which belong to a specific ASN using our own daily updated dataset:
sudo fcli show asn_networks 65536
IP to ASN mapping tables
FastNetMon distribution includes mapping tables required to obtain ASN numbers from IPv4 or IPv6 addresses. We have an automatic cron task which runs the command /opt/fastnetmon/app/bin/fill_dictionaries daily and keeps these mapping tables up to date.
These files are stored in the folder /var/cache/fastnetmon/ under the names prefix_asn_mapping_ipv4.json and prefix_asn_mapping_ipv6.json.
If you would like to add your own IP prefix to ASN information to IPv4 or IPv6 tables, you can create the following files in the folder /var/cache/fastnetmon: prefix_asn_mapping_ipv4_user.json and prefix_asn_mapping_ipv6_user.json, and FastNetMon will load them after loading our regular mapping files.
Example format used in these files for IPv4:
{"asn":123,"prefix":"1.1.1.1/21"}
{"asn":456,"prefix":"2.2.2.2/24"}
And for IPv6:
{"asn":555,"prefix":"dead:beef::0000/48"}
{"asn":777,"prefix":"beef:dead::0000/32"}

