Hello,
After reading over a few threads and staring at do_temperature.c for awhile (like that helped), I'm a bit confused as to what format the data needs to be in. I was using temperature.sh from deadcat as a template for monitoring ambient temp on an IBM H70, but I ended up trimming it down to a basic script for maintenance purposes.
So does the data need to be in _exactly_ the same format as sampled in do_temperature.c or can there be extra columns and more spaces? I'd like to add the warn/panic thresholds to the status output for the computer operators..
Thank You,
-robert
On Thu, Feb 24, 2005 at 05:27:35PM -0500, Robert Edeker wrote:
So does the data need to be in _exactly_ the same format as sampled in do_temperature.c or can there be extra columns and more spaces? I'd like to add the warn/panic thresholds to the status output for the computer operators..
Extra columns will make it break. The code picks up the temperature readings from the last two columns of each line, and assumes those are the celsius- and fahrenheit-temperatures. Everything before those two columns are treated as being part of the name of the sensor.
But your suggestions does make sense. How about this:
Device Temp(C) Temp(F)
&green Motherboard#0 31 87 (Warn: 40, Panic: 50)
i.e. your extra information is inside parenthesis ? I'd just strip everything from '(' to ')' from the line before processing it, and then handle the rest of the report as I do now - so you can put whatever info you like there.
Regards, Henrik
On Fri, 25 Feb 2005 07:56:41 +0100, Henrik Stoerner <henrik at hswn.dk> wrote:
On Thu, Feb 24, 2005 at 05:27:35PM -0500, Robert Edeker wrote:
So does the data need to be in _exactly_ the same format as sampled in do_temperature.c or can there be extra columns and more spaces? I'd like to add the warn/panic thresholds to the status output for the computer operators..
But your suggestions does make sense. How about this:
Device Temp(C) Temp(F)
&green Motherboard#0 31 87 (Warn: 40, Panic: 50)
i.e. your extra information is inside parenthesis ? I'd just strip everything from '(' to ')' from the line before processing it, and then handle the rest of the report as I do now - so you can put whatever info you like there.
Sounds like good solution.. (...and I was wondering why my rrd filenames were coming out as `temperature.AMBIENT____________26.rrd :D )
Thank You,
-r
participants (2)
-
henrik@hswn.dk
-
idxman01@gmail.com