[ZBX-4774] High cpu load with postgresql monitoring 5000 discovered snmp items Created: 2012 Mar 19 Updated: 2017 May 30 Resolved: 2012 Mar 20 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | Server (S) |
Affects Version/s: | 2.0.0rc1 |
Fix Version/s: | None |
Type: | Incident report | Priority: | Major |
Reporter: | Cristian Mammoli | Assignee: | Unassigned |
Resolution: | Cannot Reproduce | Votes: | 0 |
Labels: | lld | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified | ||
Environment: |
OS: CentOS 6.2 x86_64 Zabbix server is running Yes localhost:10051 |
Attachments: |
![]() |
Description |
Hi, I'm using postgresql and the new 2.0 low level discovery to monitor some switches. |
Comments |
Comment by Oleksii Zagorskyi [ 2012 Mar 19 ] |
Which update interval for the discovery rule is used at the moment? |
Comment by Cristian Mammoli [ 2012 Mar 19 ] |
Port {#SNMPVALUE} AdminStatus IF-MIB-ifAdminStatus.[{#SNMPINDEX}] 1800 30 365 SNMPv2 agent Enabled NetworkPort {#SNMPVALUE} Alias IF-MIB-ifAlias.[ {#SNMPINDEX}] 1800 30 SNMPv2 agent Enabled NetworkPort {#SNMPVALUE} Collisions .1.3.6.1.4.1.9.2.2.1.1.25.[{#SNMPINDEX} ] 1800 30 365 SNMPv2 agent Enabled Network InCRC .1.3.6.1.4.1.9.2.2.1.1.12.[ {#SNMPINDEX}] 1800 30 365 SNMPv2 agent Enabled Network Port {#SNMPVALUE} InErrors IF-MIB-ifInErrors.[{#SNMPINDEX}] 1800 30 365 SNMPv2 agent Enabled Network Port {#SNMPVALUE} InOctets IF-MIB-ifHCInOctets.[ {#SNMPINDEX}] 180 30 365 SNMPv2 agent Enabled NetworkPort {#SNMPVALUE} InUcastPkts IF-MIB-ifHCInUcastPkts.[{#SNMPINDEX} ] 180 30 365 SNMPv2 agent Enabled Network Port {#SNMPVALUE} OutErrors IF-MIB-ifOutErrors.[ {#SNMPINDEX}] 1800 30 365 SNMPv2 agent Enabled NetworkPort {#SNMPVALUE} OutNUcastPkts IF-MIB-ifOutNUcastPkts.[{#SNMPINDEX} ] 180 30 365 SNMPv2 agent Enabled Network Port {#SNMPVALUE} OutUcastPkts IF-MIB-ifHCOutUcastPkts.[ {#SNMPINDEX}] 180 30 365 SNMPv2 agent Enabled NetworkPort {#SNMPVALUE} Speed IF-MIB-ifSpeed.[{#SNMPINDEX} ] 3600 30 365 SNMPv2 agent Enabled Network Here you are, 180 secs for most checks. I don't think that the interval is the issue anyway, as I said the high load happens even with all items disabled! And what's the point of monitoring port traffic ONCE in a hour |
Comment by Cristian Mammoli [ 2012 Mar 19 ] |
Sorry, I didn't understand you meant the discovery rule interval and not the items! It's every 3600 secs |
Comment by Oleksii Zagorskyi [ 2012 Mar 19 ] |
Cristian, I meant the discovery rule but not item prototypes. They are different things. Find a text: |
Comment by Cristian Mammoli [ 2012 Mar 19 ] |
I replied right above you, but I don't have "load spikes" very hour: the load is continuous. I can set the discovery interval to something like 86400 and see if things get better |
Comment by Oleksii Zagorskyi [ 2012 Mar 19 ] |
> but I don't have "load spikes" very hour: the load is continuous. I can set the discovery interval to something like 86400 and see if things get better Yes, try it. |
Comment by Cristian Mammoli [ 2012 Mar 19 ] |
zabbix 2.0 cpu load with postgresql |
Comment by Cristian Mammoli [ 2012 Mar 19 ] |
As you can see from the attached image as soon as I added the switch the load skyrocketed adn didn't drop for many hours, so I don' think the discovery interval is the issue here. As a test I dumped all the configuration and reimported into mysql. The load dropped from 1.6 to 0.3. I'll keep testing with mysql but I think the problem is linked to pgsql. Thanks |
Comment by Cristian Mammoli [ 2012 Mar 20 ] |
I was being too optimist, I still have heavy load with MySQL but the situation is way better: average load around 0.7 as soon as I add the switch to the template. I still have the pgsql db in place so if you need some data just ask |
Comment by Cristian Mammoli [ 2012 Mar 20 ] |
Well, shame on me: I had a flexible interval of 50 secs on the discovery rule. Removed it and the load now is around 0.2. Thank Oleksiy for your time and again sorry. You can close. |
Comment by Oleksii Zagorskyi [ 2012 Mar 20 ] |
Issue closed as Cannot reproduce |
Comment by Oleksii Zagorskyi [ 2012 Mar 20 ] |
Cristian, btw, would be interesting to know how many time zabbix server spends to discover and process single discovery rule with creation 5173 items and 2792 triggers. |
Comment by Cristian Mammoli [ 2012 Mar 20 ] |
Well I can create a new empty db and only import the discovery template. I'll do some tests this evening and let you know Bye |
Comment by Cristian Mammoli [ 2012 Mar 21 ] |
I created an empty db and populated it with the schema and so on, then I stopped zabbix_server and started with the new db. 2012-03-21 20:43:04.946398 IP srvzabbix.xxxxx.xx.52670 > sw3570racka.xxxxx.xx.snmp: GetNextRequest(30) 31.1.1.1.1 So I don't understand why with a discovery every 50 secs it was putting so much load on the db |
Comment by Oleksii Zagorskyi [ 2012 Mar 21 ] |
You observed only network traffic, but probably would be correct to watch CPU utilization after that SNMP walk. |