I have custom scripts located in /usr/share/cluster, they are associated with each service in the cluster and execute when the service starts/stops. At the beginning of the start/stop sections I have a definition to send me an email when the service starts/stops. Whenever I update the cluster config by issuing the command “ccs_tool update /etc/cluster/cluster.conf”, for each service already running I get the email stating the cluster service is starting even thought it doesn’t because it already is running. I cannot seem to figure out why this is. Here is an example of my script in /usr/share/cluster. Everything works great, I am just stumped as to why I get email about the services starting anytime I update the cluster.conf file. Any incite is appreciated.
# Cluster service script to start/stop oracle
STARTMSG="Starting $SVCNAME on node $HOSTNAME"
STOPMSG="Stopping $SVCNAME on node $HOSTNAME"
case $1 in
/bin/echo $STARTMSG | /bin/mail -s "RED HAT CLUSTER SERVICE" my email somewhere com
su - oracle -c "/service1/rcs/start_oracle.sh"
/bin/echo $STOPMSG | /bin/mail -s "RED HAT CLUSTER SERVICE" my email somewhere com
su - oracle -c "/service1/rcs/stop_oracle.sh"