-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BGP Perl module question #622
Comments
I did try to add the perl module: use Net::Address::IP::Local; and redefined the variable: My thought was that our CNI will NAT the private K8s network to the bare metal network, and I can NAT the bare metal traffic as needed so the BGP peers think they are peering with the correct destination. That simple method didn't work sadly, I think I'll try passing the pod IP as an enviornment variable. |
Enabled the pod_ip as an enviornment variable within the helm chart:
and modified the startup script:
and although the pod is seeing the IP by the enviornment variable, the perl script is still failing.
so something is still failing even though the IP is properly passed in as the local IP. |
I used a VM to test the BGP perl script to remove the K8s and it still throws the bind() error. Its an ubuntu VM, I install cpanminus and configured the script but it fails to bind. |
I'm reviewing the BGP Perl Script vs a Python BMP script, Are there specific formats that nprobe needs in order to get AS path? Example Python BGP Monitoring Protocol (BMP) script https://github.com/smartbgp/yabmp, thinking it would function and scale better than doing a BGP peering. |
The format nprobe expects is very simple and there is nothing special to know. I will loo at the Python tool you have listed above |
Question / potential feature request:
I want to add BGP data to the sflow data to improve troubleshooting capabilities. However, when nProbe is running inside a kubernetes infrastructure, if I attempt to run the perl script from inside the container, the container is not able to attach an interface because the IP is from the CNI overlay and is dynamically allocated and is not from the baremetal / host level network. So the perl script configuration doesn't align with the configured IP address.
The questions I have are:
1.) Are there plans to improve the usability of the bgp perl script such that it can run natively in nProbe inside a container?
2.) Should I just run the perl script outside of the container and feed the data to nProbe similar to how sflow ingresses through the K8s infrastructure to the container? Essentially bypassing the K8s complexity where the perl script is concerned.
For additional context, when I attempt to run the script from inside the nprobe containt, I'm instructing the container to:
K8s commands run at container start:
sudo apt update && sudo apt --assume-yes install cpanminus sleep 10 yes | sudo perl -MCPAN -e 'install Net::BGP' /etc/ntopbgp/bgp_probe_client.pl
The last step fails and throws the error:
bind() failed at /usr/local/share/perl/5.34.0/Net/BGP/Process.pm line 237.
at /etc/ntopbgp/bgp_probe_client.pl line 134.
line 134 = $bgp->event_loop();
from the perl script.
The text was updated successfully, but these errors were encountered: