keystone-manage bootstrap failed to create assignment if user/project/role exists
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Identity (keystone) |
Fix Released
|
Medium
|
Dave Chen |
Bug Description
If `keystone-manage bootstrap` fails with the role already exists (this may happen if someone use OSC CLI created a role but someone else want to boostrap a set of `user`, `project` or `role` without aware of the role has already created.), the project or user can still be created successfully.
And then if redefine the role, `keystone-manage bootstrap` will still fail since `user`, `project` have been created, but `keystone-manage bootstrap` cannot handle with this.
See the example:
dave@shldeOTCop
25784 TRACE keystone details=
25784 TRACE keystone Conflict: Conflict occurred attempting to store role - Duplicate Entry
25784 TRACE keystone
change the role to `bootstrap_role` ...
dave@shldeOTCop
25813 TRACE keystone details=
25813 TRACE keystone Conflict: Conflict occurred attempting to store project - Duplicate Entry
25813 TRACE keystone
So, if we want to boostrap again, we need delete project, user manually, this is not friendly to end user.
`keystone-manage bootstrap` should not create any `user`, `project` if the command is not executed successfully.
According to the comments from Morgan, the `user`, `project` or `role` should be created but the real issue is that assignment cannot be created if either of them exists, see the comments #2 for the updated.
Changed in keystone: | |
assignee: | nobody → Dave Chen (wei-d-chen) |
summary: |
- keystone-manage bootstrap should not create user/project if it fails + keystone-manage bootstrap failed to create assignment if + user/project/role exists |
Changed in keystone: | |
milestone: | none → mitaka-2 |
importance: | Undecided → Medium |
Changed in keystone: | |
assignee: | Dave Chen (wei-d-chen) → Steve Martinelli (stevemar) |
Changed in keystone: | |
assignee: | Steve Martinelli (stevemar) → Dave Chen (wei-d-chen) |
Changed in keystone: | |
assignee: | Dave Chen (wei-d-chen) → Steve Martinelli (stevemar) |
Changed in keystone: | |
assignee: | Steve Martinelli (stevemar) → Dave Chen (wei-d-chen) |
description: | updated |
hmm, this really should have been solved by this patch: https:/ /review. openstack. org/#/c/ 256969/ 5/keystone/ cmd/cli. py
it almost seems like you're on an old branch?