Bug #7322
closedUnable to unregister with subscription-manager < 0.96 (RHEL 6.1, RHEL 5.7)
Description
Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1136056
Description of problem:
System is unable to unregiter via older subcription-manager (probably < 0.96)
On RHEL 5.7:- subscription-manager unregister
Traceback (most recent call last):
File "/usr/lib64/python2.4/logging/handlers.py", line 71, in emit
if self.shouldRollover(record):
File "/usr/lib64/python2.4/logging/handlers.py", line 149, in shouldRollover
msg = "%s\n" % self.format(record)
File "/usr/lib64/python2.4/logging/__init__.py", line 617, in format
return fmt.format(record)
File "/usr/lib64/python2.4/logging/__init__.py", line 405, in format
record.message = record.getMessage()
File "/usr/lib64/python2.4/logging/__init__.py", line 272, in getMessage
msg = str(self.msg)
AttributeError: RemoteServerException instance has no attribute 'args'
Remote server error. Please check the connection details, or see /var/log/rhsm/rhsm.log for more information.
On RHEL 6.1 the output was different, but the issue on the server was the same.
In server production.log
Error occurred while parsing request parameters.
Contents:
NoMethodError (undefined method `each' for nil:NilClass):
lib/middleware/catch_json_parse_errors.rb:9:in `call'
From the investigation it seems that rhsm sends some whitespaces instead of empty body which causes parsing error.
Version-Release number of selected component (if applicable):
Satellite 6 6.0.4
Client: RHEL 5.7
subscription-manager-0.95.5.21-1.el5
How reproducible:
Always
Steps to Reproduce:
1. cold install 5.7 or 6.1
2. install bootstrap RPM from satellite server (http://sat6.example.com/pub/katello-ca-consumer-sat6.example.com-1.0-1.noarch.rpm)
3. subscription-manager register
4. subscription-manager unregister
Actual results:
Traceback (see above)
Expected results:
Information that the system was unregistered
Additional info: