Aly,
I admit that there are no maintenance plans yet. This patch was first developed to provide me a crutial capability that was needed by our monitoring at work. I am now consulting with the community to take it the level where it would suit 99% of Zabbix installations. I already have a design concept in my head which is based on discussions in this forum which I am slowing building on my dev copy of Zabbix-1.6 to implement this.
I feel it is quite simple to determine whether a host is in maint mode or not using some simple boolean logic. This concept is a lot simpler than systems I design in my employ. If this was the hardest thing I needed to do at work I would be a much happier person. I have included a crude text based high level flow chart to assist in understanding the process to be used in determining a hosts maintenance status.
1. Retrieve the host's maintenance flag from DB (hosts.maintenance), is it a 1? Yes, host is in maint mode and goto point 4.
2. Retrieve the hosts maintenance plan(s) from the database and check them to see if now() is within any of them. Are any of them active? Yes, we are in maint mode and goto point 4.
3. We got to here, so we are no in maint mode.
4. We know the state of this host.
The boolean field (stored in the DB as an int) and the UI changes are already there in my patch for the manual operation. I need to move the point in the zabbix_server code where it is actioned, but that is not a big problem and I have already determined the SQL I need to use to get the info I need.
The only remaining situation I see at this time that needs resolving is how to deal with alerts which contain triggers from multiple hosts where less than all hosts on the alert are in maintenance mode? Perhaps you have some thoughts on this one?
Cheers,
Brian.
I admit that there are no maintenance plans yet. This patch was first developed to provide me a crutial capability that was needed by our monitoring at work. I am now consulting with the community to take it the level where it would suit 99% of Zabbix installations. I already have a design concept in my head which is based on discussions in this forum which I am slowing building on my dev copy of Zabbix-1.6 to implement this.
I feel it is quite simple to determine whether a host is in maint mode or not using some simple boolean logic. This concept is a lot simpler than systems I design in my employ. If this was the hardest thing I needed to do at work I would be a much happier person. I have included a crude text based high level flow chart to assist in understanding the process to be used in determining a hosts maintenance status.
1. Retrieve the host's maintenance flag from DB (hosts.maintenance), is it a 1? Yes, host is in maint mode and goto point 4.
2. Retrieve the hosts maintenance plan(s) from the database and check them to see if now() is within any of them. Are any of them active? Yes, we are in maint mode and goto point 4.
3. We got to here, so we are no in maint mode.
4. We know the state of this host.
The boolean field (stored in the DB as an int) and the UI changes are already there in my patch for the manual operation. I need to move the point in the zabbix_server code where it is actioned, but that is not a big problem and I have already determined the SQL I need to use to get the info I need.
The only remaining situation I see at this time that needs resolving is how to deal with alerts which contain triggers from multiple hosts where less than all hosts on the alert are in maintenance mode? Perhaps you have some thoughts on this one?
Cheers,
Brian.

Comment