I have a Redhat cluster that I would like to monitor in Zabbix. Two nodes, one shared disk, one shared virtual IP, and a service. I would like to be able to monitor the virtual IP and which node is the owner of the service and disk, then be alerted if this changes. Does anybody do anything like this? Or someone could point me to a good place to start looking for info on how to do this. I have done some searching but have not really found anything.
Ad Widget
Collapse
Monitoring A Redhat Cluster
Collapse
X
-
Well after a few days of testing I have some basic monitoring and alerts setup for my test cluster.
The first step thing I did was determine a way to get information about the cluster. Since zabbix cannot issue a sudo in front of a command I created a script that dumps the output of the clustat command to a file, then scheduled it to run every minute in crontab. Next I created two User Parameters and put them into zabbix_agentd.conf file.
UserParameter=cluster.service,cat /tmp/clustat.log | tail -1 | awk '{print $3}'
Displays the status of the service.
UserParameter=cluster.owner,cat /tmp/clustat.log | tail -1 | awk '{print $2}'
Displays the owner of the service.
Created two items,
Type Zabbix Agent
Key cluster.service and cluster.owner
Type of infromation Text
Applications Services
Created two triggers
{hostname:cluster.service.str(started)}=0
Alerts when the string "started" is not found.
{hostname:cluster.owner.diff(0)}#0
Alerts when the value is different from the last.
Finally I created Alerts for the Triggers.
It is a bit hacked together but works for basic monitoring. When I relocate a service, the service is stopped, or if the active node is rebooted or goes down I am alerted.
If you get anything more for monitoring clusters, please post.Last edited by Caleb14; 20-08-2009, 15:20.Comment
Comment