Bug 853857 - After deletion of consumer and restart of rhsmcertd service,consumer folder is not moved to consumer.old
After deletion of consumer and restart of rhsmcertd service,consumer folder i...
Status: CLOSED DUPLICATE of bug 852706
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: subscription-manager (Show other bugs)
5.9
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: candlepin-bugs
Entitlement Bugs
:
Depends On:
Blocks: 771748
  Show dependency treegraph
 
Reported: 2012-09-03 03:25 EDT by Shwetha Kallesh
Modified: 2012-09-14 11:32 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-09-14 11:32:41 EDT
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 Shwetha Kallesh 2012-09-03 03:25:13 EDT
Description of problem:
After deletion of consumer and restart of rhsmcertd service,consumer folder is not moved to consumer.old 

Version-Release number of selected component (if applicable):
[root@dhcp201-115 pki]# rpm -qa | grep subscription-manager
subscription-manager-1.0.17-1.el5
subscription-manager-firstboot-1.0.17-1.el5
subscription-manager-debuginfo-1.0.17-1.el5
subscription-manager-gui-1.0.17-1.el5
subscription-manager-migration-1.0.17-1.el5


How reproducible:
Steps to Reproduce:
1.[root@dhcp201-115 pki]# subscription-manager register --org=admin
Username: admin
Password: 
The system has been registered with id: 9d26b78c-cc71-4fba-a584-c9969db32b3f 
[root@dhcp201-115 pki]# curl --stderr /dev/null --insecure --user admin:admin --request DELETE https://10.65.201.132:8443/candlepin/consumers/9d26b78c-cc71-4fba-a584-c9969db32b3f
[root@dhcp201-115 pki]# service rhsmcertd restart
Stopping rhsmcertd...                                      [FAILED]
Starting rhsmcertd...                                      [  OK  ]
[root@dhcp201-115 pki]# ll
total 68
drwx------ 3 root root 4096 Apr 23 19:53 CA
drwxr-xr-x 2 root root 4096 Sep  3 12:40 consumer
drwxr-xr-x 2 root root 4096 Sep  3 12:40 entitlement
drwxr-xr-x 2 root root 4096 Jun 20 12:34 nssdb
drwxr-xr-x 2 root root 4096 Sep  2 17:03 product


2.
3.
  
Actual results:
the consumer folder exists

Expected results:
Should be moved to consumer.old

Additional info:
Comment 1 spandey 2012-09-04 07:01:19 EDT
subscription-manager-migration-1.0.17-1.el5
subscription-manager-1.0.17-1.el5
subscription-manager-gui-1.0.17-1.el5
subscription-manager-firstboot-1.0.17-1.el5
subscription-manager-migration-data-1.11.2.4-1.el5


Force registration is not working after deleted consumer from candlepin server 

[root@dhcp193-75 pki]# subscription-manager register --serverurl 10.65.193.76:8443/candlepin --u testuser1 --password password --org admin --force
Consumer 20f402d6-c601-4fc3-be7d-608cca619edd has been deleted


rhsm.log output 

2012-09-04 16:29:55,962 [INFO]  @connection.py:508 - Using no auth
2012-09-04 16:29:55,963 [INFO]  @connection.py:511 - Connection Built: host: 10.65.193.76, port: 8443, handler: /candlepin
2012-09-04 16:29:55,963 [DEBUG]  @connection.py:323 - Loading CA PEM certificates from: /etc/rhsm/ca/
2012-09-04 16:29:55,964 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/10.pem'
2012-09-04 16:29:55,964 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/candlepin-ca.pem'
2012-09-04 16:29:55,964 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/candlepin-stage.pem'
2012-09-04 16:29:55,965 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/candlepin.pem'
2012-09-04 16:29:55,965 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/redhat-uep.pem'
2012-09-04 16:29:55,966 [DEBUG]  @connection.py:344 - Making request: GET /candlepin/status/
2012-09-04 16:29:55,994 [DEBUG]  @connection.py:357 - Response status: 200
2012-09-04 16:29:55,996 [DEBUG]  @profile.py:95 - Loading current RPM profile.
2012-09-04 16:29:56,121 [INFO]  @managercli.py:252 - Client Versions: {'python-rhsm': '1.0.7-1.el5', 'subscription-manager': '1.0.17-1.el5'} 
2012-09-04 16:29:56,122 [INFO]  @connection.py:498 - Using certificate authentication: key = /etc/pki/consumer/key.pem, cert = /etc/pki/consumer/cert.pem, ca = /etc/rhsm/ca/, insecure = False
2012-09-04 16:29:56,122 [INFO]  @connection.py:511 - Connection Built: host: 10.65.193.76, port: 8443, handler: /candlepin
2012-09-04 16:29:56,124 [DEBUG]  @connection.py:323 - Loading CA PEM certificates from: /etc/rhsm/ca/
2012-09-04 16:29:56,124 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/10.pem'
2012-09-04 16:29:56,125 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/candlepin-ca.pem'
2012-09-04 16:29:56,125 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/candlepin-stage.pem'
2012-09-04 16:29:56,125 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/candlepin.pem'
2012-09-04 16:29:56,125 [DEBUG]  @connection.py:305 - Loading CA certificate: '/etc/rhsm/ca/redhat-uep.pem'
2012-09-04 16:29:56,126 [DEBUG]  @connection.py:344 - Making request: GET /candlepin/
2012-09-04 16:29:56,153 [DEBUG]  @connection.py:357 - Response status: 410
2012-09-04 16:29:56,154 [INFO]  @utils.py:320 - Server Versions: Error: consumer has been deleted, unable to check server version
2012-09-04 16:29:56,154 [INFO]  @utils.py:321 - Consumer 20f402d6-c601-4fc3-be7d-608cca619edd has been deleted
2012-09-04 16:29:56,154 [ERROR]  @managercli.py:114 - exception caught in subscription-manager
2012-09-04 16:29:56,154 [ERROR]  @managercli.py:115 - Consumer 20f402d6-c601-4fc3-be7d-608cca619edd has been deleted
Traceback (most recent call last):
  File "/usr/sbin/subscription-manager", line 78, in ?
    sys.exit(abs(main() or 0))
  File "/usr/sbin/subscription-manager", line 69, in main
    return managercli.ManagerCLI().main()
  File "/usr/share/rhsm/subscription_manager/cli.py", line 140, in main
    return cmd.main()
  File "/usr/share/rhsm/subscription_manager/managercli.py", line 415, in main
    self.log_server_version()
  File "/usr/share/rhsm/subscription_manager/managercli.py", line 266, in log_server_version
    self.server_versions = get_server_versions(self.cp)
  File "/usr/share/rhsm/subscription_manager/utils.py", line 314, in get_server_versions
    if cp.supports_resource("status"):
  File "/usr/lib64/python2.4/site-packages/rhsm/connection.py", line 538, in supports_resource
    self._load_supported_resources()
  File "/usr/lib64/python2.4/site-packages/rhsm/connection.py", line 525, in _load_supported_resources
    resources_list = self.conn.request_get("/")
  File "/usr/lib64/python2.4/site-packages/rhsm/connection.py", line 400, in request_get
    return self._request("GET", method)
  File "/usr/lib64/python2.4/site-packages/rhsm/connection.py", line 362, in _request
    self.validateResponse(result)
  File "/usr/lib64/python2.4/site-packages/rhsm/connection.py", line 384, in validateResponse
    parsed['displayMessage'], parsed['deletedId'])
GoneException: Consumer 20f402d6-c601-4fc3-be7d-608cca619edd has been deleted


Expected Result : command should register client to candlepin
Comment 2 William Poteat 2012-09-14 11:32:41 EDT

*** This bug has been marked as a duplicate of bug 852706 ***

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