Bug 1354568
Summary: | creating a hostgroup with invalid id option should raise proper error instead of foreign key constraint error | ||
---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Sachin Ghai <sghai> |
Component: | API | Assignee: | Dominik Hlavac Duran <dhlavacd> |
Status: | CLOSED WONTFIX | QA Contact: | Katello QA List <katello-qa-list> |
Severity: | medium | Docs Contact: | |
Priority: | unspecified | ||
Version: | 6.2.0 | CC: | bkearney, mhulan, tstrachota |
Target Milestone: | Unspecified | Keywords: | Triaged |
Target Release: | Unused | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2018-09-04 17:42:38 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | 1398392 | ||
Bug Blocks: | 1484102 |
Description
Sachin Ghai
2016-07-11 15:20:43 UTC
this issue appears with all 'id' options of hostgroup like: invalid arch-id: =============== ~]# hammer -u admin -p changeme hostgroup create --name test1234455 --architecture-id 45 Could not create the hostgroup: ERROR: insert or update on table "hostgroups" violates foreign key constraint "hostgroups_architecture_id_fk" DETAIL: Key (architecture_id)=(45) is not present in table "architectures". invalid domain-id: ==================~]# hammer -u admin -p changeme hostgroup create --name test1234455 --domain-id 45 Could not create the hostgroup: ERROR: insert or update on table "hostgroups" violates foreign key constraint "hostgroups_domain_id_fk" DETAIL: Key (domain_id)=(45) is not present in table "domains". invalid puppet-proxy-id: ======================= ~]# hammer -u admin -p changeme hostgroup create --name test1234455 --puppet-proxy-id 45 Could not create the hostgroup: ERROR: insert or update on table "hostgroups" violates foreign key constraint "hostgroups_puppet_proxy_id_fk" DETAIL: Key (puppet_proxy_id)=(45) is not present in table "smart_proxies". user should get error: Couldn't find domain 'id' OR could not find architecture 'id' Upstream bug assigned to szadok Upstream bug assigned to szadok Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/17525 has been resolved. Failed on Satellite 6.3 Snap 2.0: * foreman-1.15.0-1.el7sat.noarch * satellite-6.3.0-15.0.beta.el7sat.noarch * katello-3.4.0-3.el7sat.noarch Could not create the hostgroup: ERROR: insert or update on table "hostgroups" violates foreign key constraint "hostgroups_subnet_id_fk" DETAIL: Key (subnet_id)=(5278) is not present in table "subnets". Could not create the hostgroup: ERROR: insert or update on table "hostgroups" violates foreign key constraint "hostgroups_domain_id_fk" DETAIL: Key (domain_id)=(9981) is not present in table "domains". Could not create the hostgroup: ERROR: insert or update on table "hostgroups" violates foreign key constraint "hostgroups_architecture_id_fk" DETAIL: Key (architecture_id)=(3990) is not present in table "architectures". Upstream bug assigned to szadok Upstream bug assigned to szadok Upstream bug assigned to dhlavacd Upstream bug assigned to dhlavacd Created redmine issue http://projects.theforeman.org/issues/20888 from this bug Thank you for your interest in Satellite 6. We have evaluated this request, and we do not expect this to be implemented in the product in the foreseeable future. We are therefore closing this out as WONTFIX. If you have any concerns about this, please feel free to contact Rich Jerrido or Bryan Kearney. Thank you. |