# Pandora User-Defined adquisition script # This code is under GPL licence # This is the default user script file # If you're using this is because default config doest fit all your needs # You can use the following variables # # $DATA is XML output file where you need to write your module output # # Please refer documentatation for more example and a more depth usage instructions # # a little example, to monitor changes on DNS versus actual IP on interface ppp0 # Uncomment below this line to execute. All output needs to be in Pandora XML Agent-Output format #PLC_DNS=`dig @194.179.1.101 plc.genterara.com A +short | tail -1 ` #PLC_LOCAL=`ifconfig ppp0 | head -2 | tail -1 | tr -s ":" " " | awk ' { print $3 } '` #if [ "$PLC_DNS" == "$PLC_LOCAL" ] #then # PLC_STATUS=1 #else # PLC_STATUS=0 #fi # #echo "" #echo "PLC_DNS_CHECK" #echo "generic_proc" #echo "$PLC_STATUS" #echo ""