Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
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.
Fix in commit below:
commit c60b8ad4d4329616b8df6cce849f4313ec675d47
Author: Alex Wood <awood>
Date: Mon Jun 13 13:28:04 2016 -0400
Don't call static methods on a class that doesn't have them.
reproducer :
----------------------------------------
[root@dhcp35-45 home]# subscription-manager version
server type: Red Hat Subscription Management
subscription management server: 0.9.51.15-1
subscription management rules: 5.15.1
subscription-manager: 1.17.7-1.git.0.7a8354d.el7
python-rhsm: 1.17.2-1.git.5.5780140.el7
[root@dhcp35-45 home]# subscription-manager register --serverurl=subscription.rhn.stage.redhat.com:443/subscription --user=qa --proxy=auto-services.usersys.redhat.com:3128 --proxyuser=**** --proxypassword=***
This system is already registered. Use --force to override
[root@dhcp35-45 home]# subscription-manager register --serverurl=subscription.rhn.stage.redhat.com:443/subscription --user=qa --proxy=auto-services.usersys.redhat.com:3128 --proxyuser=redhat --proxypassword=redhat --force
Registering to: subscription.rhn.stage.redhat.com:443/subscription
Password:
unbound method endheaders() must be called with HTTPSConnection instance as first argument (got RhsmProxyHTTPSConnection instance instead)
Verification:
----------------------------------
[root@dhcp35-45 ~]# subscription-manager version
server type: Red Hat Subscription Management
subscription management server: 0.9.51.15-1
subscription management rules: 5.15.1
subscription-manager: 1.17.8-1.el7
python-rhsm: 1.17.4-1.el7
[root@dhcp35-45 ~]# subscription-manager register --serverurl=subscription.rhn.stage.redhat.com:443/subscription --user=qa --proxy=auto-services.usersys.redhat.com:3128 --proxyuser=*** --proxypassword=*** --force
The system with UUID f8639cfa-71c1-4f15-b0ff-78b3a7727714 has been unregistered
Registering to: subscription.rhn.stage.redhat.com:443/subscription
Password:
The system has been registered with ID: 20754727-b6ff-4ec2-b6cd-f19911b7a38b
Moveing bug to verified state
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://rhn.redhat.com/errata/RHSA-2016-2592.html
Description of problem: When trying to register (as well as any other sub-man module) using a valid proxy, a failure occurs. I suspect that this is the offending python-rhsm commit... 636d167c6f0c7a2266535892137391d227abbb62 Merge pull request #170 from candlepin/awood/socket-timeout Commit: 5780140650a59d45a03372a0390f92fd7c3301eb Allow users to set socket timeout. Remove the old method of setting a universal timeout (which was required due to limitations in Python versions that we don't support any more) and instead specify the timeout on a per-connection basis. Commit: 8cffbd466b6ab09ea92acf7c8ce127b59d5fa32f Correct misspellings and old Python except syntax. Version-Release number of selected component (if applicable): [root@jsefler-rhel7 ~]# subscription-manager version server type: This system is currently not registered. subscription management server: 0.9.51.19-1 subscription management rules: 5.15.1 subscription-manager: 1.17.7-1.git.0.7a8354d.el7 python-rhsm: 1.17.2-1.git.5.5780140.el7 How reproducible: Steps to Reproduce: [root@jsefler-rhel7 ~]# subscription-manager register --serverurl=subscription.rhsm.stage.redhat.com:443/subscription --user=qa --proxy=auto-services.usersys.redhat.com:3128 --proxyuser=redhat --proxypassword=redhat Registering to: subscription.rhsm.stage.redhat.com:443/subscription Password: unbound method endheaders() must be called with HTTPSConnection instance as first argument (got RhsmProxyHTTPSConnection instance instead) [root@jsefler-rhel7 ~]# echo $? 70 [root@jsefler-rhel7 ~]# tail -f /var/log/rhsm/rhsm.log 2016-06-13 09:28:04,732 [DEBUG] subscription-manager:5570 @ga_loader.py:89 - ga_loader GaImporterGtk3 2016-06-13 09:28:04,739 [DEBUG] subscription-manager:5570 @plugins.py:569 - loaded plugin modules: [<module 'container_content' from '/usr/share/rhsm-plugins/container_content.pyc'>, <module 'ostree_content' from '/usr/share/rhsm-plugins/ostree_content.pyc'>] 2016-06-13 09:28:04,739 [DEBUG] subscription-manager:5570 @plugins.py:570 - loaded plugins: {'container_content.ContainerContentPlugin': <container_content.ContainerContentPlugin object at 0x26ef810>, 'ostree_content.OstreeContentPlugin': <ostree_content.OstreeContentPlugin object at 0x26efdd0>} 2016-06-13 09:28:04,739 [DEBUG] subscription-manager:5570 @identity.py:131 - Loading consumer info from identity certificates. 2016-06-13 09:28:04,740 [DEBUG] subscription-manager:5570 @identity.py:146 - Reload of consumer identity cert /etc/pki/consumer/cert.pem raised an exception with msg: [Errno 2] No such file or directory: '/etc/pki/consumer/key.pem' 2016-06-13 09:28:04,780 [INFO] subscription-manager:5570 @managercli.py:384 - Client Versions: {'python-rhsm': '1.17.2-1.git.5.5780140.el7', 'subscription-manager': '1.17.7-1.git.0.7a8354d.el7'} 2016-06-13 09:28:04,780 [INFO] subscription-manager:5570 @connection.py:830 - Connection built: http_proxy=auto-services.usersys.redhat.com:3128 host=jsefler-candlepin.usersys.redhat.com port=8443 handler=/candlepin auth=identity_cert ca_dir=/etc/rhsm/ca/ verify=False 2016-06-13 09:28:04,781 [INFO] subscription-manager:5570 @connection.py:830 - Connection built: http_proxy=auto-services.usersys.redhat.com:3128 host=jsefler-candlepin.usersys.redhat.com port=8443 handler=/candlepin auth=none 2016-06-13 09:28:04,823 [INFO] subscription-manager:5570 @managercli.py:384 - Client Versions: {'python-rhsm': '1.17.2-1.git.5.5780140.el7', 'subscription-manager': '1.17.7-1.git.0.7a8354d.el7'} 2016-06-13 09:28:04,836 [INFO] subscription-manager:5570 @managercli.py:359 - Consumer Identity name=None uuid=None 2016-06-13 09:28:04,865 [INFO] subscription-manager:5570 @managercli.py:359 - Consumer Identity name=None uuid=None 2016-06-13 09:28:04,866 [INFO] subscription-manager:5570 @connection.py:830 - Connection built: http_proxy=auto-services.usersys.redhat.com:3128 host=jsefler-candlepin.usersys.redhat.com port=8443 handler=/candlepin auth=basic username=testuser1 2016-06-13 09:28:04,883 [DEBUG] subscription-manager:5570 @hwprobe.py:580 - cpu info: {'cpu.cpu(s)': 2, 'cpu.core(s)_per_socket': 1, 'cpu.thread(s)_per_core': 1, 'cpu.topology_source': 'kernel /sys cpu sibling lists', 'cpu.cpu_socket(s)': 2} 2016-06-13 09:28:04,967 [DEBUG] subscription-manager:5570 @hwprobe.py:798 - Running 'virt-what' 2016-06-13 09:28:04,993 [DEBUG] subscription-manager:5570 @hwprobe.py:802 - virt-what stdout: kvm 2016-06-13 09:28:04,993 [DEBUG] subscription-manager:5570 @hwprobe.py:803 - virt-what stderr: 2016-06-13 09:28:05,001 [INFO] subscription-manager:5570 @hwprobe.py:908 - collected virt facts: virt.is_guest=True, virt.host_type=kvm, virt.uuid=672A2A41-EFBD-463F-B8A0-543C292AAEAB 2016-06-13 09:28:05,003 [DEBUG] subscription-manager:5570 @connection.py:525 - Loaded CA certificates from /etc/rhsm/ca/: jsefler-candlepin.pem, jsefler-os-candlepin.pem, jsefler-candlepin7.pem, jsefler-candlepin6.pem, redhat-uep.pem, redhat-entitlement-authority.pem 2016-06-13 09:28:05,003 [DEBUG] subscription-manager:5570 @connection.py:558 - Using proxy: auto-services.usersys.redhat.com:3128 2016-06-13 09:28:05,003 [DEBUG] subscription-manager:5570 @connection.py:573 - Making request: GET https://jsefler-candlepin.usersys.redhat.com:8443/candlepin/ 2016-06-13 09:28:05,004 [ERROR] subscription-manager:5570 @managercli.py:174 - Error during registration: unbound method endheaders() must be called with HTTPSConnection instance as first argument (got RhsmProxyHTTPSConnection instance instead) 2016-06-13 09:28:05,005 [ERROR] subscription-manager:5570 @managercli.py:175 - unbound method endheaders() must be called with HTTPSConnection instance as first argument (got RhsmProxyHTTPSConnection instance instead) Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/subscription_manager/managercli.py", line 1119, in _do_command self.options.environment) File "/usr/lib/python2.7/site-packages/subscription_manager/managercli.py", line 1219, in _get_environment_id supports_environments = cp.supports_resource('environments') File "/usr/lib64/python2.7/site-packages/rhsm/connection.py", line 856, in supports_resource self._load_supported_resources() File "/usr/lib64/python2.7/site-packages/rhsm/connection.py", line 843, in _load_supported_resources resources_list = self.conn.request_get("/") File "/usr/lib64/python2.7/site-packages/rhsm/connection.py", line 694, in request_get return self._request("GET", method) File "/usr/lib64/python2.7/site-packages/rhsm/connection.py", line 584, in _request conn.request(request_type, handler, body=body, headers=headers) File "/usr/lib64/python2.7/httplib.py", line 979, in request self._send_request(method, url, body, headers) File "/usr/lib64/python2.7/httplib.py", line 1013, in _send_request self.endheaders(body) File "/usr/lib64/python2.7/site-packages/rhsm/connection.py", line 290, in endheaders HTTPSConnection.endheaders(self) TypeError: unbound method endheaders() must be called with HTTPSConnection instance as first argument (got RhsmProxyHTTPSConnection instance instead) Actual results: Expected results: Additional info: