Description of problem: Recent cli of SAM 1.2 has an issue when displaying info about system's subscriptinos fetching by uuid. It types "None" as system's name. One would expect to see the real system's _registered_ name there. (--name for RHSM could vary from machine's hostname!) Version-Release number of selected component (if applicable): katello-cli-1.2.4-2h.el6_3.noarch katello-headpin-1.2.6-2h.el6_3.noarch How reproducible: always Steps to Reproduce: 1.import manifest with RHEL subscription 2.register a client and subscribe to that pool 3.make cli call of: system subscriptions --uuid <system-uuid> --org <org>` Actual results: Notice what is written on the header of the output: "Current Subscriptions for System [ None ]" Expected results: Current Subscriptions for System [ <systemRegisteredName> ] Additional info:
same here doing system unregister --uuid --- Successfully unregistered System [ None ] So please, whenever will be fixing/verifying the issue: please check the whole "system <command> --uuid" chain. thanks.
Changed the name option to use uuid if name is not present: [root@brazillions katello]# headpin --username=admin --password=admin system subscribe --uuid=48c658d9-1733-40d9-9a47-9e334d67460d --pool=ff8080813b43bd6f013b43c5c8040033 --org=ACME_Corporation Successfully attached subscription to System [ 48c658d9-1733-40d9-9a47-9e334d67460d ] d9-9a47-9e334d67460d --org=ACME_Corporation ------------------------------------------------------------------------------------------------------------------ Current Subscriptions for System [ 48c658d9-1733-40d9-9a47-9e334d67460d ] [root@brazillions katello]# headpin --username=admin --password=admin system unsubscribe --uuid=48c658d9-1733-40d9-9a47-9e334d67460d --org=ACME_Corporation --entitlement=ff8080813b43bd6f013b48fcb37a00b6 Successfully removed subscription from System [ 48c658d9-1733-40d9-9a47-9e334d67460d ] [root@brazillions katello]# headpin --username=admin --password=admin system unregister --org=ACME_Corporation --uuid=48c658d9-1733-40d9-9a47-9e334d67460d Successfully unregistered System [ 48c658d9-1733-40d9-9a47-9e334d67460d ] https://github.com/Katello/katello/pull/1142
https://github.com/Katello/katello/pull/1142
VERIFIED : # rpm -qa | grep katello katello-certs-tools-1.2.1-1h.el6_3.noarch katello-common-1.2.6-3h.el6_3.noarch katello-headpin-all-1.2.6-3h.el6_3.noarch katello-cli-common-1.2.4-3h.el6_3.noarch katello-selinux-1.2.1-1h.el6_3.noarch katello-cli-1.2.4-3h.el6_3.noarch katello-headpin-1.2.6-3h.el6_3.noarch katello-configure-1.2.3-1h.el6_3.noarch katello-candlepin-cert-key-pair-1.0-1.noarch katello-glue-candlepin-1.2.6-3h.el6_3.noarch # headpin -u admin -p admin system subscribe --uuid 2e05bdb6-ca43-4cbd-a0e7-31c0df9ef898 --pool 8a90c2993b6025a2013b602bd7810053 --org ACME_Corporation Successfully attached subscription to System [ 2e05bdb6-ca43-4cbd-a0e7-31c0df9ef898 ] # headpin -u admin -p admin system unsubscribe --uuid 2e05bdb6-ca43-4cbd-a0e7-31c0df9ef898 --entitlement 8a90c2993b6025a2013b603bc0ff007e --org ACME_Corporation Successfully removed subscription from System [ 2e05bdb6-ca43-4cbd-a0e7-31c0df9ef898 ] # headpin -u admin -p admin system unregister --org ACME_Corporation --uuid 2e05bdb6-ca43-4cbd-a0e7-31c0df9ef898 Successfully unregistered System [ 2e05bdb6-ca43-4cbd-a0e7-31c0df9ef898 ] # headpin -u admin -p admin system info --uuid 76e85c24-d296-42d6-bfb7-879c0dab284f --org ACME_Corporation -------------------------------------------------------------------------------- System Information [ 76e85c24-d296-42d6-bfb7-879c0dab284f ] -------------------------------------------------------------------------------- Name : ibm-hs22-02.lab.bos.redhat.com Ipv4 Address : None Uuid : 76e85c24-d296-42d6-bfb7-879c0dab284f Location : None Registered : 2012/12/03 05:21:25 Last updated : 2012/12/03 05:21:25 Description: Initial Registration Params Activation Keys: [ ] Service Level : Guests : [ ] Custom Info: [ ] # headpin -u admin -p admin system subscriptions --uuid 76e85c24-d296-42d6-bfb7-879c0dab284f --org ACME_Corporation No Subscriptions found for System [ 76e85c24-d296-42d6-bfb7-879c0dab284f ] in Org [ ACME_Corporation ]
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/RHSA-2013-0544.html