You may have to explicitly specify the mode (msql or mysql) in the script or the easiest way to do this is to just rename the msql-mysql.monitor to mysql.monitor in that way mon knows its dealing with mysql , assuming u r only dealing with mysql .....
hope this helps
Kishore Jalleda
On 10/5/05, ankush grover <[EMAIL PROTECTED]> wrote:
hey friends,
I have configured mon for http alert but I am getting error while setting up mon for mysql
"failure for mysql1 MYSQL 1128500795 invalid mode !
Oct 5 13:56:35 linux mon[6086]: calling alert mail.alert for mysql1/MYSQL (/usr/lib/mon/alert.d/mail.alert,-S "mysql1 is down" [EMAIL PROTECTED]) invalid mode !"
the mon.cf file
### global options
cfbasedir = /etc/mon
pidfile = /var/run/mon.pid
statedir = /var/lib/mon/state.d
logdir = /var/lib/mon/log.d
dtlogfile = /var/lib/mon/log.d/downtime.log
alertdir = /usr/lib/mon/alert.d
mondir = /usr/lib/mon/mon.d
maxprocs = 20
histlength = 100
randstart = 60s
authtype = pam
userfile = /etc/mon/userfile
hostgroup apache1 192.168.1.67
hostgroup apache2 192.168.1.68
hostgroup mysql1 192.168.1.67
hostgroup mysql2 192.168.1.68
watch apache1
service HTTP
interval 1m
monitor http.monitor
allow_empty_group
period wd {Sun-Sat}
alert mail.alert -S "web server1 is down" [EMAIL PROTECTED]
upalert mail.alert -S "web server1 is back up" [EMAIL PROTECTED]
alertevery 1m
watch apache2
service HTTP
interval 1m
monitor http.monitor
allow_empty_group
period wd {Sun-Sat}
alert mail.alert -S "web server2 is down" [EMAIL PROTECTED]
upalert mail.alert -S "web server2 is back up" [EMAIL PROTECTED]
alertevery 1m
watch mysql1
service MYSQL
interval 1m
monitor msql-mysql.monitor
allow_empty_group
period wd {Sun-Sat}
alert mail.alert -S "mysql1 is down" [EMAIL PROTECTED]
upalert mail.alert -S "mysql1 is back up" [EMAIL PROTECTED]
alertevery 1m
watch mysql2
service MYSQL
interval 1m
monitor msql-mysql.monitor
allow_empty_group
period wd {Sun-Sat}
alert mail.alert -S "mysql2 is down" [EMAIL PROTECTED]
upalert mail.alert -S "mysql2 is back up" [EMAIL PROTECTED]
alertevery 1m
Moreover incase of HTTP service the alert message is not proper means I receive only
Summary output : "web
Group : apache2
Service : HTTP
Time noticed : Wed Oct 5 12:53:03 2005
Secs until next alert :
Members : 192.168.1.68
Detailed text (if any) follows:
-------------------------------
HOST 192.168.1.68: connect: No route to host
whereas In case of upalert I get this
Summary output : web server2 is back up
Group : apache2
Service : HTTP
Time noticed : Wed Oct 5 12:54:02 2005
Secs until next alert :
Members : 192.168.1.68
Detailed text (if any) follows:
-------------------------------
HOST 192.168.1.68: connect: No route to host
I am using postfix as MTA.
Any pointers.
Thanks & Regards
Ankush Grover
_______________________________________________
mon mailing list
mon@linux.kernel.org
http://linux.kernel.org/mailman/listinfo/mon
_______________________________________________ mon mailing list mon@linux.kernel.org http://linux.kernel.org/mailman/listinfo/mon