Icinga / icingaweb2

A lightweight and extensible web interface to keep an eye on your environment. Analyse problems and act on them.
https://icinga.com/get-started/
GNU General Public License v2.0
809 stars 282 forks source link

Icinga\Exception\ProgrammingError in /usr/share/php/Icinga/Data/Filter/Filter.php:54 with message: Trying to get invalid filter index 1-2 from ! _host_tags = *tagname* & host_state != UP (1) #3577

Closed K0nne closed 6 years ago

K0nne commented 6 years ago

Today I found the following syslog entry:

Icinga\Exception\ProgrammingError in /usr/share/php/Icinga/Data/Filter/Filter.php:54 with message: Trying to get invalid filter index 1-2 from ! _host_tags = *tagname* & host_state != UP (1)
    #0 /usr/share/php/Icinga/Data/Filter/FilterChain.php(41): Icinga\Data\Filter\Filter->getById(String)
    #1 /usr/share/php/Icinga/Web/Widget/FilterEditor.php(687): Icinga\Data\Filter\FilterChain->getById(String)
    #2 /usr/share/php/Icinga/Web/Widget/FilterEditor.php(327): Icinga\Web\Widget\FilterEditor->applyChanges(Array)
    #3 /usr/share/php/Icinga/Web/Controller.php(254): Icinga\Web\Widget\FilterEditor->handleRequest(Object(Icinga\Web\Request))
    #4 /usr/share/icingaweb2/modules/monitoring/application/controllers/ListController.php(714): Icinga\Web\Controller->setupFilterControl(Object(Icinga\Module\Monitoring\DataView\HostStatus), NULL, NULL, Array)
    #5 /usr/share/icingaweb2/modules/monitoring/application/controllers/ListController.php(93): Icinga\Module\Monitoring\Controllers\ListController->filterQuery(Object(Icinga\Module\Monitoring\DataView\HostStatus))
    #6 /usr/share/icingaweb2/library/vendor/Zend/Controller/Action.php(507): Icinga\Module\Monitoring\Controllers\ListController->hostsAction()
    #7 /usr/share/php/Icinga/Web/Controller/Dispatcher.php(76): Zend_Controller_Action->dispatch(String)
    #8 /usr/share/icingaweb2/library/vendor/Zend/Controller/Front.php(937): Icinga\Web\Controller\Dispatcher->dispatch(Object(Icinga\Web\Request), Object(Icinga\Web\Response))
    #9 /usr/share/php/Icinga/Application/Web.php(300): Zend_Controller_Front->dispatch(Object(Icinga\Web\Request), Object(Icinga\Web\Response))
    #10 /usr/share/php/Icinga/Application/webrouter.php(104): Icinga\Application\Web->dispatch()
    #11 /usr/share/icingaweb2/public/index.php(4): require_once(String)
    #12 {main}

Expected Behavior

Not known so far.

Current Behavior

Not known so far.

Possible Solution

Steps to Reproduce (for bugs)

Not known so far.

Context

Not known so far.

Your Environment

businessprocess 2.1.0 monitoring 2.6.0 pnp 1.1.0

Copyright (c) 2012-2018 Icinga Development Team (https://www.icinga.com/) License GPLv2+: GNU GPL version 2 or later http://gnu.org/licenses/gpl2.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.

Application information: Installation root: /usr Sysconf directory: /etc Run directory: /run Local state directory: /var Package data directory: /usr/share/icinga2 State path: /var/lib/icinga2/icinga2.state Modified attributes path: /var/lib/icinga2/modified-attributes.conf Objects path: /var/cache/icinga2/icinga2.debug Vars path: /var/cache/icinga2/icinga2.vars PID path: /run/icinga2/icinga2.pid

System information: Platform: Red Hat Enterprise Linux Server Platform version: 7.4 (Maipo) Kernel: Linux Kernel version: 3.10.0-693.21.1.el7.x86_64 Architecture: x86_64

Build information: Compiler: GNU 4.8.5 Build host: unknown

RHEL 7.4

Disabled features: command compatlog debuglog elasticsearch gelf graphite influxdb livestatus mainlog opentsdb statusdata Enabled features: api checker ido-mysql notification perfdata syslog

[2018-09-24 12:42:08 +0200] information/cli: Icinga application loader (version: r2.9.1-1) [2018-09-24 12:42:08 +0200] information/cli: Loading configuration file(s). [2018-09-24 12:42:09 +0200] information/ConfigItem: Committing config item(s). [2018-09-24 12:42:09 +0200] information/ApiListener: My API identity: icingamaster01 [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 74491 Services. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 1 SyslogLogger. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 48 HostGroups. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 1 NotificationComponent. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 1 NotificationCommand. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 89213 Notifications. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 1 IcingaApplication. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 17359 Hosts. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 1 ApiListener. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 1 PerfdataWriter. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 75 Comments. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 1 CheckerComponent. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 12 Zones. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 17 Endpoints. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 4 ApiUsers. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 1 IdoMysqlConnection. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 253 CheckCommands. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 3 TimePeriods. [2018-09-24 12:42:15 +0200] information/ConfigItem: Instantiated 1 User. [2018-09-24 12:42:15 +0200] information/ScriptGlobal: Dumping variables to file '/var/cache/icinga2/icinga2.vars' [2018-09-24 12:42:15 +0200] information/cli: Finished validating the configuration file(s).

lippserd commented 6 years ago

Hi,

Thanks for the report. The exception is thrown by our filter editor. I tried to reproduce this issue starting with the filter !_host_tags=%20%2Atagname%2A%20&host_state!=UP%20%281%29 but I could not manage to force an error. If you face this again, could please report all the necessary steps in order to reproduce this behavior? I'll close this issue for the moment.

Best, Eric