Uploaded image for project: 'Observium'
  1. Observium
  2. OBS-3187

IPMI chassis en power supply support

Details

    • Bug
    • Resolution: Fixed
    • Major
    • None
    • Professional Edition
    • Unix Agent

    Description

      The function parse_ipmitool_sensor() is not working correctly due to the empty discrete value in includes/definitions/entities/sensors.inc.php.

      The following statements in parse_ipmitool_sensor() (includes/entities/sensor.inc.php) returns true if the $unit is discrete:

      if (isset($config['ipmi_unit'][$unit])) {
      

      and the code below (from OBS-3028) will never run:

      } elseif ($unit == 'discrete') {
      

      because an empty value is set in the array, so isset() returns true.

      The attached patch will remove empty value from the array. Another option could be checking is there is an actual value in the unit-array:

      if (isset($config['ipmi_unit'][$unit]) && $config['ipmi_unit'][$unit]) {
      

      Attachments

        1. ipmi_discrete.diff
          0.5 kB
        2. ipmi_patch_bernard.diff
          4 kB
        3. ipmi_patch_rework.diff
          4 kB
        4. ipmi_sensors.diff
          3 kB
        5. ipmi_sensors.diff
          3 kB
        6. ipmitool-sdr-r730.txt
          69 kB
        7. ipmitool-sensors-r730.txt
          21 kB
        8. poller_patched.log
          115 kB
        9. poller.log
          111 kB
        10. poller-r730.txt
          329 kB

        Issue Links

          Activity

            [OBS-3187] IPMI chassis en power supply support
            diamondweaver Rafael Wilms made changes -
            Link New: This issue is mentioned by OBS-3670 [ OBS-3670 ]
            bot Observium Bot made changes -
            Status Original: Resolved [ 5 ] New: Closed [ 6 ]
            veldenb Bernard van der Velden made changes -
            Attachment New: ipmi_patch_bernard.diff [ 17432 ]
            veldenb Bernard van der Velden made changes -
            Attachment New: ipmi_patch_rework.diff [ 17431 ]
            andrewbonney Andrew Bonney made changes -
            Attachment New: ipmitool-sdr-r730.txt [ 17419 ]
            Attachment New: ipmitool-sensors-r730.txt [ 17420 ]
            Attachment New: poller-r730.txt [ 17421 ]
            landy Mike Stupalov made changes -
            Link New: This issue relates to OBS-3315 [ OBS-3315 ]
            landy Mike Stupalov made changes -
            Resolution New: Fixed [ 1 ]
            Status Original: In Progress [ 3 ] New: Resolved [ 5 ]
            landy Mike Stupalov made changes -
            Status Original: Pending Response [ 10000 ] New: In Progress [ 3 ]
            landy Mike Stupalov made changes -
            Status Original: In Review [ 10101 ] New: Pending Response [ 10000 ]
            andrewbonney Andrew Bonney made changes -
            Attachment New: ipmi_sensors.diff [ 17408 ]

            People

              landy Mike Stupalov
              veldenb Bernard van der Velden
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: