I'm trying to get Orion Linux/Unix Script Monitor to parse a CURL output. I have the bash command to get the output, what I can't seem to do is make Orion see the Message Statistic fields at the end of the script. I need someone to tell me what I'm missing.
First my CURL statement, and the output I get on my Linux box, command first and output right after:
[USER@SERVER tmp]$ x=`curl -s -k -u user:'password' '192.168.1.1:8443/.../core.executeQuery"10.100.31.59")' | grep Average` printf "Message:AvgScan:\n";printf "\t$x" | awk -F: {'print $1'} | printf "Statistic:AvgScan:\t";y=`echo "$x" | awk -F: {'print $2'} | tr -d '\015'`;printf "\t$y\n"
Message:AvgScan:
Statistic:AvgScan: 0.017518
What Orion tells me when I run this script:
Get Output Failed: Invalid script output. Unable to parse 'Statistic' as number
I'm all but convinced, at this point, that I simply am not outputting the "Message / Statistic" fields right. Can someone good with creating templates help?