RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2067129 - dbus: After subscription attachement EntitlementChanged signal is sent but GetStatus still returns "status: Unknown"
Summary: dbus: After subscription attachement EntitlementChanged signal is sent but Ge...
Keywords:
Status: CLOSED INSUFFICIENT_DATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: subscription-manager
Version: 7.9
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: 7.9
Assignee: candlepin-bugs
QA Contact: Red Hat subscription-manager QE Team
URL:
Whiteboard: CockpitTest
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-03-23 11:34 UTC by Simon Kobyda
Modified: 2023-09-15 01:53 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-06-28 10:07:33 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-116474 0 None None None 2022-03-23 11:38:14 UTC

Internal Links: 2074228

Description Simon Kobyda 2022-03-23 11:34:10 UTC
Description of problem:
In our cockpit tests we caught a regression for RHEL 7.9. We listen to a signal EntitlementChanged and when the signal is caught, we fetch the status using GetStatus. However, with a rhel 7.9 update, it seems that after attaching a subscription, the signal is triggered but the GetStatus method still returns "status: Unknown"

Version-Release number of selected component (if applicable):
subscription management server: 4.1.8-1
subscription management rules: 5.43
subscription-manager: 1.24.50-1.el7_

How reproducible:


Steps to Reproduce:
1. Listen to to a RHSM1 signal:
    path: "/com/redhat/RHSM1/Entitlement",
    interface: "com.redhat.RHSM1.Entitlement",
    member: "EntitlementChanged"
and have a callback to fetch subscription status when signal is caught:
    path: "/com/redhat/RHSM1/Entitlement"
    interface: "com.redhat.RHSM1.Entitlement"
    method: "GetStatus"

(Alternatively, you can listen to signals from CLI using: 
$dbus-monitor --system "interface='com.redhat.RHSM1.Entitlement',type='signal'")

2. subscription-manager register --insecure --serverurl [my_url]/candlepin --org=admin --activationkey=[my_key]

3. subscription-manager attach --auto

Actual results:
During/After step 3, a signal EntitlementChanged is caught, but callback GetStatus returns { status: "Unknown", valid: false }

Expected results:
During/After step 3, a signal EntitlementChanged is caught and callback GetStatus should return { status: "Subscribed", valid: true }

Additional info:
After step 3, if I check status manually, subscription-manager correctly says "Subscribed". This leads me to believe that this could be a race condition where the signal EntitlementChanged is triggered before the change is actually finalized, leading to the callback GetStatus fetching the old status of an subscription.

Comment 3 Marius Vollmer 2022-03-25 10:04:18 UTC
Please also see https://bugzilla.redhat.com/show_bug.cgi?id=2030265

Comment 4 Jan Stavel 2022-04-12 14:35:28 UTC
Hello,
I've tried
- open firefox with Subscriptions main page
- dbus-monitor --system
- subscription-manager register --activationkey={{ activation_key }} --org={{ rhsm.org }}
- subscription-manager attach --auto


... no GetStatus appears after an EntitlementChanges signals appears at dbus

A sequence of status field values at Cockpit Subscriptions Page was: 'Invalid', 'Current'

see a list of messages captured at dbus:

1th case (subscription-manager register ....)
 Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=130
  Sender=:1.56  Path=/com/redhat/RHSM1/Consumer  Interface=com.redhat.RHSM1.Consumer  Member=ConsumerChanged
  UniqueName=:1.56
  MESSAGE "" {
  };

‣ Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=131
  Sender=:1.56  Path=/com/redhat/RHSM1/Consumer  Interface=com.redhat.RHSM1.Consumer  Member=ConsumerChanged
  UniqueName=:1.56
  MESSAGE "" {
  };

‣ Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=132
  Sender=:1.56  Path=/com/redhat/RHSM1/Syspurpose  Interface=com.redhat.RHSM1.Syspurpose  Member=SyspurposeChanged
  UniqueName=:1.56
  MESSAGE "" {
  };

‣ Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=6
  Sender=:1.199  Path=/EntitlementStatus  Interface=com.redhat.SubscriptionManager.EntitlementStatus  Member=entitlement_status_changed
  UniqueName=:1.199
  MESSAGE "i" {
          INT32 1;
  };

‣ Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=945
  Sender=org.freedesktop.DBus  Path=/org/freedesktop/DBus  Interface=org.freedesktop.DBus  Member=NameOwnerChanged
  MESSAGE "sss" {
          STRING "com.redhat.SubscriptionManager";
          STRING ":1.199";
          STRING "";
  };





2nd case (subscription-manager attach ...)
 Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=141
  Sender=:1.56  Path=/com/redhat/RHSM1/Syspurpose  Interface=com.redhat.RHSM1.Syspurpose  Member=SyspurposeChanged
  UniqueName=:1.56
  MESSAGE "" {
  };

‣ Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=142
  Sender=:1.56  Path=/com/redhat/RHSM1/Syspurpose  Interface=com.redhat.RHSM1.Syspurpose  Member=SyspurposeChanged
  UniqueName=:1.56
  MESSAGE "" {
  };

‣ Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=147
  Sender=:1.56  Path=/com/redhat/RHSM1/Entitlement  Interface=com.redhat.RHSM1.Entitlement  Member=EntitlementChanged
  UniqueName=:1.56
  MESSAGE "" {
  };

‣ Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=148
  Sender=:1.56  Path=/com/redhat/RHSM1/Entitlement  Interface=com.redhat.RHSM1.Entitlement  Member=EntitlementChanged
  UniqueName=:1.56
  MESSAGE "" {
  };

‣ Type=signal  Endian=l  Flags=1  Version=1  Priority=0 Cookie=9
  Sender=org.freedesktop.DBus  Path=/org/freedesktop/DBus  Interface=org.freedesktop.DBus  Member=NameOwnerChanged
  MESSAGE "sss" {
          STRING "org.freedesktop.hostname1";
          STRING ":1.207";
          STRING "";
  };

Comment 5 Jan Stavel 2022-04-12 16:36:13 UTC
I cannot reproduce this bug. in rhel7.9 either in rhel8.7

Comment 7 Rehana 2022-06-28 10:07:33 UTC
Bugzilla backlog clean up:
-------------------------

Thanks for reporting the bug, unfortunately we can not proceed with the troubleshooting on this bug with out the additional details requested. Hence we are closing the bug, please feel free to reach out to us if the issue is still reproducible at your end.

Thanks,
Rehana

Comment 8 Red Hat Bugzilla 2023-09-15 01:53:10 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 365 days


Note You need to log in before you can comment on or make changes to this bug.