bashclub / checkmk-opnsense-agent

65 stars 14 forks source link

DHCP Pool Crash Checkmk Raw Edition 2.2.0b8 #33

Closed tzockt closed 6 months ago

tzockt commented 1 year ago

Hi,

ich hab mein CheckMK auf 2.2.0b8 geupdatet und erhalte bei den DHCP Pools aktuell immer crashes. Falls weiter Infos benötigt werden, gerne im markieren :)

image

CheckMK Exception:

AttributeError ('tuple' object has no attribute 'get')

CheckMK Traceback:

  File "/omd/sites/home/lib/python3/cmk/base/agent_based/checking/_checking.py", line 413, in get_aggregated_result
    consume_check_results(
  File "/omd/sites/home/lib/python3/cmk/base/api/agent_based/checking_classes.py", line 494, in consume_check_results
    for subr in subresults:
  File "/omd/sites/home/lib/python3/cmk/base/api/agent_based/register/check_plugins.py", line 93, in filtered_generator
    for element in generator(*args, **kwargs):
  File "/omd/sites/home/lib/python3/cmk/base/api/agent_based/register/check_plugins_legacy.py", line 207, in check_result_generator
    subresults = _normalize_check_function_return_value(sig_function(**kwargs))
  File "/omd/sites/home/lib/python3/cmk/base/api/agent_based/register/check_plugins_legacy.py", line 168, in _normalize_check_function_return_value
    return list(subresults)
  File "/omd/sites/home/share/check_mk/checks/isc_dhcpd", line 95, in check_isc_dhcpd
    for check_result in check_dhcp_pools_levels(
  File "/omd/sites/home/lib/python3/cmk/base/check_legacy_includes/dhcp_pools.py", line 21, in check_dhcp_pools_levels
    for new_api_object in dhcp_pools.check_dhcp_pools_levels(free, used, pending, size, params):
  File "/omd/sites/home/lib/python3/cmk/base/plugins/agent_based/utils/dhcp_pools.py", line 32, in check_dhcp_pools_levels
    if (levels := params.get(f"{category}_leases")) is not None:
philidinator commented 1 year ago

Hi,

Same Problem with CheckMK 2.2.0p2 :(

Thanks

snafus-io commented 11 months ago

Leider bei mir auch ;(

obkgroove21 commented 11 months ago

Bei mir leider auch. Gibts hier schon Ideen/Ansätze?

SeeJayEmm commented 10 months ago

Experiencing the issue here as well CheckMK 2.2.0p4 OPNsense 23.7.1_3-amd64

Invisi commented 9 months ago

Going by how the other check plugins (e.g. Windows[0]) behave and the parameters I could find in a local crash dump[2], I'm suspecting the isc_dhcp check definition[1] never got updated to the new dict-based default parameters.
The "auto-migration-wrapper-key" magic happens here.

[0] check_default_parameters={"free_leases": (10.0, 5.0)}, [1] isc_dhcpd_default_levels = (15.0, 5.0) [2]

local_vars => {..., 'params': (15.0, 5.0)}
params => Parameters({'auto-migration-wrapper-key': (15.0, 5.0)})
alan7000 commented 8 months ago

Hello, is there a python developer who could patch this error? That would be nice because it's the only agent that exists and works almost perfectly.

obkgroove21 commented 7 months ago

@thorstenspille : Kannst du hier helfen? :)

thorstenspille commented 7 months ago

Das ist ein Bug in checkmk, ich habe dazu einen Thread im checkmk Forum auf gemacht.

mac-linux-free commented 7 months ago

Ich habe auch mein Check_MK downgegraded :)

thorstenspille commented 7 months ago

https://forum.checkmk.com/t/check-mk-isc-dhcpd-2-2-0-crashes-if-no-leases-in-agent-output/42139

thorstenspille commented 7 months ago

Vorhin hab ich die Benachrichtigung von checkmk bekommen, in Version 2.2.0p15 wird es einen Fix geben.

thorstenspille commented 7 months ago

https://checkmk.com/werk/16323

obkgroove21 commented 6 months ago

The problem is now fixed with the newest checkmk release 2.2.0p17:

https://forum.checkmk.com/t/release-checkmk-stable-release-2-2-0p17/43114

alan7000 commented 6 months ago

I can confirm that the problem has been solved in version 2.2.0p17.

JaapHoetmer commented 6 months ago

That’s good news, and I am confirming the errors have disappeared, but I am still left with errors related to a DHCPv6 server not running on those devices where the DHCPv4 errors were shown, while DHCPv6 is not even enabled on the devices. Is that not related?

Kind regards, Jaap

From: Flambard alan @.> Reply to: bashclub/checkmk-opnsense-agent @.> Date: Wednesday, 13 December 2023 at 12:21 To: bashclub/checkmk-opnsense-agent @.> Cc: Subscribed @.> Subject: Re: [bashclub/checkmk-opnsense-agent] DHCP Pool Crash Checkmk Raw Edition 2.2.0b8 (Issue #33)

I can confirm that the problem has been solved in version 2.2.0p17.

— Reply to this email directly, view it on GitHubhttps://github.com/bashclub/checkmk-opnsense-agent/issues/33#issuecomment-1853733167, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ABHBV6QAMRQNWJAR3E3QSSLYJGFS5AVCNFSM6AAAAAAYK7UBQ6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNJTG4ZTGMJWG4. You are receiving this because you are subscribed to this thread.Message ID: @.***>