Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Created attachment 1191472[details]
foreman-debug of candlepin ConstraintViolationException
Description of problem:
When i created 2 repositories concurrent a candlepin exception is thrown.
One of the tasks is getting paused. After resuming it works.
2016-08-14 14:00:11 [app] [I] Started GET "/katello/api/v2/products" for 127.0.0.1 at 2016-08-14 14:00:11 +0000
2016-08-14 14:00:11 [app] [I] Processing by Katello::Api::V2::RepositoriesController#index as */*
2016-08-14 14:00:11 [app] [I] Parameters: {"per_page"=>9999, "organization_id"=>3, "name"=>"HOIRHEL-6.8-d20160814", "product_id"=>"36", "api_version"=>"v2", "repository"=>{"name"=>"HOIRHEL-6.8-d20160814", "product_id"=>"36"}
}
2016-08-14 14:00:12 [app] [I] Authorized user hoici(hoici )
2016-08-14 14:00:12 [app] [I] Rendered /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.68/app/views/katello/api/v2/repositories/index.json.rabl within katello/api/v2/layouts/collection (1.4ms)
2016-08-14 14:00:12 [app] [I] Completed 200 OK in 45ms (Views: 2.4ms | ActiveRecord: 8.0ms)
2016-08-14 14:00:12 [app] [I] Started POST "/katello/api/v2/repositories" for 127.0.0.1 at 2016-08-14 14:00:12 +0000
2016-08-14 14:00:12 [app] [I] Processing by Katello::Api::V2::RepositoriesController#create as */*
2016-08-14 14:00:12 [app] [I] Parameters: {"per_page"=>9999, "organization_id"=>3, "name"=>"HOIRHEL-6Server-d20160814", "product_id"=>"36", "content_type"=>"yum", "url"=>"http://fibsbamboodev.hag.hilti.com/hoici/release/HOIR
HEL-6Server-d20160814/rpm", "api_version"=>"v2", "repository"=>{"name"=>"HOIRHEL-6Server-d20160814", "url"=>"http://fibsbamboodev.hag.hilti.com/hoici/release/HOIRHEL-6Server-d20160814/rpm", "content_type"=>"yum", "product_id"=
>"36"}}
2016-08-14 14:00:12 [app] [I] Authorized user hoici(hoici )
2016-08-14 14:00:12 [app] [I] Started POST "/katello/api/v2/repositories" for 127.0.0.1 at 2016-08-14 14:00:12 +0000
2016-08-14 14:00:12 [app] [I] Processing by Katello::Api::V2::RepositoriesController#create as */*
2016-08-14 14:00:12 [app] [I] Parameters: {"per_page"=>9999, "organization_id"=>3, "name"=>"HOIRHEL-6.8-d20160814", "product_id"=>"36", "content_type"=>"yum", "url"=>"http://fibsbamboodev.hag.hilti.com/hoici/release/HOIRHEL-
6.8-d20160814/rpm", "api_version"=>"v2", "repository"=>{"name"=>"HOIRHEL-6.8-d20160814", "url"=>"http://fibsbamboodev.hag.hilti.com/hoici/release/HOIRHEL-6.8-d20160814/rpm", "content_type"=>"yum", "product_id"=>"36"}}
2016-08-14 14:00:12 [app] [I] Authorized user hoici(hoici )
2016-08-14 14:00:12 [app] [I] Processing by Katello::Api::V2::ProductsController#index as */*
2016-08-14 14:00:12 [app] [I] Parameters: {"per_page"=>9999, "organization_id"=>3, "name"=>"HOIRHEL", "api_version"=>"v2", "product"=>{"name"=>"HOIRHEL", "organization_id"=>3}}
2016-08-14 14:00:12 [app] [I] Authorized user hoici(hoici )
2016-08-14 14:00:13 [app] [I] Rendered /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.68/app/views/katello/api/v2/products/index.json.rabl within katello/api/v2/layouts/collection (596.3ms)
2016-08-14 14:00:13 [app] [I] Completed 200 OK in 712ms (Views: 586.4ms | ActiveRecord: 30.0ms)
2016-08-14 14:00:13 [foreman-tasks/action] [E] Runtime Error could not execute statement at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse:2,102 (Katello::Errors::CandlepinError)
| /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.68/app/lib/actions/middleware/propagate_candlepin_errors.rb:21:in `rescue in propagate_candlepin_errors'
| /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.68/app/lib/actions/middleware/propagate_candlepin_errors.rb:19:in `propagate_candlepin_errors'
| /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.68/app/lib/actions/middleware/propagate_candlepin_errors.rb:9:in `run'
| /opt/theforeman/tfm/root/usr/share/gems/gems/dynflow-0.8.11/lib/dynflow/middleware/stack.rb:22:in `call'
| /opt/theforeman/tfm/root/usr/share/gems/gems/dynflow-0.8.11/lib/dynflow/middleware/stack.rb:26:in `pass'
| /opt/theforeman/tfm/root/usr/share/gems/gems/dynflow-0.8.11/lib/dynflow/middleware.rb:17:in `pass'
See attached foreman-debug for more info, the time was 2016-08-14 at 14:00:12
Version-Release number of selected component (if applicable):
How reproducible:
Steps to Reproduce:
1. Create 2 repositories at the same time
2.
3.
Actual results:
Expected results:
Additional info:
Creating multiple repositories at the same time with a script triggers a Nullpointer exception,i will file another BZ for this
hammer -c/opt/hoici/etc/sat6/hammer-hoici.yaml product create --organization-id=3 --name=TestProdA
for i in `seq 1 30`; do hammer -c/opt/hoici/etc/sat6/hammer-hoici.yaml repository create --organization-id=3 --product=TestProdA --content-type=yum --name=TestRepoA$i & done
Enabled 4 repos at once and all enabled fine without any errors or paused tasks, marking as verified.
Comment 7Satellite Program
2018-02-21 16:51:07 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.
>
> https://access.redhat.com/errata/RHSA-2018:0336