Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-25777

Reduce startup load due to trigger evaluation within 30 seconds

XMLWordPrintable

    • Icon: Documentation task Documentation task
    • Resolution: Unresolved
    • Icon: Trivial Trivial
    • 7.0.9rc1
    • 6.4.20, 7.0.7, 7.2.1rc1, 7.4.0alpha1 (master)
    • None
    • None

      If time based functions in triggers are used then those triggers will be evaluated prematurely after startup and all within 30 seconds, which leads to more triggers being evaluated then history processed and very high load, this is very bad if user has now() functions in many triggers and for example in this case  800k triggers and example trigger:

      last(/host_xxx/vfs.file.exists[{$MAILBOX}],#3)=1 and last(/host_xxx/vfs.file.size[{$MAILBOX}],#3)>0 and (now()-last(/host_xxx/vfs.file.time[{$MAILBOX}]))<604799 

      As in this user supplied log:

      systemctl status zabbix-server.service | grep 'history sync'
      ├─241529 "/usr/sbin/zabbix_server: history syncer #1 [processed 35 values, 420 triggers in 93.986136 sec, syncing history]"
      ├─241530 "/usr/sbin/zabbix_server: history syncer #2 [processed 182 values, 692 triggers in 161.063722 sec, syncing history]"
      ├─241531 "/usr/sbin/zabbix_server: history syncer #3 [processed 4 values, 429 triggers in 103.734200 sec, syncing history]"
      ├─241532 "/usr/sbin/zabbix_server: history syncer #4 [processed 69 values, 484 triggers in 115.615771 sec, syncing history]"
      ├─241533 "/usr/sbin/zabbix_server: history syncer #5 [processed 23 values, 345 triggers in 53.282760 sec, syncing history]"
      ├─241534 "/usr/sbin/zabbix_server: history syncer #6 [processed 8 values, 423 triggers in 91.310238 sec, syncing history]"
      ├─241535 "/usr/sbin/zabbix_server: history syncer #7 [processed 538 values, 742 triggers in 141.932219 sec, syncing history]"
      ├─241536 "/usr/sbin/zabbix_server: history syncer #8 [processed 20 values, 379 triggers in 85.259552 sec, syncing history]"
      ├─241537 "/usr/sbin/zabbix_server: history syncer #9 [processed 68 values, 479 triggers in 106.694512 sec, syncing history]"
      ├─241538 "/usr/sbin/zabbix_server: history syncer #10 [processed 11 values, 426 triggers in 98.531984 sec, syncing history]"
      ├─241539 "/usr/sbin/zabbix_server: history syncer #11 [processed 194 values, 601 triggers in 173.374454 sec, syncing history]"
      ├─241540 "/usr/sbin/zabbix_server: history syncer #12 [processed 160 values, 567 triggers in 162.175727 sec, syncing history]"
      ├─241541 "/usr/sbin/zabbix_server: history syncer #13 [processed 1 values, 413 triggers in 101.494687 sec, syncing history]"
      ├─241542 "/usr/sbin/zabbix_server: history syncer #14 [processed 28 values, 367 triggers in 92.811734 sec, syncing history]"
      ├─241543 "/usr/sbin/zabbix_server: history syncer #15 [processed 111 values, 503 triggers in 130.510268 sec, syncing history]"
       

      Expected:

      Processed history values count should be more than trigger count.
      Similar as with trend functions don't calculate triggers within first 30 seconds but within 30 seconds after 1 minute has passed, this will spread some load.

      Forum post:
      https://www.zabbix.com/forum/zabbix-help/477223-zabbix-server-6-0-syncing-history-from-elasticsearch-too-slow

            zabbix.support Zabbix Support Team
            vso Vladislavs Sokurenko
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: