Cannot delete a service or endpoint
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Identity (keystone) |
Fix Released
|
Low
|
Theodore Ilie |
Bug Description
I created an endpoint with an error by mistake as follows;
keystone endpoint-create --service_id 410de5fed7544c9
notice the space in each tenant_i d should be tenant_id.
Should easily be able to delete the endpoint using
keystone service-delete 410de5fed7544c9
but I get
No handlers could be found for logger "keystoneclient
Authorization Failed: An unexpected error prevented the server from fulfilling your request. u'tenant_i d' (HTTP 500)
This is as ~(keystone_admin)
thanks
Changed in keystone: | |
assignee: | nobody → Sergio Cazzolato (sergio-j-cazzolato) |
Changed in keystone: | |
status: | Triaged → In Progress |
Changed in keystone: | |
assignee: | Sergio Cazzolato (sergio-j-cazzolato) → nobody |
Changed in keystone: | |
status: | In Progress → Confirmed |
Changed in keystone: | |
assignee: | nobody → Juan Antonio Osorio Robles (juan-osorio-robles) |
Changed in keystone: | |
assignee: | Juan Antonio Osorio Robles (juan-osorio-robles) → nobody |
Changed in keystone: | |
assignee: | nobody → Manikanth Akshintala (manikanth-akshintala) |
Changed in keystone: | |
assignee: | Manikanth Akshintala (manikanth-akshintala) → nobody |
status: | Confirmed → Invalid |
status: | Invalid → Confirmed |
Changed in keystone: | |
assignee: | nobody → Theodore Ilie (theoilie-ti) |
tags: | added: test-improvement |
Changed in keystone: | |
assignee: | Theodore Ilie (theoilie-ti) → David Stanek (dstanek) |
Changed in keystone: | |
assignee: | David Stanek (dstanek) → Theodore Ilie (theoilie-ti) |
Changed in keystone: | |
status: | In Progress → Fix Committed |
Changed in keystone: | |
milestone: | none → liberty-2 |
status: | Fix Committed → Fix Released |
Changed in keystone: | |
milestone: | liberty-2 → 8.0.0 |
Interesting issue; let try to explain what's going on and how to work around it.
First, to delete and endpoint created with endpoint-create you should be using endpoint-delete, not service-delete:
keystone endpoint-delete 410de5fed7544c9 0a36ebdb8b38f0c ea
However, that's still going to fail in your case because you have an invalid endpoint in the catalog, so the client is failing to authenticate itself -- it's never getting as far as attempting to delete anything.
As a workaround, bypass authentication (the credentials specified by your environment variables) using token/endpoint values:
keystone --os-token= <keystone. conf's admin_token> and --os-endpoint=http:// localhost: 35357/v2. 0/ endpoint-delete 410de5fed7544c9 0a36ebdb8b38f0c ea
Although this technically counts as user-error, I'd vastly prefer to see invalid endpoints suppressed from the service catalog output instead of raising an error back to the API and killing the authentication process. The current error message raised to the API should instead be logged to ERROR.