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 2178610 - Entitlement certificate related errors logged in /var/log/rhsm/rhsm.log when simple content access enabled.
Summary: Entitlement certificate related errors logged in /var/log/rhsm/rhsm.log when ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: subscription-manager
Version: unspecified
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: rc
: 9.3
Assignee: Pino Toscano
QA Contact: Red Hat subscription-manager QE Team
URL:
Whiteboard:
Depends On:
Blocks: 1982670 2221711
TreeView+ depends on / blocked
 
Reported: 2023-03-15 12:17 UTC by Pino Toscano
Modified: 2023-11-07 11:20 UTC (History)
13 users (show)

Fixed In Version: subscription-manager-1.29.34-1.el9
Doc Type: No Doc Update
Doc Text:
Clone Of: 1982670
: 2221711 (view as bug list)
Environment:
Last Closed: 2023-11-07 08:51:53 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github candlepin subscription-manager pull 3226 0 None Merged 2178610: do not collect unentitled products in SCA mode 2023-03-24 07:37:34 UTC
Github candlepin subscription-manager pull 3229 0 None Merged test: add simple test for 2178610 2023-03-24 07:37:32 UTC
Red Hat Issue Tracker RHELPLAN-151925 0 None None None 2023-03-15 12:18:06 UTC
Red Hat Product Errata RHBA-2023:6606 0 None None None 2023-11-07 08:52:11 UTC

Description Pino Toscano 2023-03-15 12:17:28 UTC
+++ This bug was initially created as a clone of Bug #1982670 +++

Description of problem:

System is registered to Satellite successfully using SCA but some entitlement certificate related messages/errors are keep getting generated in /var/log/rhsm/rhsm.log. 

Steps to Reproduce:

[root@rhel8client ~]# cat /etc/redhat-release 
Red Hat Enterprise Linux release 8.3 (Ootpa)

[root@rhel8client ~]# rpm -qa | grep subscription-manager
subscription-manager-1.28.13-3.el8_4.x86_64
subscription-manager-rhsm-certificates-1.28.13-3.el8_4.x86_64
dnf-plugin-subscription-manager-1.28.13-3.el8_4.x86_64
subscription-manager-cockpit-1.28.13-3.el8_4.noarch
python3-subscription-manager-rhsm-1.28.13-3.el8_4.x86_64

[root@rhel8client ~]# syspurpose show
{}

[root@rhel8client ~]# syspurpose set-role "Red Hat Enterprise Linux Workstation"
role set to "Red Hat Enterprise Linux Workstation".
[root@rhel8client ~]# syspurpose show
{
  "role": "Red Hat Enterprise Linux Workstation"
}

[root@rhel8client ~]# subscription-manager status
+-------------------------------------------+
   System Status Details
+-------------------------------------------+
Overall Status: Disabled
Content Access Mode is set to Simple Content Access. This host has access to content, regardless of subscription status.

System Purpose Status: Disabled

[root@rhel8client ~]# ls /etc/pki/product-default/
479.pem

[root@rhel8client ~]# yum update -y

[root@rhel8client ~]# cat /etc/redhat-release 
Red Hat Enterprise Linux release 8.4 (Ootpa)

[root@rhel8client ~]# syspurpose show
{
  "role": "Red Hat Enterprise Linux Workstation"

[root@rhel8client ~]# ls /etc/pki/product
product/         product-default/ 

[root@rhel8client ~]# ls /etc/pki/product-default/
479.pem

/var/log/rhsm/rhsm.log

Total updates: 1
Found (local) serial# []
Expected (UEP) serial# [5615889862954254283]
Added (new)
  [sn:5615889862954254283 ( Content Access,) @ /etc/pki/entitlement/5615889862954254283.pem]
Deleted (rogue):
  <NONE>
2021-07-11 09:26:31,973 [WARNING] subscription-manager:5798:MainThread @cert_sorter.py:194 - Installed product 479 not present in response from server.
2021-07-11 09:26:50,363 [INFO] yum:5803:MainThread @entcertlib.py:131 - certs updated:
Total updates: 1
Found (local) serial# []
Expected (UEP) serial# [5615889862954254283]
Added (new)
  [sn:5615889862954254283 ( Content Access,) @ /etc/pki/entitlement/5615889862954254283.pem]
Deleted (rogue):

Actual results:

Above error generated in /var/log/rhsm/rhsm.log

Expected results:

Need to avoid unwanted messages from the logs.

Comment 1 Jan Stavel 2023-03-27 19:59:57 UTC
I have installed a product certificate 479.pem into /etc/pki/product-default.
A warning about certificate appeared in the log file.

2023-03-27 08:46:09,536 [WARNING] subscription-manager:22559:MainThread @cert_sorter.py:194 - Installed product 479 not present in response from server.

[root@sgi-uv30-01 ~]# subscription-manager syspurpose role --set "Red Hat Enterprise Linux Workstation"
Warning: Provided value "Red Hat Enterprise Linux Workstation" is not included in the list of valid values
 - Red Hat Enterprise Linux Server
role set to "Red Hat Enterprise Linux Workstation".
[root@sgi-uv30-01 ~]# 

root@sgi-uv30-01 ~]# subscription-manager status
+-------------------------------------------+
   System Status Details
+-------------------------------------------+
Overall Status: Disabled
Content Access Mode is set to Simple Content Access. This host has access to content, regardless of subscription status.

System Purpose Status: Disabled



After I updated package subscription-manager to the latest version provided by a jenkins build job no warning appeared.

Comment 5 Zdenek Petracek 2023-04-18 12:54:19 UTC
Final verification done on sub-man version:
[root@kvm-01-guest09 ~]# subscription-manager version
server type: This system is currently not registered.
subscription management server: 4.2.15-1
subscription management rules: 5.43
subscription-manager: 1.29.34-1.el9

[root@kvm-01-guest09 ~]# cat /etc/redhat-release 
Red Hat Enterprise Linux release 9.3 Beta (Plow)

[root@kvm-01-guest09 ~]# subscription-manager status
+-------------------------------------------+
   System Status Details
+-------------------------------------------+
Overall Status: Disabled
Content Access Mode is set to Simple Content Access. This host has access to content, regardless of subscription status.

System Purpose Status: Disabled



Updating the certificate:
[root@kvm-01-guest09 product-default]# ls /etc/pki/product-default/
479.pem

cat /var/log/rhsm/rhsm.log:
2023-04-18 12:54:04,000 [INFO] subscription-manager:16517:MainThread @managerlib.py:103 - Consumer created: kvm-01-guest09.lab.eng.brq2.redhat.com (414ccbfc-bc31-4bbe-a79c-94a8ab2003e8)
2023-04-18 12:54:06,834 [INFO] subscription-manager:16517:MainThread @entcertlib.py:107 - certs updated:
Total updates: 1
Found (local) serial# []
Expected (UEP) serial# [7365450278341807506]
Added (new)
  [sn:7365450278341807506 ( Content Access,) @ /etc/pki/entitlement/7365450278341807506.pem]
Deleted (rogue):
  <NONE>

^^ There was no "[WARNING] subscription-manager:5798:MainThread @cert_sorter.py:194 - Installed product 479 not present in response from server." error -> PASSED

Comment 10 errata-xmlrpc 2023-11-07 08:51:53 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (subscription-manager bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2023:6606


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