Exposing sensors to IPMI over dbus

AKASH G J akashgj91 at gmail.com
Fri Dec 20 23:08:39 AEDT 2019


Thanks for the help.

I changed  "Probe" : "TRUE", now entity manager configuration file is
parsed and published to dbus a configuration.

root at rudra:~# busctl introspect --no-pager
xyz.openbmc_project.EntityManager \
> /xyz/openbmc_project/inventory/system/board/Rudra_Baseboard/bmc_temp
NAME                                                TYPE      SIGNATURE
RESULT/VALUE     FLAGS
org.freedesktop.DBus.Introspectable                 interface -         -
             -
.Introspect                                         method    -         s
             -
org.freedesktop.DBus.Peer                           interface -         -
             -
.GetMachineId                                       method    -         s
             -
.Ping                                               method    -         -
             -
org.freedesktop.DBus.Properties                     interface -         -
             -
.Get                                                method    ss        v
             -
.GetAll                                             method    s
a{sv}            -
.Set                                                method    ssv       -
             -
.PropertiesChanged                                  signal    sa{sv}as  -
             -
xyz.openbmc_project.Configuration.TMP75             interface -         -
             -
.Address                                            property  s
"0x4a"           emits-change
.Bus                                                property  t         5
             emits-change
.Name                                               property  s
"bmc_temp"       emits-change
.Type                                               property  s
"TMP75"          emits-change
xyz.openbmc_project.Configuration.TMP75.Thresholds0 interface -         -
             -
.Delete                                             method    -         i
             -
.Direction                                          property  s
"greater than"   emits-change writable
.Name                                               property  s
"upper critical" emits-change writable
.Severity                                           property  d         1
             emits-change writable
.Value                                              property  d         80
              emits-change writable

dbus-sensors hwmon temperature sensor daemon is not recognizing the
configuration interface: xyz.openbmc_project.Configuration.TMP75

root at rudra:~# busctl tree --no-pager xyz.openbmc_project.HwmonTempSensor
Failed to introspect object / of service
xyz.openbmc_project.HwmonTempSensor: The name is not activatable
No objects discovered.

In journalctl log the following messages are coming.

hwmontempsensor[153]: Error communicating to entity manager
hwmontempsensor[566]: terminate called after throwing an instance of
'std::bad_variant_access'
hwmontempsensor[566]:   what():  Unexpected index
phosphor-mapper[210]: Introspect call failed with error: generic:110,
Connection timed out on process: xyz.openbmc_project.HwmonTempSensor path: /
systemd[1]: xyz.openbmc_project.hwmontempsensor.service: Main process
exited, code=killed, status=6/ABRT
systemd[1]: xyz.openbmc_project.hwmontempsensor.service: Failed with result
'signal'.
systemd[1]: xyz.openbmc_project.hwmontempsensor.service: Service
RestartSec=5s expired, scheduling restart.
systemd[1]: xyz.openbmc_project.hwmontempsensor.service: Scheduled restart
job, restart counter is at 4.
systemd[1]: Stopped Hwmon Temp Sensor.
phosphor-mapper[210]: Introspect call failed with error: generic:110,
Connection timed out on process: xyz.openbmc_project.HwmonTempSensor path: /
systemd-udevd[97]: Spawned process '/usr/bin/start_hwmon.sh start
/devices/platform/ahb/ahb:apb/ahb:apb:bus at 1e78a000/1e78a180.i2c-bus/i2c-5/5-004c/hwmon/hwmon2
/ahb/apb/bus at 1e78a000/i2c-bus at 180/tmp75 at 4c' [104] is taking longer than 59s
to complete



Thanks and Regards,

Akash

On Fri, Dec 20, 2019 at 12:42 AM James Feist <james.feist at linux.intel.com>
wrote:

> On 12/19/19 1:12 AM, AKASH G J wrote:
> > Hi all,
> > I am using OpenBMC firmware for server board having Aspeed AST-2500.
> >
> > Followed
> >
> https://github.com/openbmc/entity-manager/blob/master/docs/my_first_sensors.md
> > for populating sensor value to dbus. Entity manager configuration file
> > is given below.
> > {
> >      "Exposes": [
> >          {
> >              "Address": "0x4f",
> >              "Bus": 5,
> >              "Name": "cpu0_vrd_temp",
> >              "Thresholds": [
> >                  {
> >                      "Direction": "greater than",
> >                      "Name": "upper critical",
> >                      "Severity": 1,
> >                      "Value": 80
> >                  }
> >              ],
> >              "Type": "TMP75"
> >          }
> >      ],
> >      "Name": "Rudra Baseboard",
> >      "Probe": "xyz.openbmc_project.FruDevice({'PRODUCT_PRODUCT_NAME':
> > 'RUDRA'})",
> >      "Type": "Board",
> >      "xyz.openbmc_project.Inventory.Decorator.Asset": {
> >          "Manufacturer": "$BOARD_MANUFACTURER",
> >          "Model": "$BOARD_PRODUCT_NAME",
> >          "PartNumber": "$BOARD_PART_NUMBER",
> >          "SerialNumber": "$BOARD_SERIAL_NUMBER"
> >      }
> > }
> >
> > Wrote sample FRU information on eeprom with the following content. Used
> > dd command for writing to eeprom.
> >
> > root at s2600wf:/sys/bus/i2c/devices/3-0056# cat eeprom
> > Product:
> >    MANUFACTURER  "ABC"
> >    PART_NUMBER   "12345"
> >    PRODUCT_NAME  "SAMPLENAME"
> >    SERIAL_NUMBER "12312490840"
>
> This is not a legal IMPI FRU. FRU Device only allows legal fru based on
> the spec:
>
> https://www.intel.com/content/www/us/en/servers/ipmi/ipmi-platform-mgt-fru-infostorage-def-v1-0-rev-1-3-spec-update.html
>
> For testing purposes using "Probe" : "TRUE" can be used as well.
> >
> > The dbus tree not showing /xyz/openbmc_project/FruDevice/SAMPLENAME
> >
> > root at s2600wf:~# busctl tree --no-pager xyz.openbmc_project.FruDevice
> > `-/xyz
> >    `-/xyz/openbmc_project
> >      `-/xyz/openbmc_project/FruDevice
> >
> > In journalctl log the following messages are printed.
> >
> > systemd[1]: Started Hwmon Temp Sensor.
> > hwmontempsensor[120]: Error communicating to entity manager
> > hwmontempsensor[120]: error communicating to entity manager
> >
> > Look like FruDevice daemon is not parsing the contents of eeprom and
> > publish them to dbus.
> >
> > Is there any thing missing in configuration? Please help to resolve the
> > problem.
> >
> >
> >
> > Thanks,
> >
> > Akash
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ozlabs.org/pipermail/openbmc/attachments/20191220/d66dddbd/attachment.htm>


More information about the openbmc mailing list