hi , experts
I want to exec a shell to send a message when a alarm occur. how to get the alarm info such ip address etc in the shell ?
another question , how to monitor a process ? must I install agents or just using snmp?
thx
faust
how to get the alarm info such ip address etc in the shell
Re: how to get the alarm info such ip address etc in the sh
If I understand you correctly for the first question you want an event handler that runs a shell script when a problem occurs? If you look in your commands.cfg then at the notify-host-by-email or any of those notification commands you will see an example of shell execution... in the Nagios documentation there is a list of all available macros.
And as for process monitoring... single process? All processes? Linux? Windows? More information if you want some help
And as for process monitoring... single process? All processes? Linux? Windows? More information if you want some help
Re: how to get the alarm info such ip address etc in the sh
thx , I want to send a measasge when a process is down on linux and unix and windows , how to do it ?
Re: how to get the alarm info such ip address etc in the sh
For windows I don't know of a plugin that allows you to monitor the processes in the manner I think you want, you can however use the NSClient++ client to check that services on a windows host are operating correctly. See http://nsclient.org/nscp/ for the client and http://nsclient.org/nscp/wiki/CheckProcState or http://nsclient.org/nscp/wiki/CheckServiceState for examples of configuration.
Nagios comes with a check_procs plugin for monitoring *nix you just need to install NRPE and the plugins-package on each host, though unlike check service state for NSClient++ there is no catch all... you will need to define exactly which processes you want monitored. For examples run check_procs with the --help switch.
Nagios comes with a check_procs plugin for monitoring *nix you just need to install NRPE and the plugins-package on each host, though unlike check service state for NSClient++ there is no catch all... you will need to define exactly which processes you want monitored. For examples run check_procs with the --help switch.