Bug 1001169 - subscription-manager CLI attach --auto will not persist the unsetting of the service-level
subscription-manager CLI attach --auto will not persist the unsetting of the ...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: subscription-manager (Show other bugs)
6.5
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: Carter Kozak
John Sefler
:
Depends On:
Blocks: rhsm-rhel65
  Show dependency treegraph
 
Reported: 2013-08-26 11:16 EDT by John Sefler
Modified: 2014-09-14 20:09 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
No description necessary.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-11-21 16:28:05 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description John Sefler 2013-08-26 11:16:30 EDT
Description of problem:
When calling subscription-manager attach --auto --service-level="", the service level should be unset before attempting the auto attachment.  This is not happening.


Version-Release number of selected component (if applicable):
[root@jsefler-6 ~]# subscription-manager version
server type: Red Hat Subscription Management
subscription management server: Unknown
subscription-manager: 1.9.3-1.el6
python-rhsm: 1.9.3-1.el6


How reproducible:


Steps to Reproduce:
[root@jsefler-6 ~]# subscription-manager register --serverurl=https://subscription.rhn.stage.redhat.com:443/subscription --username=qa@redhat.com
Password: 
The system has been registered with ID: 501dd142-4952-4f26-b9cd-aac1572948e5 
[root@jsefler-6 ~]# subscription-manager service-level --list
+-------------------------------------------+
               Available Service Levels
+-------------------------------------------+
None
Premium
Self-support
Standard
[root@jsefler-6 ~]# subscription-manager service-level --set=Standard
Service level set to: Standard
[root@jsefler-6 ~]# subscription-manager attach --auto --servicelevel=""
Installed Product Current Status:
Product Name: Red Hat Enterprise Linux Server
Status:       Not Subscribed

[root@jsefler-6 ~]# subscription-manager service-level
Current service level: Standard                     <============== WRONG
[root@jsefler-6 ~]# subscription-manager service-level --set=""
Service level preference has been unset
[root@jsefler-6 ~]# subscription-manager service-level
Service level preference not set                    <============== CORRECT
Comment 1 Carter Kozak 2013-08-29 14:46:28 EDT
commit 4c00469a5992a6e91df0f344b4559cee60309281
Author: ckozak <ckozak@redhat.com>
Date:   Mon Aug 26 11:51:37 2013 -0400

    1001169: fix pythonic empty string identity problems
Comment 3 John Sefler 2013-09-15 13:54:24 EDT
Verifying Version...
[root@jsefler-6 ~]# rpm -q subscription-manager python-rhsm
subscription-manager-1.9.6-1.el6.x86_64
python-rhsm-1.9.6-1.el6.x86_64

[root@jsefler-6 ~]# subscription-manager register --serverurl=https://subscription.rhn.stage.redhat.com:443/subscription --username=qa@redhat.com
Password: 
The system has been registered with ID: 28fecaea-e28f-44d8-b58f-3cea9e9708ad 
[root@jsefler-6 ~]# subscription-manager service-level --list
+-------------------------------------------+
               Available Service Levels
+-------------------------------------------+
None
PREMIUM
Self-Support
Standard
[root@jsefler-6 ~]# subscription-manager service-level --set=Standard
Service level set to: Standard
[root@jsefler-6 ~]# subscription-manager attach --auto --servicelevel=""
Service level set to:               <=========  VERIFIED: servicelevel was unset
Installed Product Current Status:
Product Name: Red Hat Enterprise Linux Server
Status:       Subscribed

[root@jsefler-6 ~]# subscription-manager service-level
Service level preference not set    <=========  VERIFIED: servicelevel was unset
[root@jsefler-6 ~]# subscription-manager list --consumed
+-------------------------------------------+
   Consumed Subscriptions
+-------------------------------------------+
Subscription Name: Red Hat Enterprise Linux Server, Premium (8 sockets) (Up to 4
                   guests)
Provides:          Red Hat Software Collections Beta (for RHEL Server)
                   Red Hat Enterprise Linux Server
                   Red Hat Beta
SKU:               RH0103708
Contract:          10014848
Account:           477931
Serial:            4888036419779628206
Pool ID:           8a99f9843c1bef8f013c1f81284004ae
Active:            True
Quantity Used:     1
Service Level:     Premium       <=========  VERIFIED: any auto attached 
Service Type:      L1-L3                     servicelevel is expected when unset
Status Details:    
Starts:            12/31/2012
Ends:              12/31/2013

[root@jsefler-6 ~]# 


Moving to VERIFIED
Comment 4 errata-xmlrpc 2013-11-21 16:28:05 EST
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.

http://rhn.redhat.com/errata/RHBA-2013-1659.html

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