[Jenkins] monitor free space on jenkins slave

fyi, Until we have a proper monitoring solution (nagios,etc..). i added a new job to monitor jenkins slaves disk space and alert to infra@ovirt.org if one of the partitions of jenkins slave have is more than 90%. http://jenkins.ovirt.org/view/system-monitoring/job/check_disk_space_on_jenk... maybe we can add this as a cron to other ovirt servers as well: (and move it to nagios when it's available) #!/bin/sh df -H | grep -vE '^Filesystem|tmpfs|cdrom' | awk '{ print $5 " " $1 }' | while read output; do echo $output usep=$(echo $output | awk '{ print $1}' | cut -d'%' -f1 ) partition=$(echo $output | awk '{ print $2 }' ) if [ $usep -ge 90 ]; then echo "Running out of space \"$partition ($usep%)\" on $(hostname) as on $(date)" exit 1 (can be replaced with mutt/mail command) fi done
participants (1)
-
Eyal Edri