Question about ALARMPROGRAM
Posted in 1998
Hello All The FM says that the script pointed by ALARMPROGRAM takes 4 arguments, = ie EVENT_SEVERITY, EVENT_CLASS, EVENT_CLASS_MSG and EVENT_FILE (aka See = Also). I have multiple databases residing on the same machine, so I need = the instance name as well to identify an alarm. I think this can be done = by setting ALARMPROGRAM in my ONCONFIG file as follows: ALARMPROGRAM /usr/informix/etc/alarm.pl <servername> and within my alarm.pl script, I do: $server_name =3D $ARV[0]; $event_severity =3D $ARGV[1]; ... $event_file =3D $ARGV[4]; ie, I accept the <servername> as the first argument to my script, which = is hardcoded in my ONCONFIG file. My program then sends mail to me if it detects an alarm, telling me the = servername, the host (`hostname`) and the rest of the alarm, at least in = theory. So my question is: Has anyone done this sort of thing? Do you think = (from your knowledge of Unix and event handling) that this is workable? = If not do you have workarounds short of calling wrappers for each = instance or worse, having different alarm programs for each instance = that I create? TIA Sujit Pal