Skip to header Skip to main navigation Skip to main content Skip to footer

Search form

Site branding

Home
What's up, home?

Main navigation

  • Home
  • Story mode
  • About
  • Features
  • Hardware list
  • Videos
  • GitHub (opens in new tab)
  • Daily AI generated stories (opens in new tab)

Part 83: Just a second

Breadcrumbs

Breadcrumb

  • Home
  • Part 83: Just a second

Main page content

By whatsuphome | 9:38 PM EEST, Tue June 18, 2024

TL;DR

I changed every Zabbix item interval and even the UI refresh interval to one second across my home lab to see what happens. The server coped fine at first, but the single ICMP pinger ran out of steam, so I raised the poller count to five.
What's up, home? part 83 cover image

Zabbix 7.0 is fast. Not only it is fast for the new performance it gained underneath, but it also feels fast even on a Raspberry Pi 4.

Me being me, the following truly is an idea brought to you by Bad Idea Panda. Please, please do not try this at home. Or actually, DO try this at home, or any lab, but under any circumstances, DO NOT try this in production. Clear? Clear. Good, let's continue.

Change every interval to one second

My home lab environment is very small for Zabbix. Only few thousand items in total, only about 10-20 new values per second. That's with Zabbix default settings.

Number of items and triggers

But what would happen if I would change the default polling interval from one minute, 15 seconds, 30 seconds, whatever it is by default for different templates and items, to one second? Only one way to find out! 

Here's Linux by Zabbix agent template after the change (did not make it compute /etc/passwd checksum every second, all the other items I did change)

One second interval for Linux template

... and here is the same for SNMP interfaces template, apart from interface type I changed all the items.

SNMP interfaces

Does Zabbix server care?

No, of course it does not, as my environment is so tiny. Values processed per second did jump up quite a bit.

Values processed per second

By default Zabbix server starts only one ICMP pinger poller, and that was too few -- yes, I did change even the SNMP generic template ICMP ping update interval to one second, which I know does not make any sense. That is exactly why I did it. After I upped the number of ICMP pollers to five, no problems.

Data collectors utilisation

For Zabbix internal processes, the spikes you see are from housekeeper.

Housekeeper

Value cache seems to get some proper beating, but there's probably another reason for that -- we'll get into that just in a moment. Carry on reading.

Value cache effectiveness

Queues feel just fine -- the pending values are from my external test proxy, not Zabbix server itself. Why this happens, I have not checked, but this was going on before my little stunt.

Queue

... as you can see from queue details.

Queue details

Let's change the Zabbix UI refresh interval to one second, too!

By default, the minimum update interval that Zabbix lets you to choose for its widgets is ten seconds. That's boringly slow. Luckily, that's easy to adjust to our ... or my liking. The refresh interval options are set in Zabbix installation directory include/classes/core/CWidget.php file, so let's inject the choice of one second there, too. This might also be the reason why the value cache hits did jump up so much earlier. I'm just guessing, no actual knowledge of that.

 private static function getRefreshRates(): array {
               return [
                       0 => _('No refresh'),
                       1 => _n('%1$s second', '%1$s seconds', 1),
                       10 => _n('%1$s second', '%1$s seconds', 10),
                       30 => _n('%1$s second', '%1$s seconds', 30),
                       60 => _n('%1$s minute', '%1$s minutes', 1),
                       120 => _n('%1$s minute', '%1$s minutes', 2),
                       600 => _n('%1$s minute', '%1$s minutes', 10),
                       900 => _n('%1$s minute', '%1$s minutes', 15)
               ];
       }

After that, Zabbix user interface now includes this:

Refresh interval with one second

Does user interface still work after that?

Yes, though Zabbix starts to have its own little rave party for my network gauge. It's still fast to use, but for example with these values gathered over SNMP, my router bits received widget goes a bit bonkers when I run internet speed test on fast.com.

Router bits received

Any side effects?

Well, apart from the fact that now my Zabbix is going to grow the database much, much more than before, not really. My Raspberry Pi 4 MariaDB instance seems to consume anything between 30-60% of the CPU all the time now, but I don't care. Raspberry Pi stays snappy, and everything else running on it, including Grafana and Home Assistant, still continues to run smoothly.

MySQL

Required server performance is now a bit higher too compared to 10-20 new values per sec that was the status before I did the change.

Required server performance

Am I going to leave my Zabbix like this?

We will see. Part of me thinks that why not, I do have disk space for the database growth, and this seems to be working just fine. My sensible part thinks that I should revert the change. But not doing that right now.

whatsuphome
zabbix
zabbix70
benchmark
  • Allowed HTML tags: <a href hreflang> <em> <strong> <cite> <blockquote cite> <code> <ul type> <ol start type> <li> <dl> <dt> <dd> <h2 id> <h3 id> <h4 id> <h5 id> <h6 id>
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.
I changed every Zabbix item interval and even the UI refresh interval to one second across my home lab to see what happens. The server coped fine at first, but the single ICMP pinger ran out of steam, so I raised the poller count to five.

Search

Who am I?

  • Janne Pikkarainen from Finland 🇫🇮
  • Began with computers in 1986 with C64
  • Doing IT for living since 1999
  • Principal Site Reliability Engineer at Forcepoint
  • A Zabbix Summit speaker every year since 2022
  • Walking, talking Zabbix commercial

Support my project

Buy me a coffee 

Footer menu

  • Contact

What's up, home? | Janne Pikkarainen | contact(at)whatsuphome.fi | 2022 - 2026

Developed and Designed by Janne Pikkarainen