Re: [Freeipmi-devel] ipmimonitoring-sensors.c discretereading workaround

2018-12-10 Thread Al Chu
Hey Florian,

I have an experimental branch called ipmimonitoring-discrete-reading on
github here:

https://github.com/chu11/freeipmi-mirror/tree/ipmimonitoring-discrete-r
eading

./autogen.sh
./configure
make
make install
re-compile ipmimonitoring-sensors.c and try it out

LMK if you need help, like getting to the right branch.  If you can't
make install, LMK and I can show you some linker tricks.

Al

On Wed, 2018-12-05 at 20:34 +0100, Florian wrote:
> Hey Al,
> 
> That's awesome!
> 
> Sure, I'm totally OK with a git repo. As long as I just need to do
> configure and make I can do it.
> 
> Thanks for looking into this so fast!
> 
> Florian 
> 
> On Wed, Dec 5, 2018 at 8:26 PM Albert Chu  wrote:
> > Hey Florian,
> > 
> > Ok, I think I found a bug.  The "discrete reading" flag is passed
> > to an
> > underlying library correctly, but the result is not stored in
> > libipmimonitoring correctly.  I don't remember how this workaround
> > works 100%, because I never had this motherboard.
> > 
> > Once I look into this, how would like to be able to test?  Will
> > pointing you to a github repo be ok?
> > 
> > For my personal notes for later: see 
> > _digital_sensor_reading() and _specific_sensor_reading(), store
> > sensor
> > reading result and possibly units and other things too.
> > 
> > Al
> > 
> > On Wed, 2018-12-05 at 10:59 +0100, Florian wrote:
> > > Hey Albert,
> > > 
> > > The changeing of record_ids and record_ids_length showed the
> > sensor 5
> > > (but no data) like this
> > > Record ID, Sensor Name, Sensor Number, Sensor Type, Sensor State,
> > > Sensor Reading, Sensor Units, Sensor Event/Reading Type Code,
> > Sensor
> > > Event Bitmask, Sensor Event String
> > > 5, Power Meter, 5, Current, N/A, N/A, N/A, 9h, 2h, 'Device
> > Enabled'.
> > > 
> > > IPMI_MONITORING_FLAGS_DEBUG unfortunately did not add ANY more
> > logs
> > > at all, so I tried with IPMI_MONITORING_FLAGS_DEBUG_IPMI_PACKETS
> > > which gave me more logs.
> > > Those are quite a lot of more lines, so I pasted it into my
> > > privatebin: https://privatebin.florianstroeger.com/?58387298f9b91
> > 3c4#
> > > CkDCOMP5eFXOs6Whn+giWtidWNhMZGrkhc3tXYPaK9o=
> > > I also tried setting discrete_reading to 1 as the sensor 5 was
> > > visible with record_ids, but that did output the same results.
> > > 
> > > Florian
> > > 
> > > On Wed, Dec 5, 2018 at 12:07 AM Albert Chu 
> > wrote:
> > > > Hey Florian,
> > > > 
> > > > Lets try:
> > > > 
> > > > unsigned int record_ids[] = {5,
> > > >
> > 0};
> > > >   
> > > > unsigned int record_ids_length = 1;
> > > > 
> > > > and
> > > > 
> > > > unsigned int ipmimonitoring_init_flags =
> > > > IPMI_MONITORING_FLAGS_DEBUG;
> > > > 
> > > > Al
> > > > 
> > > > On Tue, 2018-12-04 at 20:16 +0100, Florian wrote:
> > > > > Oops, I'm sorry, Android-Mail apparently deleted the CC...
> > > > > 
> > > > > I compiled with ipmimonitoring_init_flags = 1 now and got
> > debug
> > > > stuff
> > > > > this time.
> > > > > 
> > > > > The output is following...
> > > > > (ipmi_monitoring_sensor_reading.c,
> > > > > ipmi_monitoring_get_sensor_reading, 1061): record_type '0xC0'
> > not
> > > > > supported
> > > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type,
> > > > 752):
> > > > > event_reading_type_code '0x70' bitmask is OEM
> > > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type,
> > > > 752):
> > > > > event_reading_type_code '0x71' bitmask is OEM
> > > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type,
> > > > 752):
> > > > > event_reading_type_code '0x71' bitmask is OEM
> > > > > (ipmi_monitoring_sensor_reading.c,
> > > > > ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8'
> > not
> > > > > supported
> > > > > (ipmi_monitoring_sensor_reading.c,
> > > > > ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8'
> > not
> > > > > supported
> > > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > > ipmi_sensor_read: sensor reading unavailable
> > > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > > 571):
> > > > > cannot read sensor for record id '23'
> > > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > > ipmi_sensor_read: sensor reading unavailable
> > > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > > 571):
> > > > > cannot read sensor for record id '24'
> > > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > > ipmi_sensor_read: sensor reading unavailable
> > > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > > 571):
> > > > > cannot read sensor for record id '38'
> > > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > > ipmi_sensor_read: sensor reading unavailable
> > > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > > 571):
> > > > > cannot read sensor for record id '39'

Re: [Freeipmi-devel] ipmimonitoring-sensors.c discretereading workaround

2018-12-05 Thread Florian
Hey Al,

That's awesome!

Sure, I'm totally OK with a git repo. As long as I just need to do
configure and make I can do it.

Thanks for looking into this so fast!

Florian

On Wed, Dec 5, 2018 at 8:26 PM Albert Chu  wrote:

> Hey Florian,
>
> Ok, I think I found a bug.  The "discrete reading" flag is passed to an
> underlying library correctly, but the result is not stored in
> libipmimonitoring correctly.  I don't remember how this workaround
> works 100%, because I never had this motherboard.
>
> Once I look into this, how would like to be able to test?  Will
> pointing you to a github repo be ok?
>
> For my personal notes for later: see
> _digital_sensor_reading() and _specific_sensor_reading(), store sensor
> reading result and possibly units and other things too.
>
> Al
>
> On Wed, 2018-12-05 at 10:59 +0100, Florian wrote:
> > Hey Albert,
> >
> > The changeing of record_ids and record_ids_length showed the sensor 5
> > (but no data) like this
> > Record ID, Sensor Name, Sensor Number, Sensor Type, Sensor State,
> > Sensor Reading, Sensor Units, Sensor Event/Reading Type Code, Sensor
> > Event Bitmask, Sensor Event String
> > 5, Power Meter, 5, Current, N/A, N/A, N/A, 9h, 2h, 'Device Enabled'.
> >
> > IPMI_MONITORING_FLAGS_DEBUG unfortunately did not add ANY more logs
> > at all, so I tried with IPMI_MONITORING_FLAGS_DEBUG_IPMI_PACKETS
> > which gave me more logs.
> > Those are quite a lot of more lines, so I pasted it into my
> > privatebin: https://privatebin.florianstroeger.com/?58387298f9b913c4#
> > CkDCOMP5eFXOs6Whn+giWtidWNhMZGrkhc3tXYPaK9o=
> > I also tried setting discrete_reading to 1 as the sensor 5 was
> > visible with record_ids, but that did output the same results.
> >
> > Florian
> >
> > On Wed, Dec 5, 2018 at 12:07 AM Albert Chu  wrote:
> > > Hey Florian,
> > >
> > > Lets try:
> > >
> > > unsigned int record_ids[] = {5,
> > > 0};
> > >
> > > unsigned int record_ids_length = 1;
> > >
> > > and
> > >
> > > unsigned int ipmimonitoring_init_flags =
> > > IPMI_MONITORING_FLAGS_DEBUG;
> > >
> > > Al
> > >
> > > On Tue, 2018-12-04 at 20:16 +0100, Florian wrote:
> > > > Oops, I'm sorry, Android-Mail apparently deleted the CC...
> > > >
> > > > I compiled with ipmimonitoring_init_flags = 1 now and got debug
> > > stuff
> > > > this time.
> > > >
> > > > The output is following...
> > > > (ipmi_monitoring_sensor_reading.c,
> > > > ipmi_monitoring_get_sensor_reading, 1061): record_type '0xC0' not
> > > > supported
> > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type,
> > > 752):
> > > > event_reading_type_code '0x70' bitmask is OEM
> > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type,
> > > 752):
> > > > event_reading_type_code '0x71' bitmask is OEM
> > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type,
> > > 752):
> > > > event_reading_type_code '0x71' bitmask is OEM
> > > > (ipmi_monitoring_sensor_reading.c,
> > > > ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8' not
> > > > supported
> > > > (ipmi_monitoring_sensor_reading.c,
> > > > ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8' not
> > > > supported
> > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > ipmi_sensor_read: sensor reading unavailable
> > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > 571):
> > > > cannot read sensor for record id '23'
> > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > ipmi_sensor_read: sensor reading unavailable
> > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > 571):
> > > > cannot read sensor for record id '24'
> > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > ipmi_sensor_read: sensor reading unavailable
> > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > 571):
> > > > cannot read sensor for record id '38'
> > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > ipmi_sensor_read: sensor reading unavailable
> > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > 571):
> > > > cannot read sensor for record id '39'
> > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > ipmi_sensor_read: sensor reading unavailable
> > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > 571):
> > > > cannot read sensor for record id '40'
> > > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > > ipmi_sensor_read: sensor reading unavailable
> > > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > > 571):
> > > > cannot read sensor for record id '41'
> > > > Record ID, Sensor Name, Sensor Number, Sensor Type, Sensor State,
> > > > Sensor Reading, Sensor Units, Sensor Event/Reading Type Code,
> > > Sensor
> > > > Event Bitmask, Sensor Event String
> > > > ipmi_monitoring_sensor_read_sensor_bitmask_strings: success
> > > >
> > > >
> > > > I'm unfortunately don't know much about C. You mean I should

Re: [Freeipmi-devel] ipmimonitoring-sensors.c discretereading workaround

2018-12-05 Thread Albert Chu
Hey Florian,

Ok, I think I found a bug.  The "discrete reading" flag is passed to an
underlying library correctly, but the result is not stored in
libipmimonitoring correctly.  I don't remember how this workaround
works 100%, because I never had this motherboard.

Once I look into this, how would like to be able to test?  Will
pointing you to a github repo be ok?

For my personal notes for later: see 
_digital_sensor_reading() and _specific_sensor_reading(), store sensor
reading result and possibly units and other things too.

Al

On Wed, 2018-12-05 at 10:59 +0100, Florian wrote:
> Hey Albert,
> 
> The changeing of record_ids and record_ids_length showed the sensor 5
> (but no data) like this
> Record ID, Sensor Name, Sensor Number, Sensor Type, Sensor State,
> Sensor Reading, Sensor Units, Sensor Event/Reading Type Code, Sensor
> Event Bitmask, Sensor Event String
> 5, Power Meter, 5, Current, N/A, N/A, N/A, 9h, 2h, 'Device Enabled'.
> 
> IPMI_MONITORING_FLAGS_DEBUG unfortunately did not add ANY more logs
> at all, so I tried with IPMI_MONITORING_FLAGS_DEBUG_IPMI_PACKETS
> which gave me more logs.
> Those are quite a lot of more lines, so I pasted it into my
> privatebin: https://privatebin.florianstroeger.com/?58387298f9b913c4#
> CkDCOMP5eFXOs6Whn+giWtidWNhMZGrkhc3tXYPaK9o=
> I also tried setting discrete_reading to 1 as the sensor 5 was
> visible with record_ids, but that did output the same results.
> 
> Florian
> 
> On Wed, Dec 5, 2018 at 12:07 AM Albert Chu  wrote:
> > Hey Florian,
> > 
> > Lets try:
> > 
> > unsigned int record_ids[] = {5,
> > 0};
> >   
> > unsigned int record_ids_length = 1;
> > 
> > and
> > 
> > unsigned int ipmimonitoring_init_flags =
> > IPMI_MONITORING_FLAGS_DEBUG;
> > 
> > Al
> > 
> > On Tue, 2018-12-04 at 20:16 +0100, Florian wrote:
> > > Oops, I'm sorry, Android-Mail apparently deleted the CC...
> > > 
> > > I compiled with ipmimonitoring_init_flags = 1 now and got debug
> > stuff
> > > this time.
> > > 
> > > The output is following...
> > > (ipmi_monitoring_sensor_reading.c,
> > > ipmi_monitoring_get_sensor_reading, 1061): record_type '0xC0' not
> > > supported
> > > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type,
> > 752):
> > > event_reading_type_code '0x70' bitmask is OEM
> > > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type,
> > 752):
> > > event_reading_type_code '0x71' bitmask is OEM
> > > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type,
> > 752):
> > > event_reading_type_code '0x71' bitmask is OEM
> > > (ipmi_monitoring_sensor_reading.c,
> > > ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8' not
> > > supported
> > > (ipmi_monitoring_sensor_reading.c,
> > > ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8' not
> > > supported
> > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > ipmi_sensor_read: sensor reading unavailable
> > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > 571):
> > > cannot read sensor for record id '23'
> > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > ipmi_sensor_read: sensor reading unavailable
> > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > 571):
> > > cannot read sensor for record id '24'
> > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > ipmi_sensor_read: sensor reading unavailable
> > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > 571):
> > > cannot read sensor for record id '38'
> > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > ipmi_sensor_read: sensor reading unavailable
> > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > 571):
> > > cannot read sensor for record id '39'
> > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > ipmi_sensor_read: sensor reading unavailable
> > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > 571):
> > > cannot read sensor for record id '40'
> > > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > > ipmi_sensor_read: sensor reading unavailable
> > > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading,
> > 571):
> > > cannot read sensor for record id '41'
> > > Record ID, Sensor Name, Sensor Number, Sensor Type, Sensor State,
> > > Sensor Reading, Sensor Units, Sensor Event/Reading Type Code,
> > Sensor
> > > Event Bitmask, Sensor Event String
> > > ipmi_monitoring_sensor_read_sensor_bitmask_strings: success
> > > 
> > > 
> > > I'm unfortunately don't know much about C. You mean I should
> > change
> > > in 'unsigned int record_ids[] = {0};' the 0 to a sensor-id,
> > right?
> > > Because I did this and that neither worked with putting 5 in for
> > the
> > > power meter nor with any other sensor.
> > > 
> > > Florian
> > > 
> > > 
> > > 
> > > On Tue, Dec 4, 2018 at 7:47 PM Albert Chu  wrote:
> > > > Didn't see your out

Re: [Freeipmi-devel] ipmimonitoring-sensors.c discretereading workaround

2018-12-05 Thread Florian
Hey Albert,

The changeing of record_ids and record_ids_length showed the sensor 5 (but
no data) like this
Record ID, Sensor Name, Sensor Number, Sensor Type, Sensor State, Sensor
Reading, Sensor Units, Sensor Event/Reading Type Code, Sensor Event
Bitmask, Sensor Event String
5, Power Meter, 5, Current, N/A, N/A, N/A, 9h, 2h, 'Device Enabled'.

IPMI_MONITORING_FLAGS_DEBUG unfortunately did not add ANY more logs at all,
so I tried with IPMI_MONITORING_FLAGS_DEBUG_IPMI_PACKETS which gave me more
logs.
Those are quite a lot of more lines, so I pasted it into my privatebin:
https://privatebin.florianstroeger.com/?58387298f9b913c4#CkDCOMP5eFXOs6Whn+giWtidWNhMZGrkhc3tXYPaK9o=
I also tried setting discrete_reading to 1 as the sensor 5 was visible with
record_ids, but that did output the same results.

Florian

On Wed, Dec 5, 2018 at 12:07 AM Albert Chu  wrote:

> Hey Florian,
>
> Lets try:
>
> unsigned int record_ids[] = {5,
> 0};
> unsigned int record_ids_length = 1;
>
> and
>
> unsigned int ipmimonitoring_init_flags = IPMI_MONITORING_FLAGS_DEBUG;
>
> Al
>
> On Tue, 2018-12-04 at 20:16 +0100, Florian wrote:
> > Oops, I'm sorry, Android-Mail apparently deleted the CC...
> >
> > I compiled with ipmimonitoring_init_flags = 1 now and got debug stuff
> > this time.
> >
> > The output is following...
> > (ipmi_monitoring_sensor_reading.c,
> > ipmi_monitoring_get_sensor_reading, 1061): record_type '0xC0' not
> > supported
> > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type, 752):
> > event_reading_type_code '0x70' bitmask is OEM
> > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type, 752):
> > event_reading_type_code '0x71' bitmask is OEM
> > (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type, 752):
> > event_reading_type_code '0x71' bitmask is OEM
> > (ipmi_monitoring_sensor_reading.c,
> > ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8' not
> > supported
> > (ipmi_monitoring_sensor_reading.c,
> > ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8' not
> > supported
> > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > ipmi_sensor_read: sensor reading unavailable
> > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> > cannot read sensor for record id '23'
> > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > ipmi_sensor_read: sensor reading unavailable
> > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> > cannot read sensor for record id '24'
> > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > ipmi_sensor_read: sensor reading unavailable
> > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> > cannot read sensor for record id '38'
> > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > ipmi_sensor_read: sensor reading unavailable
> > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> > cannot read sensor for record id '39'
> > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > ipmi_sensor_read: sensor reading unavailable
> > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> > cannot read sensor for record id '40'
> > (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> > ipmi_sensor_read: sensor reading unavailable
> > (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> > cannot read sensor for record id '41'
> > Record ID, Sensor Name, Sensor Number, Sensor Type, Sensor State,
> > Sensor Reading, Sensor Units, Sensor Event/Reading Type Code, Sensor
> > Event Bitmask, Sensor Event String
> > ipmi_monitoring_sensor_read_sensor_bitmask_strings: success
> >
> >
> > I'm unfortunately don't know much about C. You mean I should change
> > in 'unsigned int record_ids[] = {0};' the 0 to a sensor-id, right?
> > Because I did this and that neither worked with putting 5 in for the
> > power meter nor with any other sensor.
> >
> > Florian
> >
> >
> >
> > On Tue, Dec 4, 2018 at 7:47 PM Albert Chu  wrote:
> > > Didn't see your output, I guess you forgot to paste it in.
> > >
> > > H.  That means the main monitoring code is just returning "0",
> > > i.e.
> > > 0 sensors read.  Could you try experimenting with the settings and
> > > setting "record_ids" to the record we're trying to figure out (i
> > > think
> > > it was #5 in your prior post).  Lets just concentrate on that
> > > specific
> > > record and try to figure out what's going on.  Also set
> > > ipmimonitoring_init_flags for more debugging and lets see what gets
> > > output.
> > >
> > > BTW, could you please respond to the mailing list.
> > >
> > > Al
> > >
> > > On Tue, 2018-12-04 at 07:50 +0100, Florian Ströger wrote:
> > > > Hello Albert,
> > > >
> > > > Thanks for the fast reply!
> > > > I've set 'int ignore_non_interpretable_sensors' to 0, but when I
> > > run
> > > > the binary now it just outputs the headers, like this:
> > > >
> > > --
> > > Albert Chu
> > > ch...@llnl.gov
> > > Computer Scientist
> > > H

Re: [Freeipmi-devel] ipmimonitoring-sensors.c discretereading workaround

2018-12-04 Thread Albert Chu
Hey Florian,

Lets try:

unsigned int record_ids[] = {5, 0}; 
 
unsigned int record_ids_length = 1;

and

unsigned int ipmimonitoring_init_flags = IPMI_MONITORING_FLAGS_DEBUG;

Al

On Tue, 2018-12-04 at 20:16 +0100, Florian wrote:
> Oops, I'm sorry, Android-Mail apparently deleted the CC...
> 
> I compiled with ipmimonitoring_init_flags = 1 now and got debug stuff
> this time.
> 
> The output is following...
> (ipmi_monitoring_sensor_reading.c,
> ipmi_monitoring_get_sensor_reading, 1061): record_type '0xC0' not
> supported
> (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type, 752):
> event_reading_type_code '0x70' bitmask is OEM
> (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type, 752):
> event_reading_type_code '0x71' bitmask is OEM
> (ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type, 752):
> event_reading_type_code '0x71' bitmask is OEM
> (ipmi_monitoring_sensor_reading.c,
> ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8' not
> supported
> (ipmi_monitoring_sensor_reading.c,
> ipmi_monitoring_get_sensor_reading, 1061): record_type '0x8' not
> supported
> (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> ipmi_sensor_read: sensor reading unavailable
> (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> cannot read sensor for record id '23'
> (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> ipmi_sensor_read: sensor reading unavailable
> (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> cannot read sensor for record id '24'
> (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> ipmi_sensor_read: sensor reading unavailable
> (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> cannot read sensor for record id '38'
> (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> ipmi_sensor_read: sensor reading unavailable
> (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> cannot read sensor for record id '39'
> (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> ipmi_sensor_read: sensor reading unavailable
> (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> cannot read sensor for record id '40'
> (ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
> ipmi_sensor_read: sensor reading unavailable
> (ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571):
> cannot read sensor for record id '41'
> Record ID, Sensor Name, Sensor Number, Sensor Type, Sensor State,
> Sensor Reading, Sensor Units, Sensor Event/Reading Type Code, Sensor
> Event Bitmask, Sensor Event String
> ipmi_monitoring_sensor_read_sensor_bitmask_strings: success
> 
> 
> I'm unfortunately don't know much about C. You mean I should change
> in 'unsigned int record_ids[] = {0};' the 0 to a sensor-id, right?
> Because I did this and that neither worked with putting 5 in for the
> power meter nor with any other sensor.
> 
> Florian
> 
> 
> 
> On Tue, Dec 4, 2018 at 7:47 PM Albert Chu  wrote:
> > Didn't see your output, I guess you forgot to paste it in.
> > 
> > H.  That means the main monitoring code is just returning "0",
> > i.e.
> > 0 sensors read.  Could you try experimenting with the settings and
> > setting "record_ids" to the record we're trying to figure out (i
> > think
> > it was #5 in your prior post).  Lets just concentrate on that
> > specific
> > record and try to figure out what's going on.  Also set
> > ipmimonitoring_init_flags for more debugging and lets see what gets
> > output.
> > 
> > BTW, could you please respond to the mailing list.
> > 
> > Al
> > 
> > On Tue, 2018-12-04 at 07:50 +0100, Florian Ströger wrote:
> > > Hello Albert, 
> > > 
> > > Thanks for the fast reply!
> > > I've set 'int ignore_non_interpretable_sensors' to 0, but when I
> > run
> > > the binary now it just outputs the headers, like this:
> > >    
> > -- 
> > Albert Chu
> > ch...@llnl.gov
> > Computer Scientist
> > High Performance Systems Division
> > Lawrence Livermore National Laboratory
> > 
> > 
> 
> 
-- 
Albert Chu
ch...@llnl.gov
Computer Scientist
High Performance Systems Division
Lawrence Livermore National Laboratory


___
Freeipmi-devel mailing list
Freeipmi-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/freeipmi-devel


Re: [Freeipmi-devel] ipmimonitoring-sensors.c discretereading workaround

2018-12-04 Thread Florian
Oops, I'm sorry, Android-Mail apparently deleted the CC...

I compiled with ipmimonitoring_init_flags = 1 now and got debug stuff this
time.

The output is following...
(ipmi_monitoring_sensor_reading.c, ipmi_monitoring_get_sensor_reading,
1061): record_type '0xC0' not supported
(ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type, 752):
event_reading_type_code '0x70' bitmask is OEM
(ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type, 752):
event_reading_type_code '0x71' bitmask is OEM
(ipmi_monitoring_sensor_reading.c, _get_sensor_bitmask_type, 752):
event_reading_type_code '0x71' bitmask is OEM
(ipmi_monitoring_sensor_reading.c, ipmi_monitoring_get_sensor_reading,
1061): record_type '0x8' not supported
(ipmi_monitoring_sensor_reading.c, ipmi_monitoring_get_sensor_reading,
1061): record_type '0x8' not supported
(ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
ipmi_sensor_read: sensor reading unavailable
(ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571): cannot
read sensor for record id '23'
(ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
ipmi_sensor_read: sensor reading unavailable
(ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571): cannot
read sensor for record id '24'
(ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
ipmi_sensor_read: sensor reading unavailable
(ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571): cannot
read sensor for record id '38'
(ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
ipmi_sensor_read: sensor reading unavailable
(ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571): cannot
read sensor for record id '39'
(ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
ipmi_sensor_read: sensor reading unavailable
(ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571): cannot
read sensor for record id '40'
(ipmi_monitoring_sensor_reading.c, _get_sensor_reading, 356):
ipmi_sensor_read: sensor reading unavailable
(ipmi_monitoring_sensor_reading.c, _threshold_sensor_reading, 571): cannot
read sensor for record id '41'
Record ID, Sensor Name, Sensor Number, Sensor Type, Sensor State, Sensor
Reading, Sensor Units, Sensor Event/Reading Type Code, Sensor Event
Bitmask, Sensor Event String
ipmi_monitoring_sensor_read_sensor_bitmask_strings: success


I'm unfortunately don't know much about C. You mean I should change in
'unsigned int record_ids[] = {0};' the 0 to a sensor-id, right? Because I
did this and that neither worked with putting 5 in for the power meter nor
with any other sensor.

Florian



On Tue, Dec 4, 2018 at 7:47 PM Albert Chu  wrote:

> Didn't see your output, I guess you forgot to paste it in.
>
> H.  That means the main monitoring code is just returning "0", i.e.
> 0 sensors read.  Could you try experimenting with the settings and
> setting "record_ids" to the record we're trying to figure out (i think
> it was #5 in your prior post).  Lets just concentrate on that specific
> record and try to figure out what's going on.  Also set
> ipmimonitoring_init_flags for more debugging and lets see what gets
> output.
>
> BTW, could you please respond to the mailing list.
>
> Al
>
> On Tue, 2018-12-04 at 07:50 +0100, Florian Ströger wrote:
> > Hello Albert,
> >
> > Thanks for the fast reply!
> > I've set 'int ignore_non_interpretable_sensors' to 0, but when I run
> > the binary now it just outputs the headers, like this:
> >
> --
> Albert Chu
> ch...@llnl.gov
> Computer Scientist
> High Performance Systems Division
> Lawrence Livermore National Laboratory
>
>

-- 
Florian Ströger
Zur Rossschwemme 5
3452 Atzenbrugg

___
Freeipmi-devel mailing list
Freeipmi-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/freeipmi-devel


Re: [Freeipmi-devel] ipmimonitoring-sensors.c discretereading workaround

2018-12-03 Thread Albert Chu
Hi Florian,

Assuming you're using a modern version of FreeIPMI, the
"ipmimonitoring" command that comes with FreeIPMI simply points to
ipmi-sensors with some specific options set.  That was a legacy
decision, and perhaps I should revisit that as it might cause
confusion.

So the behaviors might have subtle differences.  So lets just
concentrate on the ipmimonitoring-sensors.c output.

Lets start by setting:

int ignore_non_interpretable_sensors = 1;

to 0, b/c that's probably why sensor 5 isn't showing up.  Basically,
this configuration says "if you can't come up with NORMAL, WARNING,
CRITICAL for this sensor, don't output it".  I don't think there are
any "current" rules for determining normal vs warning vs critical (see
freeipmi_interpret_sensors.conf).

As for the output of sensors 8 & 9, I'm betting there might be a bug in
the ipmimonitoring-sensors.c since discrete_reading is sort of an
oddball case.  I'll take a look later on, but lets start with sensor
#5.

Al

On Mon, 2018-12-03 at 20:02 +0100, Florian wrote:
> Hello,
> 
> $ipmimonitoring -W discretereading gives me the Output of the Power
> Meter like this "5  | Power Meter | Current  | N/A  |
> 168.00 | W | 'Device Enabled'" here you can clearly see the
> wattage. In this case 168W.
> If I just use $ipmimonitoring I get "5  | Power Meter |
> Current  | N/A  | N/A    | N/A   | 'Device Enabled'". No
> wattage at all.
> 
> If I compile ipmimonitoring-sensors.c and run it, I don't get the
> sensor 5 (Power Meter) at all. 
> 
> Also there are 2 other sensors (8,9), as seen below, who are giving
> also wattage readings with $ipmimonitoring -W discretereading 
> 8  | Power Supply 1  | Power Supply | Nominal  | 45.00  | W |
> 'Presence detected'
> 9  | Power Supply 2  | Power Supply | Nominal  | 35.00  | W |
> 'Presence detected'
> 
> but with ipmimonitoring-sensors I only get
> 8, Power Supply 1, 8, Power Supply, Nominal, N/A, N/A, 6Fh, 1h,
> 'Presence detected'
> 9, Power Supply 2, 9, Power Supply, Nominal, N/A, N/A, 6Fh, 1h,
> 'Presence detected'
> (like with $ipmimonitoring without the discretereading workaround
> flag)
> I've tried to set int discrete_reading to 1, but I got the same
> results.
> Unfortunately I couldn't find any documentation about setting the
> workaround in the ipmimonitoring-sensors.c library, so thats why I'm
> asking here.
> 
> Related links: 
> https://github.com/netdata/netdata/blob/master/collectors/freeipmi.pl
> ugin/freeipmi_plugin.c (implementation of ipmimonitoring-sensors.c
> into netdata (a performance monitoring webinterface)
> https://github.com/netdata/netdata/issues/3977 (Issue we have over
> there showing the wattages).
> 
> Since this neither works with http://www.gnu.org/software/freeipmi/ip
> mimonitoring-sensors.c, I thought I would ask here.
> 
> Sincerely,
> Florian Ströger (Preisschild)
> ___
> Freeipmi-devel mailing list
> Freeipmi-devel@gnu.org
> https://lists.gnu.org/mailman/listinfo/freeipmi-devel
-- 
Albert Chu
ch...@llnl.gov
Computer Scientist
High Performance Systems Division
Lawrence Livermore National Laboratory


___
Freeipmi-devel mailing list
Freeipmi-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/freeipmi-devel