[Xymon] Running the Availability Report from a crontab entry
    cleaver at terabithia.org 
    cleaver at terabithia.org
       
    Tue Jan 17 22:38:26 CET 2012
    
    
  
On Tue, January 17, 2012 12:13 pm, White, Bruce wrote:
>
> Hi all,
>
> I know I have seen some discussion on how to do this, but my searching
> the archive has come up with nothing.   Can anyone provide an example of
> how I would run the Availability report from a crontab entry, so I could
> produce a report automatically the first of every month for the last
> month?
>
>From xymonreport.sh:
"10 2 1 * * /usr/bin/xymoncmd --env=/etc/xymon/xymonserver.cfg
xymonreports.sh monthly"
..should be all you need (adjust your paths as needed). If you want to be
slick, drop versions of this into cron.daily/weekly/monthly instead.
Reports will be dropped into your webroot under /periodic.
HTH,
-jc
This is what I do in my RPM (with paths):
## Install cron jobs for the xymonreports.sh script on the server
  echo "#!/bin/sh
# Run daily xymon reports
  exec $XYMONHOME/bin/xymoncmd $XYMONHOME/bin/xymonreports.sh daily" >
/etc/cron.daily/xymonreports
  sed -e 's/daily/weekly/' /etc/cron.daily/xymonreports >
/etc/cron.weekly/xymonreports
  sed -e 's/daily/monthly/' /etc/cron.daily/xymonreports >
/etc/cron.monthly/xymonreports
  chmod 755 /etc/cron.*/xymonreports
## Create destination directory
  install -d /var/www/xymon/periodic
    
    
More information about the Xymon
mailing list