-
Notifications
You must be signed in to change notification settings - Fork 15
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
Errors with traps and host groups after upgrading to 1.0.6 #52
Comments
Hi, For the GUI error : when does this happen ? When you save / add from existing trap / Check "hostgroup" ? Did you check the permission changes in API needed by 1.0.6 ? Regards |
Hi Patrick, the GUI error only happens when saving a new trap handler for a host group. When using the log option "trace" or "ALL", only infos about incoming traps (sql queries,...) are logged and looked good, but the php errors cannot be found in the file. These are only visible in syslog caused by snmptrapd which called the php trap handler. Instead of Regards PS: when changing log level in GUI, the log file is truncated - is this a desired behavior? |
Same GUI problem persists after applying Manfred's changes to lines 327 and 341 of Trap.php |
My solution only addresses the PHP 7.4 warning which is thrown by each incoming trap. Regarding the web GUI issue within Icingaweb2 maybe the developer team of Icingaweb can help. I'm pretty sure that there are debugging capabilities. Icingaweb2 is a complex and extensible system, I'm not a web programmer and so it's hard for me to deliver detailed information. Who created the Trapdirector web interface? |
count(): Parameter must be an array or an object that implements Countable
Hi there, I just installed 1.0.7a and faced the same issue. Applied the patch and the problem seems have been fixed, at least I was able to create a new handler with a hostgroup. I can confirm, that getting list of hostgroups and then list of services takes some time, maybe 20-30 seconds. |
Describe the bug
Trap handles for host groups stopped working after upgrade to TrapDirector 1.0.6.
Traps for dedicated hosts still work.
Also I'm not able to create new trap handlers for host groups (GUI : Error : count(): Parameter must be an array or an object that implements Countable). Selection of host groups works, but saving is not possible.
To Reproduce
Syslog starting with new incoming Link Down Trap:
2021-01-01T21:53:44.888000+01:00 host snmptrapd[2071]: 10.10.10.2: Link Down Trap (0) Uptime: 94 days, 12:20:24.83, .1.3.6.1.2.1.2.2.1.1.10106 = INTEGER: 10106, .1.3.6.1.2.1.2.2.1.2.10106 = STRING: GigabitEthernet1/0/6, .1.3.6.1.2.1.2.2.1.3.10106 = INTEGER: 6, .1.3.6.1.4.1.9.2.2.1.1.20.10106 = STRING: "down"
2021-01-01T21:53:44.977469+01:00 host snmptrapd[2071]: PHP Notice: Trying to access array offset on value of type bool in /usr/share/icingaweb2/modules/trapdirector/library/Trapdirector/TrapsProcess/Trap.php on line 327
2021-01-01T21:53:44.979448+01:00 host snmptrapd[2071]: message repeated 4 times: [ PHP Notice: Trying to access array offset on value of type bool in /usr/share/icingaweb2/modules/trapdirector/library/Trapdirector/TrapsProcess/Trap.php on line 327]
2021-01-01T21:53:44.979714+01:00 host snmptrapd[2071]: PHP Notice: Trying to access array offset on value of type bool in /usr/share/icingaweb2/modules/trapdirector/library/Trapdirector/TrapsProcess/Trap.php on line 341
2021-01-01T21:53:45.116622+01:00 host snmptrapd[2071]: PHP Notice: Trying to access array offset on value of type bool in /usr/share/icingaweb2/modules/trapdirector/library/Trapdirector/TrapsProcess/Trap.php on line 327
2021-01-01T21:53:45.117056+01:00 host snmptrapd[2071]: PHP Notice: Trying to access array offset on value of type bool in /usr/share/icingaweb2/modules/trapdirector/library/Trapdirector/TrapsProcess/Trap.php on line 341
2021-01-01T21:53:45.254773+01:00 host snmptrapd[2071]: PHP Notice: Trying to access array offset on value of type bool in /usr/share/icingaweb2/modules/trapdirector/library/Trapdirector/TrapsProcess/Trap.php on line 327
2021-01-01T21:53:45.255220+01:00 host snmptrapd[2071]: PHP Notice: Trying to access array offset on value of type bool in /usr/share/icingaweb2/modules/trapdirector/library/Trapdirector/TrapsProcess/Trap.php on line 341
A truncation and rebuild of the MIB cache DB tables did not change the behavior.
Your Environment:
icinga2 --version
): 2.12.3The text was updated successfully, but these errors were encountered: