Bug 841289 - inconsistency on system info: Katello-Candlepin: unresponsive "Systems" page
Summary: inconsistency on system info: Katello-Candlepin: unresponsive "Systems" page
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: WebUI
Version: 6.0.1
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: Unspecified
Assignee: Brad Buckingham
QA Contact: Garik Khachikyan
URL:
Whiteboard:
: 841244 (view as bug list)
Depends On: 841244
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-07-18 15:03 UTC by Garik Khachikyan
Modified: 2015-01-04 21:59 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
System Engine performs a database rollback on the transaction if an error occurs. However, this did not affect System Engine sub-component records, which created inconsistencies. This fix adds a callback to perform a clean-up of System Engine sub-components. This keeps the databases for System Engine and its sub-components consistent.
Clone Of: 841244
Environment:
Last Closed: 2012-12-04 19:47:26 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2012:1543 0 normal SHIPPED_LIVE Important: CloudForms System Engine 1.1 update 2012-12-05 00:39:57 UTC

Description Garik Khachikyan 2012-07-18 15:03:03 UTC
+++ This bug was initially created as a clone of Bug #841244 +++

Created attachment 598892 [details]
loading ...

Description of problem:
Having error on RHSM registration with activation key brings UI of "Systems" page to onloading state forever. Further usage of Systems through UI becomes impossible. CLI also has no way to remove conflicting data info (seems manually through DB only~)

Version-Release number of selected component (if applicable):
pulp-common-1.1.11-1.el6.noarch
katello-certs-tools-1.1.6-1.git.572.1606589.el6.noarch
qpid-cpp-server-ssl-0.14-14.el6_2.x86_64
katello-glue-pulp-0.2.45-1.git.20.0d974f6.el6.noarch
katello-0.2.45-1.git.20.0d974f6.el6.noarch
katello-configure-0.2.30-1.git.16.0e273d4.el6.noarch
candlepin-tomcat6-0.5.32-1.el6.noarch
katello-qpid-client-key-pair-1.0-1.noarch
katello-cli-common-0.2.43-1.git.0.07c77a6.el6.noarch
katello-cli-0.2.43-1.git.0.07c77a6.el6.noarch
m2crypto-0.21.1.pulp-7.el6.x86_64
mod_wsgi-3.3-3.pulp.el6.x86_64
qpid-cpp-client-ssl-0.14-14.el6_2.x86_64
katello-glue-foreman-0.2.45-1.git.20.0d974f6.el6.noarch
katello-selinux-0.2.6-1.git.9.1606589.el6.noarch
katello-qpid-broker-key-pair-1.0-1.noarch
katello-agent-1.0.4-1.git.11.1606589.el6.noarch
python-qpid-0.14-7.el6_2.noarch
qpid-cpp-server-0.14-14.el6_2.x86_64
katello-glue-candlepin-0.2.45-1.git.20.0d974f6.el6.noarch
pulp-1.1.11-1.el6.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
python-oauth2-1.5.170-2.pulp.el6.noarch
candlepin-0.5.32-1.el6.noarch
qpid-cpp-client-0.14-14.el6_2.x86_64
katello-common-0.2.45-1.git.20.0d974f6.el6.noarch
katello-repos-0.2.5-1.el6.noarch
pulp-selinux-server-1.1.11-1.el6.noarch

How reproducible:
always

Steps to Reproduce:
1.prepare System Group having usage limit of 2 systems
2.create AK having no usage limit
3.assign system group to that AK.
4. register 2 systems using that activation key
5. try the third one: 
error on rhsm output:
"Validation failed: You cannot have more than 2 system(s) associated with system group 'cloud'"
Refer to the Katello UI and visit Systems-> All page.

Actual results:
Nothing but the loading progress icon is shown (attached is the pict.)

Expected results:
Katello & Candlepin both should handle the rollback of failure(s) correctly.

Additional info:

--- Additional comment from gkhachik on 2012-07-18 09:52:21 EDT ---

Created attachment 598893 [details]
katello logs

Comment 1 Brad Buckingham 2012-09-04 20:30:35 UTC
katello github pull request:
https://github.com/Katello/katello/pull/543

katello github commits:
https://github.com/Katello/katello/commit/b33806abe7cdebb80fe71a13cff13e4f2376e6ad

When a client/system/consumer registers with katello, the
creation of the system in katello is handled using a single db
transaction.  In supporting this, it will assign the system
to the activation key, environment, subscriptions, system groups...etc.
In addition, it will create the appropriate records in pulp,
candlepin and elasticsearch.

If an error occurs when creating the katello records (e.g.
system group max members validation error), a DB rollback will
be performed on the transaction.  While this cleans up the
katello DB, it does not affect pulp, candlepin and elasticsearch.

In order to address this bug, we'll also rollback changes made
to elasticsearch, pulp and candlepin when an error occurs.

Comment 2 Mike McCune 2012-09-12 19:21:21 UTC
*** Bug 841244 has been marked as a duplicate of this bug. ***

Comment 4 Garik Khachikyan 2012-09-20 06:52:44 UTC
# VERIFIED

error has been gone.

checked on:
---
candlepin-selinux-0.7.8-1.el6cf.noarch
katello-glue-candlepin-1.1.12-7.el6cf.noarch
python-qpid-0.7.946106-1.el6.noarch
qpid-cpp-client-0.14-16.el6.x86_64
qpid-cpp-server-0.14-16.el6.x86_64
qpid-cpp-server-ssl-0.14-16.el6.x86_64
katello-agent-1.1.2-1.el6cf.noarch
mod_wsgi-3.3-3.pulp.el6.x86_64
katello-certs-tools-1.1.8-1.el6cf.noarch
katello-configure-1.1.9-3.el6cf.noarch
pulp-1.1.12-1.el6cf.noarch
candlepin-0.7.8-1.el6cf.noarch
katello-selinux-1.1.1-1.el6cf.noarch
katello-glue-pulp-1.1.12-7.el6cf.noarch
candlepin-tomcat6-0.7.8-1.el6cf.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
katello-qpid-client-key-pair-1.0-1.noarch
candlepin-cert-consumer-smqe-ws15.lab.eng.brq.redhat.com-1.0-1.noarch
python-isodate-0.4.4-4.pulp.el6.noarch
pulp-common-1.1.12-1.el6cf.noarch
pulp-selinux-server-1.1.12-1.el6cf.noarch
qpid-cpp-client-ssl-0.14-16.el6.x86_64
m2crypto-0.21.1.pulp-7.el6.x86_64
katello-common-1.1.12-7.el6cf.noarch
python-oauth2-1.5.170-2.pulp.el6.noarch
katello-1.1.12-7.el6cf.noarch
katello-qpid-broker-key-pair-1.0-1.noarch
katello-cli-common-1.1.8-4.el6cf.noarch
katello-cli-1.1.8-4.el6cf.noarch
---

Comment 6 errata-xmlrpc 2012-12-04 19:47:26 UTC
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-2012-1543.html

Comment 7 Mike McCune 2013-08-16 18:02:39 UTC
getting rid of 6.0.0 version since that doesn't exist


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