Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be available on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 1412113 - subscription-manager attach --auto fails with "Runtime Error ERROR:"
Summary: subscription-manager attach --auto fails with "Runtime Error ERROR:"
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Candlepin
Classification: Community
Component: candlepin
Version: 2.0
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: ---
: 2.0
Assignee: vritant
QA Contact: Katello QA List
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-01-11 09:55 UTC by Rehana
Modified: 2017-02-20 18:07 UTC (History)
3 users (show)

Fixed In Version: candlepin-2.0.26-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-02-01 18:17:23 UTC


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github candlepin candlepin pull 1450 0 None closed 1412113: autobind fails when binding 2 pools together with same stackid 2020-08-10 11:59:13 UTC

Description Rehana 2017-01-11 09:55:25 UTC
Description of problem:
The issue was observed on a mapped guest machine during attach.

Version-Release number of selected component (if applicable):
subscription management server: 2.0.21-1
subscription management rules: 5.20
subscription-manager: 1.18.6-1.el6
python-rhsm: 1.18.6-1.el6


How reproducible:
always

Steps to Reproduce:
1.Register host and guest with the same Org against candlepin server
2.Make sure the virt-who service is running 
3.Set cpu socket on host machine (ex:say to 50)
Ex:
echo '{"cpu.cpu_socket(s)":"50"}' > /etc/rhsm/facts/sockets.facts
subscription-manager facts --update
4.Make sure a product is installed on the client (ex : 32060.pem)
5.Execute subscription-manager attach --auto or set the heal time and wait till the heal occurs on the guest

Actual results:
Only guest should be healed if not enough quantity is available to make the physical system compliant

Expected results:
attach fails on the client with 

# subscription-manager attach --auto

Runtime Error ERROR: current transaction is aborted, commands ignored until end of transaction block at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse:2,102


Additional info:
After disabling auto-attach on the host , the attach was successful on the guest machine

rhsm.log:
=======
2017-01-11 04:05:48,244 [ERROR] subscription-manager:1654:MainThread @managercli.py:177 - Unable to attach: Runtime Error ERROR: current transaction is aborted, commands ignored until end of transaction block at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse:2,102
2017-01-11 04:05:48,244 [ERROR] subscription-manager:1654:MainThread @managercli.py:178 - Runtime Error ERROR: current transaction is aborted, commands ignored until end of transaction block at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse:2,102
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/subscription_manager/managercli.py", line 1621, in _do_command
    service_level=self.options.service_level)
  File "/usr/lib/python2.6/site-packages/subscription_manager/managercli.py", line 200, in autosubscribe
    ents = cp.bind(consumer_uuid)  # new style
  File "/usr/lib64/python2.6/site-packages/rhsm/connection.py", line 1123, in bind
    return self.conn.request_post(method)
  File "/usr/lib64/python2.6/site-packages/rhsm/connection.py", line 626, in request_post
    return self._request("POST", method, params)
  File "/usr/lib64/python2.6/site-packages/rhsm/connection.py", line 534, in _request
    self.validateResponse(result, request_type, handler)
  File "/usr/lib64/python2.6/site-packages/rhsm/connection.py", line 587, in validateResponse
    raise RestlibException(response['status'], error_msg, response.get('headers'))
RestlibException: Runtime Error ERROR: current transaction is aborted, commands ignored until end of transaction block at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse:2,102

Comment 1 Rehana 2017-01-11 09:58:47 UTC
please read as ;

Actual results:
attach fails on the client with 

# subscription-manager attach --auto

Runtime Error ERROR: current transaction is aborted, commands ignored until end of transaction block at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse:2,102

Expected results:

Only guest should be healed if not enough quantity is available to make the physical system compliant


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