Nagios as Cron

Ben Clewett Ben at clewett.org.uk
Fri Apr 16 09:35:45 CEST 2004


Personally I would always use the tool designed for that task.  Cron is 
designed to run precesses very reliably at specific time.  Nagios is 
designed to collect data from plugins....  Eg, Nagios might timeout your 
plugin whilst still in the process of the ftp.

If you are uploading an hourly data file, would it not be better to 
write a plugin to check that the data file is there and less than one 
hour old?

Ben

Jason Martin wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> What is the community's views on using Nagios as a sort of Cron daemon? 
> I've got a process that runs hourly in cron that downloads an updated data 
> file from another host. The process takes about 5 seconds. The timing is 
> not critical as long as it eventually gets executed. I want to know if the 
> process fails (ie can't connect to the remote host, can't get the 
> datafile, etc).
> 
> I could have the process send a send_nsca message indicating it's status
> and run it out of normal cron, or I could call it as a plugin. Calling it 
> as a plugin seems aesthetically wrong to me as it has definite 
> externalities, as opposed to merely monitoring something else.  Does 
> anyone else use Nagios in this manner? 
> 
> Another issue is for maintence jobs that run once per day.  An example
> would be a app-specific log rotation script.  I need to know when these
> fail as well.  In this case it pretty much has to be run from cron and use
> send_nsca as the timing is important.  Can anyone give me some ideas on 
> how to handle these sort of jobs?
> 
> Thanks,
> - -Jason Martin
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.3.5 (GNU/Linux)
> Comment: pgpenvelope 2.10.2 - http://pgpenvelope.sourceforge.net/
> 
> iD8DBQFAfvlQl2ODWuqVSBMRAtjGAJ46SSxl8UykWArSRwPpi3aG9IMcRgCfbTXG
> cuT7Gzw5aRGatVI+puuxTd0=
> =QGfJ
> -----END PGP SIGNATURE-----
> 
> 
> -------------------------------------------------------
> This SF.Net email is sponsored by: IBM Linux Tutorials
> Free Linux tutorial presented by Daniel Robbins, President and CEO of
> GenToo technologies. Learn everything from fundamentals to system
> administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
> _______________________________________________
> Nagios-users mailing list
> Nagios-users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagios-users
> ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
> ::: Messages without supporting info will risk being sent to /dev/null
> 



-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list