Missed interfacesRemoved signal callbacks in object-mapper results in invalidated DBus objects

Lei Yu yulei.sh at bytedance.com
Tue Mar 29 00:19:40 AEDT 2022


An issue that is related to missed match callbacks is noticed and it
causes the inconsistency between object-mapper and the dbus objects.

Steps to reproduce on g220a QEMU (it is not 100% reproducible and when
it occurs it likely occurs on the first try when BMC boots)

1. Generate several logging entries
2. Call logging service's DeleteAll
3. Check the objects of logging service, all entries are deleted
 ```
 # busctl tree xyz.openbmc_project.Logging
 `-/xyz
   `-/xyz/openbmc_project
     `-/xyz/openbmc_project/logging
       `-/xyz/openbmc_project/logging/internal
         `-/xyz/openbmc_project/logging/internal/manager
 ```
4. Check the entries via object-mapper, it gets the entries
 ```
 # busctl call xyz.openbmc_project.ObjectMapper
/xyz/openbmc_project/object_mapper xyz.openbmc_project.ObjectMapper
GetObject sas /xyz/openbmc_project/logging/entry/1 0
 a{sas} 1 "xyz.openbmc_project.Logging" 8
"org.freedesktop.DBus.Introspectable" "org.freedesktop.DBus.Peer"
"org.freedesktop.DBus.Properties"
"xyz.openbmc_project.Association.Definitions" "xyz.open
bmc_project.Common.FilePath" "xyz.openbmc_project.Logging.Entry"
"xyz.openbmc_project.Object.Delete"
"xyz.openbmc_project.Software.Version"
 ```
5. I could verify that the DBus object does not really exist:
 ```
 # busctl introspect "xyz.openbmc_project.Logging"
/xyz/openbmc_project/logging/entry/1
 Failed to introspect object /xyz/openbmc_project/logging/entry/1 of
service xyz.openbmc_project.Logging: Unknown object
'/xyz/openbmc_project/logging/entry/1'.
 ```

I also added some logs in my service to get callbacks of the
interfacesRemoved signal, and it shows that I really do not get the
callbacks for some objects.
For example, in one test I have 41 logging entries, and my service
only gets `interfacesRemoved` callback for entry 18~41, this causes
the object-mapper to show the remaining 1~17 entries while they do not
really exist on DBus.

This looks like some fundamental issue in dbus-broker or sdbusplus.
Is there anyone who hits the similar issue?

-- 
BRs,
Lei YU


More information about the openbmc mailing list