1
0
Fork 0
mirror of https://github.com/pavel-odintsov/fastnetmon synced 2024-06-06 06:26:39 +02:00
fastnetmon-rewritten/src/scripts
Pavel Odintsov 1fdde91cbb Fixed bunch of paths to old versions of FNM 2017-12-03 21:22:11 +00:00
..
README.md Fixed bunch of paths to old versions of FNM 2017-12-03 21:22:11 +00:00
bgp_network_collector.py Fix typo 2015-06-23 17:10:26 +03:00
bgp_network_retriever.py Add script for collection subnets from route servers 2015-06-23 16:52:16 +03:00
build_any_package.pl Fixed bunch of paths to old versions of FNM 2017-12-03 21:22:11 +00:00
build_libary_bundle.pl Fix exec flag for fastnetmon client. Closes #398 2015-09-05 22:59:23 +03:00
enable_passthrough_for_pcie_nic_to_kvm_vm.pl Add script for PCI passthourgh configuration 2015-05-14 13:16:35 +03:00
exabgp_network_collector.conf Add script for collection subnets from route servers 2015-06-23 16:52:16 +03:00
fastnetmon_notify.py notify script using python 2015-09-10 19:47:05 -03:00
install_binary.pl Move installer script to scripts instead of src 2015-08-25 20:01:00 +03:00
notify_with_slack.sh Added a script for Slack notifications called notify_with_slack.sh 2016-08-09 18:56:35 +01:00
reformat_code_with_clang_format.sh Add script for code reformatiing 2015-05-15 13:50:50 +03:00
reset_redis_stats Move redis reset script to scripts folder 2015-06-17 11:42:49 +03:00

Here you could find nice scripts for subnet's collection from the BGP router server

  • Clone ExaBGP master's repository:
# yum/apt-get install -y python-pip
pip install exabgp
  • Download configs and scripts:
wget https://raw.githubusercontent.com/pavel-odintsov/fastnetmon/master/src/scripts/exabgp_network_collector.conf -O/etc/exabgp_network_collector.conf
wget https://raw.githubusercontent.com/pavel-odintsov/fastnetmon/master/src/scripts/bgp_network_retriever.py -O/usr/local/bin/bgp_network_retriever.py

wget https://raw.githubusercontent.com/pavel-odintsov/fastnetmon/master/src/scripts/bgp_network_collector.py -O/usr/local/bin/bgp_network_collector.py

chmod +x /usr/local/bin/bgp_network_retriever.py /usr/local/bin/bgp_network_collector.py
  • Run ExaBGP:
cd /usr/src/exabgp
env exabgp.log.level=DEBUG exabgp.daemon.user=root exabgp.tcp.bind="0.0.0.0" exabgp.tcp.port=179 exabgp.daemon.daemonize=false exabgp.daemon.pid=/var/run/exabgp.pid exabgp.log.destination=/var/log/exabgp.log exabgp /etc/exabgp_network_collector.conf
  • Wait few minutes while all announces received (depends on router server size)
  • Retrieve learned networks from database (/var/lib/bgp_network_collector.db): python /usr/local/bin/bgp_network_retriever.py