On 20 Oct 2009, at 18:22, Mike Dorman wrote:

I just did the check for this bug on our system and the minimum instance ID is 2, so looks like we are affected. In looking at the FAQ, it says that there should only be one row in the nagios_instances table. However, we have 24 (see below.)

It is very strange that the id numbers increment by 2 each time.

I am not very familiar with NDO, but it seems like this might be indicative of a larger problem. The FAQ says that “you have more than just Opsview pointing to this runtime database”, but I know that is not true.

The problem is in NDO code. It queries the nagios_instances table for the "default" instance to get the instance id. For some reason which we haven't determined yet, it sometimes doesn't get the existing row. Thus the next step it takes is to insert a new row and then use that new id number.

What we did was to set a constraint on the table so you can never have two instance ids with the same name. Then we changed the NDO code to select again after attempting the insert. This should stop what you are seeing below in new systems.


Do I need to worry about this? Or just wait for v3.3.3 and everything will be fine? Right now we are still on 2.14.1 (I know, I know) and I am getting everything in place to go to the latest v3.x.

The only symptoms we are seeing are duplicate numbers of services in the HH view. Can you try this statement to see how many times you can getting non-instance id = 2 connecting:

select count(*) from nagios_conninfo where instance_id != 2

Also, we seen that tuning mysql will help the database: 
http://docs.opsview.org/doku.php?id=opsview3.3:mysql

Ton

_______________________________________________
Opsview-users mailing list
[email protected]
http://lists.opsview.org/lists/listinfo/opsview-users

Reply via email to