pierky / arouteserver

A tool to automatically build (and test) feature-rich configurations for BGP route servers.
https://arouteserver.readthedocs.org/
GNU General Public License v3.0
284 stars 46 forks source link

Option "-3" not supported in bgpq4, results in Errors at the script #95

Closed stkonst closed 2 years ago

stkonst commented 2 years ago

Hi there,

Line 203 of irrdb.py puts the option "-3" by default on the bgpq3/bgpq4 commands. However, this option is not supported in bgpq4 and thus, generates errors like the following:

ARouteServer 2022-01-20 15:10:40,175 ERROR Error while retrieving IPv6 prefixes from AS203101 for client AS203101_1: Can't get authorized prefix list for AS203101 IPv6: Error while parsing bgpq4 output for the following command: 'bgpq4 -h rr1.ntt.net -S RIPE,APNIC,AFRINIC,ARIN,NTTCOM,ALTDB,BBOI,BELL,JPIRR,LEVEL3,RADB,RGNET,TC -3 -j -6 -A -l prefix_list AS203101': bgpq4 exit code is 1, stderr: b"bgpq4: invalid option -- '3'\n" - No more attempts will be performed, all the hosts in the list failed.

By disabling/commenting this line the process goes on successfully.

pierky commented 2 years ago

Hello @stkonst, thanks for reporting this issue.

It seems that the -3 option has been dropped from bgpq4 recently. In the past it was added as a no-op just to keep compatibility with the bgpq3 syntax.

I've just pushed a pre-release for 1.13.1, where this should be fixed: v1.13.1-alpha1. The CI/CD pipeline is now running, and if everything goes well it should be pushed to the test instance of PyPi in about one hour. It'd be great if you could give it a try. In case, you can find instructions on how to install it from the test instance on this page: https://arouteserver.readthedocs.io/en/latest/INSTALLATION.html#development-and-pre-release-versions

Thanks a lot

stkonst commented 2 years ago

You are welcome, thank's for the quick fix. I will give it a try as well.

pierky commented 2 years ago

v1.13.1 is out with this fix/improvement.