#!/bin/bash

plugins=/usr/local/monitoring/nagios/libexec
port=9666
timeout=60
command=check_vvm
host=$1

out=`${plugins}/check_nrpe -t $timeout -H $1 -p $port -c $command 2>&1`
stat=$?

if [[ "$stat" -eq "1" ]]; then stat=2; fi

echo $out
exit $stat
