MSSQL Plugin broken since update to 2.3.0P10

MSP 2.3.0P10
22.04 LTS

We’ve just updated to MSP 2.3.0P10. Now the MSSQL back-up plugin seems to be broken.
All SQL back-up service checks are now in an UNKN state with Crash-id:
Crash-ID: debdf2af-4443-11ef-95c8-293cdaeaf422

Output of “cmk --debug -vvn hostname”: (If it is a problem with checks or plugins)

OMD[nl01]:~$ cmk --debug -vvn Fortiweb-NL
Trying to acquire lock on /omd/sites/nl01/var/check_mk/crashes/base/c08eb50a-4443-11ef-95c8-293cdaeaf422/crash.info
Got lock on /omd/sites/nl01/var/check_mk/crashes/base/c08eb50a-4443-11ef-95c8-293cdaeaf422/crash.info
Releasing lock on /omd/sites/nl01/var/check_mk/crashes/base/c08eb50a-4443-11ef-95c8-293cdaeaf422/crash.info
Released lock on /omd/sites/nl01/var/check_mk/crashes/base/c08eb50a-4443-11ef-95c8-293cdaeaf422/crash.info
Traceback (most recent call last):
  File "/omd/sites/nl01/bin/cmk", line 97, in <module>
    errors = config.load_all_plugins(
             ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/omd/sites/nl01/lib/python3/cmk/base/config.py", line 1395, in load_all_plugins
    errors = agent_based_register.load_all_plugins()
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/omd/sites/nl01/lib/python3/cmk/base/api/agent_based/register/_discover.py", line 56, in load_all_plugins
    register_plugin_by_type(location, plugin)
  File "/omd/sites/nl01/lib/python3/cmk/base/api/agent_based/register/_discover.py", line 73, in register_plugin_by_type
    register_agent_section(plugin, location)
  File "/omd/sites/nl01/lib/python3/cmk/base/api/agent_based/register/_discover.py", line 99, in register_agent_section
    raise ValueError(f"duplicate section definition: {section_plugin.name}")
ValueError: duplicate section definition: mssql_backup
OMD[nl01]:~$

OMD[US01]:~/local/lib/check_mk/base/plugins/agent_based$ cmk -vI --detect-plugins=fortiweb_memory.py Fortiweb-US
Error in agent based plug-in mssql_backup (AgentSection): duplicate section definition: mssql_backupError in agent based plug-in mssql_backup (CheckPlugin): duplicate check plug-in definition: mssql_backupError in agent based plug-in mssql_backup_per_type (CheckPlugin): duplicate check plug-in definition: mssql_backup_per_typeDiscovering services and host labels on: Fortiweb-US

Crashreport info:
Exception:

TypeError ('>=' not supported between instances of 'float' and 'tuple')

Traceback:

  File "/omd/sites/US01/lib/python3/cmk/base/checkers.py", line 716, in get_aggregated_result
    check_result = check_function(**item_kw, **params_kw, **section_kws)
  File "/omd/sites/US01/lib/python3/cmk/base/checkers.py", line 496, in __check_function
    return _aggregate_results(consume_check_results(check_function(*args, **kw)))
  File "/omd/sites/US01/lib/python3/cmk/base/checkers.py", line 554, in consume_check_results
    for subr in subresults:
  File "/omd/sites/US01/lib/python3/cmk/base/api/agent_based/register/check_plugins.py", line 91, in filtered_generator
    for element in generator(*args, **kwargs):
  File "/omd/sites/US01/local/lib/python3/cmk/base/plugins/agent_based/mssql_backup.py", line 174, in check_mssql_backup
    yield from check_levels(
  File "/omd/sites/US01/lib/python3.12/site-packages/cmk/agent_based/v1/_check_levels.py", line 138, in check_levels
    value_state, levels_text = _do_check_levels(value, levels_upper, levels_lower, render_func)
  File "/omd/sites/US01/lib/python3.12/site-packages/cmk/agent_based/v1/_check_levels.py", line 29, in _do_check_levels
    if levels_upper and levels_upper[1] is not None and value >= levels_upper[1]:

It sounds like an incompatible plugin from before the 2.3 update. Please have a look at ~/local/share/check_mk/checks/ if there are some old plugins.
You can also grep over you local folder for “mssql_backup” as this section name is doubled as stated in the error message.

That folder is empty on all 3 of our servers.
When using ls i find the following from the /local folder:

OMD[US01]:~/local$ ls -lR | grep mssql_backup
-rw------- 1 US01 US01 9021 Jul 17 08:25 mssql_backup.py
-rw------- 1 US01 US01 9697 Mar 11 04:01 mssql_backup.cpython-311.pyc
-rw------- 1 US01 US01 8729 Jul 17 08:25 mssql_backup.cpython-312.pyc
-rw------- 1 US01 US01 12404 Jul 17 08:18 mssql_backup_220-0.2.0.mkp

I’m not entirely sure but the mssql_backup_220-0.2.0.mkp could be a custom plugin I’ve received from support a while back as a test.

I would deactivate this mkp first.
Then the error message should be gone.

1 Like

Thank you. I though I had already disabled the one I’ve received from support earlier, apparently I received 2 and forgot about this. By removing the other MKP as well this issue is now resolved.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed. Contact an admin if you think this should be re-opened.