Bug 1408940
| Summary: | Cannot disassociate entities from organization | ||
|---|---|---|---|
| Product: | Red Hat Satellite | Reporter: | Oleksandr Shtaier <oshtaier> |
| Component: | API | Assignee: | satellite6-bugs <satellite6-bugs> |
| Status: | CLOSED ERRATA | QA Contact: | Swapnil Abnave <sabnave> |
| Severity: | high | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 6.3.0 | CC: | bbuckingham, dhlavacd, mhulan, sabnave, tstrachota |
| Target Milestone: | Unspecified | Keywords: | AutomationBlocker, Reopened, Triaged |
| Target Release: | Unused | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2018-02-21 16:45:45 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: | |||
Does it work from UI or API directly? I reproduced the issue. It's API issue only, everything works in the UI. It appears when you're removing the last item from the collection. API seems to have problems with accepting empty array and ignores the parameter. Both sat 6.2 and current upstream master work fine. I found out there's already an upstream issue with associated BZ dealing with this issue, closing as duplicate. *** This bug has been marked as a duplicate of bug 1395229 *** Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/17343 has been resolved. Verified Satellite 6.3 SNAP 9
* satellite-6.3.0-16.0.beta.el7sat.noarch
* foreman-1.15.2-1.el7sat.noarch
* katello-3.4.2-1.el7sat.noarch
Before:
# hammer organization info --id=3
---
Smart proxies:
bkr-hv01-guest06.dsal.lab.eng.bos.redhat.com
Subnets:
test-subnet (127.0.0.1/24)
Compute resources:
vCenter
---
After:
# hammer organization remove-subnet --id 3 --subnet test-subnet
# hammer organization remove-smart-proxy --id 3 --smart-proxy-id 1
# hammer organization remove-compute-resource --id 3 --compute-resource-id 1
# hammer organization info --id=3
---
Id: 3
Name: nukelater
Description:
Users:
Smart proxies:
Subnets:
Compute resources:
---
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 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 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 |
Description of problem: Basically, cannot disassociate any entity from organization neither by id nor by name hammer -v -u admin -p changeme organization add-subnet --subnet="dwGoNeFm" --name="89aE3E" The subnet has been associated hammer -v -u admin -p changeme organization info --id="182" Id: 182 Name: 89aE3E ... Subnets: dwGoNeFm (94.138.206.0/26) ... hammer -v -u admin -p changeme organization remove-subnet --subnet="dwGoNeFm" --name="89aE3E" The subnet has been disassociated hammer -v -u admin -p changeme organization info --id="182" ... Subnets: dwGoNeFm (94.138.206.0/26) ... or hammer -v -u admin -p changeme organization add-user --user-id="64" --id="196" The user has been associated hammer -v -u admin -p changeme organization remove-user --user-id="64" --id="196" The user has been disassociated hammer -v -u admin -p changeme organization info --id="196" Id: 196 Name: iVMkzf ... Users: Rp2QHp ... Version-Release number of selected component (if applicable): 6.3.0 SNAP8 How reproducible: Always Steps to Reproduce: 1. Create organization 2. Add any entity to it (user, medium, subnet, hostgroup, etc) 3. Try to remove that entity from organization Actual results: Entity is not disassociated Expected results: Entity is disassociated successfully Additional info: