Bug 1433479
Summary: | rhsmcertd-worker should check connection before locking | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Kevin Howell <khowell> |
Component: | subscription-manager | Assignee: | Kevin Howell <khowell> |
Status: | CLOSED ERRATA | QA Contact: | John Sefler <jsefler> |
Severity: | low | Docs Contact: | |
Priority: | medium | ||
Version: | 7.2 | CC: | csnyder, redakkan, skallesh |
Target Milestone: | rc | Keywords: | Triaged |
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2017-08-01 19:21:47 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Kevin Howell
2017-03-17 18:08:09 UTC
Steps to test (elaborating on comment 0): 1. subscription-manager register to hosted (ensure we're using port 443) 2. systemctl stop rhsmcertd 3. Configure the environment to drop traffic to port 443: firewall-cmd --direct --add-rule ipv4 filter OUTPUT 0 -p tcp -m tcp --dport=443 -j DROP 4. Run rhsmcertd-worker in the background: /usr/libexec/rhsmcertd-worker & 5. Wait a few seconds to ensure that rhsmcertd-worker has a chance to start its connections 6. Ensure that /var/run/rhsm/cert.pid does not exist 7. Ensure that yum --verbose repolist's output does not contain "Another process has the cert lock. We will not attempt to update certs or repos." Note that we could modify the test case to work against candlepin by changing port to 8443. (Previous versions should fail at both steps 6 and 7). To restore the environment: 1. firewall-cmd --direct --remove-rule ipv4 filter OUTPUT 0 -p tcp -m tcp --dport=443 -j DROP 2. systemctl start rhsmcertd Reproducer: [root@dell-pe-fc630-02 ~]# subscription-manager register Registering to: subscription.rhsm.stage.redhat.com:443/subscription Username: shwetha_tier1_test Password: The system has been registered with ID: 81246647-046b-4c37-9302-34087beee016 [root@dell-pe-fc630-02 ~]# systemctl stop rhsmcertd [root@dell-pe-fc630-02 ~]# firewall-cmd --direct --add-rule ipv4 filter OUTPUT 0 -p tcp -m tcp --dport=443 -j DROP success [root@dell-pe-fc630-02 ~]# /usr/libexec/rhsmcertd-worker & [1] 113905 [root@dell-pe-fc630-02 ~]# Updating entitlement certificates & repositories Fact updates status: None updates: [] exceptions: Package profile updates status: 0 updates: [] exceptions: Installed Products status: 0 updates: [] exceptions: [root@dell-pe-fc630-02 ~]# yum --verbose repolist Not loading "rhnplugin" plugin, as it is disabled Loading "product-id" plugin Loading "search-disabled-repos" plugin Loading "subscription-manager" plugin Updating Subscription Management repositories. Another process has the cert lock. We will not attempt to update certs or repos. This system is registered with an entitlement server, but is not receiving updates. You can use subscription-manager to assign subscriptions. Config time: 0.134 Yum version: 3.4.3 Setting up Package Sacks pkgsack time: 0.020 Repo-id : beaker-Server Repo-name : beaker-Server Repo-revision: 1493661878 Repo-updated : Mon May 1 14:04:38 2017 Repo-pkgs : 5,130 Repo-size : 3.7 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server/x86_64/os Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:50 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server.repo Repo-id : beaker-Server-HighAvailability Repo-name : beaker-Server-HighAvailability Repo-revision: 1493661903 Repo-updated : Mon May 1 14:05:03 2017 Repo-pkgs : 35 Repo-size : 13 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server/x86_64/os/addons/HighAvailability Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:50 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-HighAvailability.repo Repo-id : beaker-Server-NFV Repo-name : beaker-Server-NFV Repo-revision: 1493661908 Repo-updated : Mon May 1 14:05:09 2017 Repo-pkgs : 21 Repo-size : 235 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-NFV/x86_64/os Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:50 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-NFV.repo Repo-id : beaker-Server-NFV-debuginfo Repo-name : beaker-Server-NFV-debuginfo Repo-revision: 1493661909 Repo-updated : Mon May 1 14:05:09 2017 Repo-pkgs : 9 Repo-size : 1.2 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-NFV/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:50 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-NFV-debuginfo.repo Repo-id : beaker-Server-RT Repo-name : beaker-Server-RT Repo-revision: 1493661915 Repo-updated : Mon May 1 14:05:15 2017 Repo-pkgs : 15 Repo-size : 233 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-RT/x86_64/os Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:50 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-RT.repo Repo-id : beaker-Server-RT-debuginfo Repo-name : beaker-Server-RT-debuginfo Repo-revision: 1493661916 Repo-updated : Mon May 1 14:05:16 2017 Repo-pkgs : 6 Repo-size : 1.2 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-RT/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:51 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-RT-debuginfo.repo Repo-id : beaker-Server-ResilientStorage Repo-name : beaker-Server-ResilientStorage Repo-revision: 1493661928 Repo-updated : Mon May 1 14:05:28 2017 Repo-pkgs : 40 Repo-size : 15 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server/x86_64/os/addons/ResilientStorage Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:51 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-ResilientStorage.repo Repo-id : beaker-Server-SAP Repo-name : beaker-Server-SAP Repo-revision: 1493661942 Repo-updated : Mon May 1 14:05:42 2017 Repo-pkgs : 12 Repo-size : 1.6 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-SAP/x86_64/os Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:51 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-SAP.repo Repo-id : beaker-Server-SAP-debuginfo Repo-name : beaker-Server-SAP-debuginfo Repo-revision: 1493661944 Repo-updated : Mon May 1 14:05:44 2017 Repo-pkgs : 6 Repo-size : 5.3 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-SAP/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:51 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-SAP-debuginfo.repo Repo-id : beaker-Server-SAPHANA Repo-name : beaker-Server-SAPHANA Repo-revision: 1493661949 Repo-updated : Mon May 1 14:05:49 2017 Repo-pkgs : 4 Repo-size : 864 k Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-SAPHANA/x86_64/os Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:51 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-SAPHANA.repo Repo-id : beaker-Server-SAPHANA-debuginfo Repo-name : beaker-Server-SAPHANA-debuginfo Repo-revision: 1493661951 Repo-updated : Mon May 1 14:05:51 2017 Repo-pkgs : 3 Repo-size : 4.9 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-SAPHANA/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:51 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-SAPHANA-debuginfo.repo Repo-id : beaker-Server-debuginfo Repo-name : beaker-Server-debuginfo Repo-revision: 1493661883 Repo-updated : Mon May 1 14:04:43 2017 Repo-pkgs : 2,167 Repo-size : 11 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:51 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-debuginfo.repo Repo-id : beaker-Server-optional Repo-name : beaker-Server-optional Repo-revision: 1493662012 Repo-updated : Mon May 1 14:06:52 2017 Repo-pkgs : 4,406 Repo-size : 3.7 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-optional/x86_64/os Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:51 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-optional.repo Repo-id : beaker-Server-optional-debuginfo Repo-name : beaker-Server-optional-debuginfo Repo-revision: 1493662004 Repo-updated : Mon May 1 14:06:44 2017 Repo-pkgs : 226 Repo-size : 1.9 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-optional/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:52 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-optional-debuginfo.repo Repo-id : beaker-harness Repo-name : beaker-harness Repo-revision: 1489364031 Repo-updated : Sun Mar 12 20:13:51 2017 Repo-pkgs : 214 Repo-size : 316 M Repo-baseurl : http://beaker.engineering.redhat.com/harness/RedHatEnterpriseLinux7/ Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:52 2017) Filter : read-only:present Repo-excluded: 247 Repo-filename: /etc/yum.repos.d/beaker-harness.repo Repo-id : beaker-tasks Repo-name : beaker-tasks Repo-revision: 1493707537 Repo-updated : Tue May 2 02:45:37 2017 Repo-pkgs : 24,123 Repo-size : 2.3 G Repo-baseurl : http://beaker.engineering.redhat.com/repos/3794529 Repo-expire : 21,600 second(s) (last: Mon May 8 04:35:52 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-tasks.repo repolist: 36,417 Verification: [root@dell-pe-fc630-02 ~]# subscription-manager version server type: Red Hat Subscription Management subscription management server: 0.9.51.21-1 subscription management rules: 5.15.1 subscription-manager: 1.19.12-1.el7 python-rhsm: 1.19.6-1.el7 [root@dell-pe-fc630-02 ~]# subscription-manager register Registering to: subscription.rhsm.stage.redhat.com:443/subscription Username: shwetha_tier1_test Password: The system has been registered with ID: 3eed8303-e198-43ef-bbba-212e2022b32c [root@dell-pe-fc630-02 ~]# systemctl stop rhsmcertd [root@dell-pe-fc630-02 ~]# firewall-cmd --direct --add-rule ipv4 filter OUTPUT 0 -p tcp -m tcp --dport=443 -j DROP success [root@dell-pe-fc630-02 ~]# /usr/libexec/rhsmcertd-worker & [1] 116526 [root@dell-pe-fc630-02 ~]# yum --verbose repolist Not loading "rhnplugin" plugin, as it is disabled Loading "product-id" plugin Loading "search-disabled-repos" plugin Loading "subscription-manager" plugin Updating Subscription Management repositories. Unable to update entitlement certificates and repositories This system is registered with an entitlement server, but is not receiving updates. You can use subscription-manager to assign subscriptions. Config time: 127.398 Yum version: 3.4.3 Setting up Package Sacks pkgsack time: 0.020 Repo-id : beaker-Server Repo-name : beaker-Server Repo-revision: 1493661878 Repo-updated : Mon May 1 14:04:38 2017 Repo-pkgs : 5,130 Repo-size : 3.7 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server/x86_64/os Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server.repo Repo-id : beaker-Server-HighAvailability Repo-name : beaker-Server-HighAvailability Repo-revision: 1493661903 Repo-updated : Mon May 1 14:05:03 2017 Repo-pkgs : 35 Repo-size : 13 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server/x86_64/os/addons/HighAvailability Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-HighAvailability.repo Repo-id : beaker-Server-NFV Repo-name : beaker-Server-NFV Repo-revision: 1493661908 Repo-updated : Mon May 1 14:05:09 2017 Repo-pkgs : 21 Repo-size : 235 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-NFV/x86_64/os Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-NFV.repo Repo-id : beaker-Server-NFV-debuginfo Repo-name : beaker-Server-NFV-debuginfo Repo-revision: 1493661909 Repo-updated : Mon May 1 14:05:09 2017 Repo-pkgs : 9 Repo-size : 1.2 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-NFV/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-NFV-debuginfo.repo Repo-id : beaker-Server-RT Repo-name : beaker-Server-RT Repo-revision: 1493661915 Repo-updated : Mon May 1 14:05:15 2017 Repo-pkgs : 15 Repo-size : 233 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-RT/x86_64/os Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-RT.repo Repo-id : beaker-Server-RT-debuginfo Repo-name : beaker-Server-RT-debuginfo Repo-revision: 1493661916 Repo-updated : Mon May 1 14:05:16 2017 Repo-pkgs : 6 Repo-size : 1.2 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-RT/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-RT-debuginfo.repo Repo-id : beaker-Server-ResilientStorage Repo-name : beaker-Server-ResilientStorage Repo-revision: 1493661928 Repo-updated : Mon May 1 14:05:28 2017 Repo-pkgs : 40 Repo-size : 15 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server/x86_64/os/addons/ResilientStorage Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-ResilientStorage.repo Repo-id : beaker-Server-SAP Repo-name : beaker-Server-SAP Repo-revision: 1493661942 Repo-updated : Mon May 1 14:05:42 2017 Repo-pkgs : 12 Repo-size : 1.6 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-SAP/x86_64/os Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-SAP.repo Repo-id : beaker-Server-SAP-debuginfo Repo-name : beaker-Server-SAP-debuginfo Repo-revision: 1493661944 Repo-updated : Mon May 1 14:05:44 2017 Repo-pkgs : 6 Repo-size : 5.3 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-SAP/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-SAP-debuginfo.repo Repo-id : beaker-Server-SAPHANA Repo-name : beaker-Server-SAPHANA Repo-revision: 1493661949 Repo-updated : Mon May 1 14:05:49 2017 Repo-pkgs : 4 Repo-size : 864 k Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-SAPHANA/x86_64/os Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-SAPHANA.repo Repo-id : beaker-Server-SAPHANA-debuginfo Repo-name : beaker-Server-SAPHANA-debuginfo Repo-revision: 1493661951 Repo-updated : Mon May 1 14:05:51 2017 Repo-pkgs : 3 Repo-size : 4.9 M Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-SAPHANA/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-SAPHANA-debuginfo.repo Repo-id : beaker-Server-debuginfo Repo-name : beaker-Server-debuginfo Repo-revision: 1493661883 Repo-updated : Mon May 1 14:04:43 2017 Repo-pkgs : 2,167 Repo-size : 11 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-debuginfo.repo Repo-id : beaker-Server-optional Repo-name : beaker-Server-optional Repo-revision: 1493662012 Repo-updated : Mon May 1 14:06:52 2017 Repo-pkgs : 4,406 Repo-size : 3.7 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-optional/x86_64/os Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-optional.repo Repo-id : beaker-Server-optional-debuginfo Repo-name : beaker-Server-optional-debuginfo Repo-revision: 1493662004 Repo-updated : Mon May 1 14:06:44 2017 Repo-pkgs : 226 Repo-size : 1.9 G Repo-baseurl : http://download.eng.bos.redhat.com/nightly/RHEL-7.4-20170501.n.0/compose/Server-optional/x86_64/debug/tree Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-Server-optional-debuginfo.repo Repo-id : beaker-harness Repo-name : beaker-harness Repo-revision: 1489364031 Repo-updated : Sun Mar 12 20:13:51 2017 Repo-pkgs : 214 Repo-size : 316 M Repo-baseurl : http://beaker.engineering.redhat.com/harness/RedHatEnterpriseLinux7/ Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-excluded: 247 Repo-filename: /etc/yum.repos.d/beaker-harness.repo Repo-id : beaker-tasks Repo-name : beaker-tasks Repo-revision: 1493707537 Repo-updated : Tue May 2 02:45:37 2017 Repo-pkgs : 24,123 Repo-size : 2.3 G Repo-baseurl : http://beaker.engineering.redhat.com/repos/3794529 Repo-expire : 21,600 second(s) (last: Tue May 9 02:20:35 2017) Filter : read-only:present Repo-filename: /etc/yum.repos.d/beaker-tasks.repo repolist: 36,417 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, 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-2017:2083 |