Bug 1019227
Description
qianzhan
2013-10-15 10:33:59 UTC
Created attachment 812417 [details]
'disable auto-attach from SAM web UI.png'
Created attachment 812418 [details]
'disable auto-attach in CLI and the GUI does not work.png'
This sounds like something isn't sending a request correctly. I cannot reproduce any problems with the subscription-manager client. I think modifying it with other tools while the gui is running (preferences window open) gets the gui into a stale state, but nothing will actually be wrong. It sounds like you're leaving the preferences window open, and expecting it to update, which never happens. There may be a sam bug, but I can't really tell what the problem is from the description. Feel free to re-open if this is still reproducible and is a bug, not just a stale preferences dialog (not closed and re-opened). This bug still exit in RHEL-7.0-20140207.0, so I reopened it, please see following details. 1, Register to SAM, and run "# subscription-manager auto-attach --disable" 2, Run "# subscription-manager-gui", the auto-attach check box in System Preference window still selected. It should be a SAM bug, because when registered to Stage Candlepin, rerun above steps, the result is correct, please compare the logs Run command "# subscription-manager auto-attach --disable" after registered to Stage Candlepin 2014-02-08 04:02:24,610 [DEBUG] subscription-manager @plugins.py:519 - loaded plugin modules: [] 2014-02-08 04:02:24,610 [DEBUG] subscription-manager @plugins.py:520 - loaded plugins: {} 2014-02-08 04:02:24,630 [DEBUG] subscription-manager @identity.py:130 - Loading consumer info from identity certificates. 2014-02-08 04:02:24,635 [DEBUG] subscription-manager @profile.py:97 - Loading current RPM profile. 2014-02-08 04:02:24,729 [INFO] subscription-manager @managercli.py:288 - Client Versions: {'python-rhsm': '1.10.12-1.el7', 'subscription-manager': '1.10.13-1.el7'} 2014-02-08 04:02:24,730 [INFO] subscription-manager @connection.py:663 - Using certificate authentication: key = /etc/pki/consumer/key.pem, cert = /etc/pki/consumer/cert.pem, ca = /etc/rhsm/ca/, insecure = False 2014-02-08 04:02:24,730 [INFO] subscription-manager @connection.py:674 - Connection Built: host: subscription.rhn.stage.redhat.com, port: 443, handler: /subscription 2014-02-08 04:02:24,730 [INFO] subscription-manager @connection.py:670 - Using no auth 2014-02-08 04:02:24,730 [INFO] subscription-manager @connection.py:674 - Connection Built: host: subscription.rhn.stage.redhat.com, port: 443, handler: /subscription 2014-02-08 04:02:24,741 [DEBUG] subscription-manager @connection.py:418 - Loaded CA certificates from /etc/rhsm/ca/: candlepin-stage.pem, redhat-uep.pem, candlepin-local.pem 2014-02-08 04:02:24,741 [DEBUG] subscription-manager @connection.py:450 - Making request: GET /subscription/ 2014-02-08 04:02:25,798 [DEBUG] subscription-manager @connection.py:473 - Response: status=200 2014-02-08 04:02:25,799 [DEBUG] subscription-manager @connection.py:690 - Server supports the following resources: 2014-02-08 04:02:25,799 [DEBUG] subscription-manager @connection.py:691 - {'owners': '/owners', 'jobs': '/jobs', 'users': '/users', 'consumers': '/consumers', 'subscriptions': '/subscriptions', 'distributor_versions': '/distributor_versions', 'hypervisors': '/hypervisors', 'products': '/products', 'entitlements': '/entitlements', 'pools': '/pools'} -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 2014-02-08 04:02:25,800 [INFO] subscription-manager @managercli.py:299 - Server Versions: {'candlepin': 'Unknown', 'server-type': 'Red Hat Subscription Management'} 2014-02-08 04:02:25,801 [DEBUG] subscription-manager @connection.py:418 - Loaded CA certificates from /etc/rhsm/ca/: candlepin-stage.pem, redhat-uep.pem, candlepin-local.pem 2014-02-08 04:02:25,802 [DEBUG] subscription-manager @connection.py:450 - Making request: PUT /subscription/consumers/599e263a-3aee-45f5-8e07-7004d935e5b9 2014-02-08 04:02:27,355 [DEBUG] subscription-manager @connection.py:473 - Response: status=204 Run command "# subscription-manager auto-attach --disable" after registered to SAM 2014-02-08 03:32:21,731 [DEBUG] subscription-manager @plugins.py:519 - loaded plugin modules: [] 2014-02-08 03:32:21,731 [DEBUG] subscription-manager @plugins.py:520 - loaded plugins: {} 2014-02-08 03:32:21,751 [DEBUG] subscription-manager @identity.py:130 - Loading consumer info from identity certificates. 2014-02-08 03:32:21,756 [DEBUG] subscription-manager @profile.py:97 - Loading current RPM profile. 2014-02-08 03:32:21,846 [INFO] subscription-manager @managercli.py:288 - Client Versions: {'python-rhsm': '1.10.12-1.el7', 'subscription-manager': '1.10.13-1.el7'} 2014-02-08 03:32:21,846 [INFO] subscription-manager @connection.py:663 - Using certificate authentication: key = /etc/pki/consumer/key.pem, cert = /etc/pki/consumer/cert.pem, ca = /etc/rhsm/ca/, insecure = False 2014-02-08 03:32:21,846 [INFO] subscription-manager @connection.py:674 - Connection Built: host: samserv.redhat.com, port: 443, handler: /sam/api 2014-02-08 03:32:21,847 [INFO] subscription-manager @connection.py:670 - Using no auth 2014-02-08 03:32:21,847 [INFO] subscription-manager @connection.py:674 - Connection Built: host: samserv.redhat.com, port: 443, handler: /sam/api 2014-02-08 03:32:21,858 [DEBUG] subscription-manager @connection.py:418 - Loaded CA certificates from /etc/rhsm/ca/: candlepin-stage.pem, redhat-uep.pem, candlepin-local.pem 2014-02-08 03:32:21,858 [DEBUG] subscription-manager @connection.py:450 - Making request: GET /sam/api/ 2014-02-08 03:32:21,908 [DEBUG] subscription-manager @connection.py:473 - Response: status=200 2014-02-08 03:32:21,909 [DEBUG] subscription-manager @connection.py:690 - Server supports the following resources: 2014-02-08 03:32:21,909 [DEBUG] subscription-manager @connection.py:691 - {'status': '/api/status/', 'organizations': '/api/organizations/', 'roles': '/api/roles/', 'sync_plans': '/api/sync_plans/', 'users': '/api/users/', 'distributors': '/api/distributors/', 'providers': '/api/providers/', 'entitlements': '/api/entitlements/', 'content_views': '/api/content_views/', 'system_groups': '/api/system_groups/', 'products': '/api/products/', 'systems': '/api/systems/', 'activation_keys': '/api/activation_keys/', 'content_view_definitions': '/api/content_view_definitions/', 'consumers': '/api/consumers/'} -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 2014-02-08 03:32:21,911 [DEBUG] subscription-manager @connection.py:418 - Loaded CA certificates from /etc/rhsm/ca/: candlepin-stage.pem, redhat-uep.pem, candlepin-local.pem 2014-02-08 03:32:21,911 [DEBUG] subscription-manager @connection.py:450 - Making request: GET /sam/api/status 2014-02-08 03:32:21,940 [DEBUG] subscription-manager @connection.py:473 - Response: status=200 -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 2014-02-08 03:32:21,941 [INFO] subscription-manager @managercli.py:299 - Server Versions: {'candlepin': '1.4.3.23-1.el6sam_splice-Headpin', 'server-type': 'Red Hat Subscription Management'} 2014-02-08 03:32:21,942 [DEBUG] subscription-manager @connection.py:418 - Loaded CA certificates from /etc/rhsm/ca/: candlepin-stage.pem, redhat-uep.pem, candlepin-local.pem 2014-02-08 03:32:21,943 [DEBUG] subscription-manager @connection.py:450 - Making request: PUT /sam/api/consumers/d4e0044e-7c32-4fc0-bebc-c2a3f02e064e 2014-02-08 03:32:22,481 [DEBUG] subscription-manager @connection.py:473 - Response: status=200 The setting of this parameter works correctly when the client is run against Candlepin. It is only when SAM [1.3 or 1.4] is involved that the setting is ineffective. Pushing this to katello team for resolution. Since this issue was entered in Red Hat Bugzilla, the release flag has been set to ? to ensure that it is properly evaluated for this release. Created redmine issue http://projects.theforeman.org/issues/6578 from this bug *** This bug has been marked as a duplicate of bug 1113879 *** I don't think this bug is duplicate of 1113879, because this bug aims at auto-attach function by CLI, while 1113879 by Web UI. *** This bug has been marked as a duplicate of bug 1103774 *** Bug 1103774 should be a duplicate of this bug, because this bug is filed earlier than 1103774 by more than 8 months. *** Bug 1103774 has been marked as a duplicate of this bug. *** Connecting redmine issue http://projects.theforeman.org/issues/6012 from this bug Verifying Version: subscription-manager: 1.13.22-1.el7 python-rhsm: 1.13.10-1.el7 Verification: 1. Prepare Satellite-6.1.0-RHEL-7-20150225.0 and RHEL-7.1-20150219.1 2. Register the rhel to satellite: [root@dhcp-128-77 ~]# rpm -ivh katello-ca-consumer-intel-s3e3432-01.rhts.eng.bos.redhat.com-1.0-1.noarch.rpm Preparing... ################################# [100%] Updating / installing... 1:katello-ca-consumer-intel-s3e3432################################# [100%] [root@dhcp-128-77 ~]# subscription-manager register Username: admin Password: The system has been registered with ID: c8c33775-6698-4a8f-9b05-0dd9a25e2932 3. Enable auto-attach in satellite web UI: see attachment "enable auto-attach in satellite.png" 4. Enable auto-attach in subscription-manager-gui of RHEL7.1: see attachment "enable auto-attach in subscripiton-manager-gui.png" 5. Disable auto-attach in CLI of RHEL7.1 [root@dhcp-128-77 ~]# subscription-manager auto-attach --disable Auto-attach preference: disabled 6. Lanch subscription-manager-gui and open Preference window: The auto-attach preference is still checked, see attachment "The auto-attach preference is still checked after disabling the it in CLI.png" 7. Show the current auto-attach preference in CLI: [root@dhcp-128-77 ~]# subscription-manager auto-attach --show Auto-attach preference: enabled As per step 6 and step 7, disabling auto-attach in subscription-manager CLI, can not control the auto-attach preference in subscription-manager-gui, can not control the auto-attach preference in subscription-manager CLI neither. Moving the bug from ON_QA to ASSIGNED. Created attachment 996407 [details]
"enable auto-attach in satellite.png"
Created attachment 996408 [details]
"enable auto-attach in subscripiton-manager-gui.png"
Created attachment 996409 [details]
The auto-attach preference is still checked after disabling the it in CLI.png
I have tried this using a RHEL7.1 machine and the latest compose (Satellite-6.1.0-RHEL-7-20150310.0), and I have not been able to recreate this bug. I am able to enable and disable it from CLI, and in sub-man-gui those changes are reflected. Verifying Version: subscription-manager: 1.13.22-1.el7 python-rhsm: 1.13.10-1.el7 Verification: 1. Prepare Satellite-6.1.0-RHEL-7-20150310.0 and RHEL-7.1-20150219.1 2. Register the rhel to satellite: [root@dhcp-128-77 ~]# subscription-manager register Username: admin Password: The system has been registered with ID: 4913a150-640a-47f2-9439-7ffd5887cd36 [root@dhcp-128-77 ~]# 3. Enable auto-attach in satellite web UI: see attachment "enable auto-attach in satellite 2.png" 4. Enable auto-attach in subscription-manager-gui of RHEL7.1: see attachment "enable auto-attach in subscripiton-manager-gui 2.png" 5. Disable auto-attach in CLI of RHEL7.1 [root@dhcp-128-77 ~]# subscription-manager auto-attach --disable Auto-attach preference: disabled 6. Lanch subscription-manager-gui and open Preference window: The auto-attach preference is unchecked, see attachment "The auto-attach preference is unchecked after disabling the it in CLI.png" 7. Show the current auto-attach preference in CLI: [root@dhcp-128-77 ~]# subscription-manager auto-attach --show Auto-attach preference: disabled As per step 6 and step 7, Moving the bug from ON_QA to VERIFIED. Created attachment 1000259 [details]
enable auto-attach in satellite 2.png
Created attachment 1000260 [details]
enable auto-attach in subscripiton-manager-gui 2.png
Created attachment 1000261 [details]
The auto-attach preference is unchecked after disabling the it in CLI.png
This bug is slated to be released with Satellite 6.1. 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/RHSA-2015:1592 |