BGP Error after adding the BGP Plugin

Hi All,

Thanks in advance and hope you are all well.

We have Cisco ISR’s and ASR’s we want to configure BGP Monitoring on them we have uploaded this plugin:

https://checkmk.com/check_mk-exchange-file.php?&file=cisco_bgp_peer-20180525.v.0.2.mkp

We were able to find this plugin under manual checks.

I created a rule found here:

Basically it targets the Main Directory with any device which has the tag BGP.

No time period was set

Here is a device with the tag set:

After doing a bulk discovery the results are as follows which is a little confusing.

As you can see some BGP Peers are idle i.e critical, some are unknown and some are okay while others are pending. This is a rather mixed bag of results.

Now with the warning below this is particularly interesting as it states the device has been up less than it’s minimum up time which is 1 day however this plugin has had that state for over a week.

Certain checks never leave pending

The critical check seems to always be the same as shown in the screenshot below does anyone have any ideas how to best configure the plugin and get rid of the annoying errors.

I would also like to add that doing a bulk discovery and a tabula rasa doesn’t remove the warnings even after removing the plugin rule/tag.

There is a newer version of that extension available at https://thl-cmk.hopto.org/gitlab/checkmk/cisco/cisco_bgp_peer
Have you tried that?

Hi,

Thanks for the plugin the website was blocked by Cisco Umbrella so this took a while to action.

So I removed the old version of the plugin and did a bulk discovery removing varnished services I then uploaded the plugin and did a bulk discovery and I got the following:

This time I was hoping the info would come through SNMP any idea where I am going wrong or can you suggest the config you have used and I can adapt it

The output looks ok, where is the problem with the current output?
You can define the minimum uptime of your BGP peer inside WATO.

The issue is that even though it has been more than a day we are still seeing the warnings saying less than a day and I am not sure how to resolve CRIT - Peer state: idle CRIT , or why it is occurring.

Can you show one of the uptime graphs for a BGP peer?
But if you don’t want to get an error message for the uptime you can also define that a uptime of 1 second is ok with the available WATO rules.

If you don’t want to “idle” state to result in crit you need to modify the cisco_bgp_peer file.
Beginning with line 462 you find the code transforming idle state to crit.

        if peerstate == 1:  # idle
        yield 2, 'Peer state: %s' % cisco_bgp_peerstate(peerstate)

Hi,

Thanks for your response.

I can’t seem to find the rule to define the uptime to 1 second but I will dig into this a bit more.

I have attached the requested graphs

I have also noticed on the same device the following error message:

Invalid check parameter : enable HTML Output for long output of check plugin (multiline): Invalid value, must be ‘True’ but is ‘False’
Variable: checkgroup_parameters:cisco_bgp_peer
Parameters:

{‘htmloutput’: False, ‘infotext_values’: [], ‘minuptime’: 86400, ‘peer_list’: [], ‘useaslocalas’: 0}


I was looking in Global Settings but couldn’t find the HTML output setting any idea as I assume they are in pending for that reason.

Hi,

Where can I define the warning rule for this plugin in WATO I can’t find it?

Hi,

which file do I edit you stated modify the cisco_bgp_peer but this file is in a number of locations so which one also this is not a fix for the error… it seems to me that it more ignores it.

/opt/omd/sites/ccycloud/local/share/check_mk/checks/cisco_bgp_peer
/opt/omd/sites/ccycloud/local/share/check_mk/web/plugins/wato/cisco_bgp_peer.py
/opt/omd/sites/ccycloud/local/share/check_mk/web/plugins/metrics/cisco_bgp_peer.py
/opt/omd/sites/ccycloud/var/check_mk/packages/cisco_bgp_peer
/opt/omd/sites/ccycloud/var/check_mk/precompiled_checks/local/cisco_bgp_peer
/opt/omd/sites/ccycloud/tmp/check_mk/wato/activation/f0f1120b-984f-410f-a8e3-2bd683a30950/multitar_workdir/synced_files/local/share/check_mk/web/plugins/wato/cisco_bgp_peer.py
/opt/omd/sites/ccycloud/tmp/check_mk/wato/activation/f0f1120b-984f-410f-a8e3-2bd683a30950/multitar_workdir/synced_files/local/share/check_mk/web/plugins/metrics/cisco_bgp_peer.py
/opt/omd/sites/ccycloud/tmp/check_mk/wato/activation/f0f1120b-984f-410f-a8e3-2bd683a30950/multitar_workdir/synced_files/local/share/check_mk/checks/cisco_bgp_peer
/opt/omd/sites/ccycloud/tmp/check_mk/wato/activation/f0f1120b-984f-410f-a8e3-2bd683a30950/multitar_workdir/synced_files/mkps/cisco_bgp_peer
/opt/omd/sites/ccycloud/tmp/check_mk/check_includes/local/cisco_bgp_peer

Hi ,

Any ideas with this?

The pending is only inside the WATO service discovery not if you activated the checks to be monitored.

You can access the settings with the icons left of the “PEND” field. The icon with the three bars brings you directly to the parameters for this services.

Hi,

Hope you are well.

If I edit /opt/omd/sites/ccycloud/local/share/check_mk/checks/cisco_bgp_peer

Surely that just ignores the critical state?