STATUS: My script now returns 'running' when called with 'status' - did NOT fix my problem.
Anyre more ideas? What abut that other guy having problems with processes? I have no idea what goes wrong, or how to fix it. /S�ren >From: [EMAIL PROTECTED] (Peter HOLZLEITNER) >To: [EMAIL PROTECTED] >Subject: RE: What's wrong with this config? >Date: Wed, 10 Apr 2002 13:40:14 +0200 > >Please RTFM: > > http://www.linux-ha.org/download/faqntips.html: > 3. Resource scripts are basically (extended) System V init scripts. >They have to support stop, start, and status operations. > >--Peter > >-----Original Message----- >From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] >Sent: Wednesday, April 10, 2002 10:15 AM >To: [EMAIL PROTECTED] >Subject: What's wrong with this config? > > >Maybe this belong to heartbeat maillist, but I have tried there, and I >still >do not know what goes wrong. > >I let heartbeat start mon with the following script: > >******************** >#!/bin/bash > >MON=/usr/ha/mon-0.99.2 > >if [ $1 = "start" ]; then > $MON/mon -f -c $MON/mon.cf >elif [ $1 = "stop" ]; then > pid=$(ps -xw|grep $MON/mon.cf|grep -v grep|cut -c 1-5) > kill $pid >else > echo 0 >fi > >exit 0 >******************** > >If I start mon with that script manually, it seems to work allright. But >if >I let heartbeat start mon, it keeps starting new instances of mon!? > >Here is my mon.cf: > >******************** ># ># global options ># >cfbasedir = /usr/ha/mon-0.99.2/etc >alertdir = /usr/ha/mon-0.99.2/alert.d >mondir = /usr/ha/mon-0.99.2/mon.d >maxprocs = 20 >histlength = 100 >randstart = 60s > ># ># authentication types: ># getpwnam standard Unix passwd, NOT for shadow passwords ># shadow Unix shadow passwords (not implemented) ># userfile "mon" user file ># >authtype = getpwnam > ># ># NB: hostgroup and watch entries are terminated with a blank line (or ># end of file). Don't forget the blank lines between them or you lose. ># > ># ># group definitions (hostnames or IP addresses) ># >hostgroup wwwservers 62.243.245.113 > >hostgroup ethCard 62.243.245.100 > >watch wwwservers > service http > interval 4m > monitor http.monitor > allow_empty_group > period wd {Sun-Sat} > alert mail.alert [EMAIL PROTECTED] > upalert mail.alert -S "web server is back up" >[EMAIL PROTECTED] > alertevery 45m > >watch ethCard > service ping > interval 1m > monitor fping.monitor > period wd {Sun-Sat} > alert heartbeat.alert >******************** > >And now to the strange (to me anyway) mon stuff. If I comment out the >ethCard watch, heartbeat only starts one mon instance!?? But heartbeat >still >can't stop mon with my script!? > >Any ideas? I really need help on this one. > >/S�ren > >_________________________________________________________________ >MSN Photos is the easiest way to share and print your photos: >http://photos.msn.com/support/worldwide.aspx > > _________________________________________________________________ Chat with friends online, try MSN Messenger: http://messenger.msn.com
