Sunday, May 22, 2016

Duplicate Entry error in Zabbix server logs

We were seeing the following error

22199:20150613:133805.639 [Z3005] query failed: [1062] Duplicate entry '1743313' for key 'PRIMARY' [insert into events (eventid,source,object,objectid,clock,ns,value) values (1743313,3,0,55456,1460569085,540384532,0);

Main reason for this error is that two Zabbix servers were connected to the same DB server. We thought this might work in a HA scenario but it doesn't even though the second Zabbix server is doing nothing.

You might also have to run this query

delete from events;

Be careful as it would delete all events.
We did not care about this in a load test so we were OK with it.

No comments:

Post a Comment