freeipmi-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Freeipmi-users] sensor not found with lib ipmimonitoring


From: Albert Chu
Subject: Re: [Freeipmi-users] sensor not found with lib ipmimonitoring
Date: Thu, 16 May 2013 10:08:24 -0700

Hey Yiannis,

On Thu, 2013-05-16 at 18:18 +0200, yiannis georgiou wrote:
> Hi Al,
> 
> good guess!! that was the problem and by putting the REREAD_SDR_CACHE 
> flag to true everything went back to normal
> 
> my question now is if I let the flag REREAD_SDR_CACHE to true permanently
> is the program going to flush / read the cache every time or only the 
> first time when we make multiple calls per minute?

It'll re-read the SDR cache every time you call one of the appropriate
"get sensor readings" functions (like
ipmi_monitoring_sensor_readings_by_record_id).  Normally, the re-read of
the cache is handled automatically if the timestamps on the firmware
have changed.  However, I've noticed that some vendors do not update the
timestamps, ugh ...

> actually the program I'm talking about is running as a thread collecting 
> power consumption information from a sensor every once in a while so if 
> it's going to delay every time reading the cache then I need to put the 
> value to false after the first read.

You may want to time things to see if the delay is a problem.  If you're
monitoring every 5 seconds, it may be a problem.  If you're monitoring
every hour, it may not be that big of a deal.

I believe the folks that use the library at my company do a re-read
cache everytime the monitoring daemon is restarted (i.e. the first
time).  It appears to be sufficient given the amount of
downtimes/software upgrades that occur.

Al

> 
> thanks a lot for your help
> 
> Best Regards
> Yiannis
> 
> 
> On 05/15/2013 07:28 PM, Albert Chu wrote:
> > Hi Yiannis,
> >
> > That is indeed strange.  It's hard to tell from just the information you
> > provided, but I have a guess
> >
> > Both ipmi-sensors and libipmimonitoring cache the SDR (sensor data
> > repository) "database" the first time it reads from the system so that
> > it doesn't have to do it over and over again.  It's possible that cache
> > is out of date, wrong, or corrupted for libipmimonitoring (i.e. firmware
> > update at some point, caches were created at different times, etc.).
> >
> > You may wish to flush the cache (-f in ipmi-sensors, see
> > REREAD_SDR_CACHE flag in ipmi_monitoring.h).  You could also just delete
> > the cache manually.  The default location of the libipmimonitoring cache
> > depends on your build, but you can see the location in the
> > libipmimonitoring.3 manpage.
> >
> > If that doesn't work, could you send me the debug output when you run
> > your libipmimonitoring tool.  You can turn on debugging by setting these
> > flags
> >
> >      IPMI_MONITORING_FLAGS_DEBUG              = 0x01,
> >      IPMI_MONITORING_FLAGS_DEBUG_IPMI_PACKETS = 0x02,
> >
> > Al
> >
> > On Wed, 2013-05-15 at 16:41 +0200, yiannis georgiou wrote:
> >> Hello,
> >>
> >> I have observed a strange behaviour when using ipmimonitoring library
> >> from a C program to collect the value of particular sensor
> >> The problem was observed on a cluster of homogeneous nodes and with
> >> freeipmi version 1.2.1.
> >> Even if ipmi-sensors command returns correctly the record id  the
> >> function "ipmi_monitoring_sensor_readings_by_record_id"
> >> returns "sensor not found"
> >>
> >> The strange thing is that the function works correctly on most of the
> >> nodes and the problem arrives only on some nodes:
> >> Here are some output from our cluster. In the results the executable
> >> ./test_lib_ipmi  makes use of the function
> >> "ipmi_monitoring_sensor_readings_by_record_id"
> >>
> >> so this is a node where the function works fine
> >> --------------------
> >> address@hidden ~]# ipmi-sensors -r 81
> >> ID | Name         | Type         | Reading    | Units | Event
> >> 81 | Blade Consum | Power Supply | 78.00      | W     | 'OK'
> >>
> >> address@hidden ~]# ./test_lib_ipmi 1 81
> >> sensor=81
> >> The sensor value is in watt: 76
> >> ------------------------
> >>
> >> and this is a node where it doesn't:
> >>
> >> -------------------------
> >> address@hidden ~]# ipmi-sensors -r 81
> >> ID | Name         | Type         | Reading    | Units | Event
> >> 81 | Blade Consum | Power Supply | 72.00      | W     | 'OK'
> >>
> >> address@hidden ~]# ./test_lib_ipmi 1 81
> >> sensor=81
> >> error: ipmi_monitoring_sensor_readings_by_record_id: sensor not found
> >> ------------------------------
> >>
> >> Do you have any ideas why we get this behaviour? Could this be a
> >> freeipmi configuration problem (related with the defaults of
> >> ipmimonitoring library) or a hardware issue ?
> >> Let me know if you want more information to localize the problem
> >>
> >> Thanks a lot for your help
> >> Best Regards
> >> Yiannis
> >>
> >>
> >>
> >>
> >>
> >> _______________________________________________
> >> Freeipmi-users mailing list
> >> address@hidden
> >> https://lists.gnu.org/mailman/listinfo/freeipmi-users
> 
-- 
Albert Chu
address@hidden
Computer Scientist
High Performance Systems Division
Lawrence Livermore National Laboratory





reply via email to

[Prev in Thread] Current Thread [Next in Thread]