There were two evids duplicated in my status table (two records per evid).
I deleted these one-by-one, first from the status table, then the history.
Once I did that, a large number of the non-clearing events cleared and
zenaction started running again.
--
Gene Carter
Team Lead, UNIX Technical Programming
Acting Team Lead, UNIX Technical Services
Ricoh Americas Corporation
W: 973-882-2212
Printing email makes the baby trees cry.
[email protected] wrote on 06/01/2009 02:58:28 PM:
>
> I upgraded to 2.4.2 this weekend and noticed that while events
> haven't been clearing.
>
> In short it appears that there's a problem with: 'delete from status
> where clearid is not null ;'
>
> Any suggestions on how to address this would be welcome.
>
> Details...
>
> Interestingly, if I look at the detail log for one of the non-
> clearing events, I see:
>
> 2009/06/01 14:46:39.000 admin auto cleared
> 2009/06/01 14:46:21.000 admin auto cleared
> ...
>
> Also, I've noticed that in my zenactions.log, I am throwing database
> integrity errors... When I run zenaction run -v 10, the process
> appears to die with:
>
> ##########
> ERROR:zen.Events:(1062, "Duplicate entry '89cf9d82-
> d283-4732-92a4-082bc7a4e031' for key 1")
> Traceback (most recent call last):
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 46, in execute
> result = cursor.execute(statement)
> File "/usr/local/zenoss/python/lib/python2.4/site-
> packages/MySQLdb/cursors.py", line 137, in execute
> self.errorhandler(self, exc, value)
> File "/usr/local/zenoss/python/lib/python2.4/site-
> packages/MySQLdb/connections.py", line 33, in defaulterrorhandler
> raise errorclass, errorvalue
> IntegrityError: (1062, "Duplicate entry '89cf9d82-
> d283-4732-92a4-082bc7a4e031' for key 1")
> DEBUG:zen.DbConnectionPool:Returned a connection; Pool size: 1
> Traceback (most recent call last):
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/zenactions.py",
> line 672, in ?
> za.run()
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/zenactions.py",
> line 513, in run
> self.schedule.run()
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/Schedule.py",
> line 94, in run
> self.runEvents()
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/Schedule.py",
> line 150, in runEvents
> prodState=prodState,
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 132, in sendEvent
> evid = self.doSendEvent(event)
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 173, in doSendEvent
> execute(curs, delete)
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 51, in execute
> raise ex
> _mysql_exceptions.IntegrityError: (1062, "Duplicate entry '89cf9d82-
> d283-4732-92a4-082bc7a4e031' for key 1")
> ERROR:zen.Events:(1062, "Duplicate entry '89cf9d82-
> d283-4732-92a4-082bc7a4e031' for key 1")
> Traceback (most recent call last):
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 46, in execute
> result = cursor.execute(statement)
> File "/usr/local/zenoss/python/lib/python2.4/site-
> packages/MySQLdb/cursors.py", line 137, in execute
> self.errorhandler(self, exc, value)
> File "/usr/local/zenoss/python/lib/python2.4/site-
> packages/MySQLdb/connections.py", line 33, in defaulterrorhandler
> raise errorclass, errorvalue
> IntegrityError: (1062, "Duplicate entry '89cf9d82-
> d283-4732-92a4-082bc7a4e031' for key 1")
> DEBUG:zen.DbConnectionPool:Returned a connection; Pool size: 1
> Traceback (most recent call last):
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/zenactions.py",
> line 672, in ?
> za.run()
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/zenactions.py",
> line 513, in run
> self.schedule.run()
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/Schedule.py",
> line 94, in run
> self.runEvents()
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/Schedule.py",
> line 150, in runEvents
> prodState=prodState,
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 132, in sendEvent
> evid = self.doSendEvent(event)
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 173, in doSendEvent
> execute(curs, delete)
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 51, in execute
> raise ex
> _mysql_exceptions.IntegrityError: (1062, "Duplicate entry '89cf9d82-
> d283-4732-92a4-082bc7a4e031' for key 1")ERROR:zen.Events:(1062,
> "Duplicate entry '89cf9d82-d283-4732-92a4-082bc7a4e031' for key 1")
> Traceback (most recent call last):
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 46, in execute
> result = cursor.execute(statement)
> File "/usr/local/zenoss/python/lib/python2.4/site-
> packages/MySQLdb/cursors.py", line 137, in execute
> self.errorhandler(self, exc, value)
> File "/usr/local/zenoss/python/lib/python2.4/site-
> packages/MySQLdb/connections.py", line 33, in defaulterrorhandler
> raise errorclass, errorvalue
> IntegrityError: (1062, "Duplicate entry '89cf9d82-
> d283-4732-92a4-082bc7a4e031' for key 1")
> DEBUG:zen.DbConnectionPool:Returned a connection; Pool size: 1
> Traceback (most recent call last):
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/zenactions.py",
> line 672, in ?
> za.run()
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/zenactions.py",
> line 513, in run
> self.schedule.run()
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/Schedule.py",
> line 94, in run
> self.runEvents()
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/Schedule.py",
> line 150, in runEvents
> prodState=prodState,
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 132, in sendEvent
> evid = self.doSendEvent(event)
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 173, in doSendEvent
> execute(curs, delete)
> File "/usr/local/zenoss/zenoss/Products/ZenEvents/MySqlSendEvent.
> py", line 51, in execute
> raise ex
> _mysql_exceptions.IntegrityError: (1062, "Duplicate entry '89cf9d82-
> d283-4732-92a4-082bc7a4e031' for key 1")
> ########
>
> This appears to corespond to this sql: delete from status where
> clearid is not null
>
> When I run this SQL directly:
> #########
> mysql> use events;
> Reading table information for completion of table and column names
> You can turn off this feature to get a quicker startup with -A
>
> Database changed
> mysql> delete from status where clearid is not null ;
> ERROR 1062 (23000): Duplicate entry '89cf9d82-
> d283-4732-92a4-082bc7a4e031' for key 1
> mysql>
> ########
>
> --
> Gene Carter
> Team Lead, UNIX Technical Programming
> Acting Team Lead, UNIX Technical Services
> Ricoh Americas Corporation
> W: 973-882-2212
> Printing email makes the baby trees cry.
> _______________________________________________
> zenoss-users mailing list
> [email protected]
> http://lists.zenoss.org/mailman/listinfo/zenoss-users
_______________________________________________
zenoss-users mailing list
[email protected]
http://lists.zenoss.org/mailman/listinfo/zenoss-users