Bug #20899

Unable to delete default admin user

Added by Daniel Lobato Garcia 2 months ago. Updated 2 months ago.

Status:Duplicate
Priority:Normal
Assigned To:-
Category:Notifications
Target version:-
Difficulty: Bugzilla link:1490305
Found in release: Pull request:
Story points-
Velocity based estimate-

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1490305

Description of problem: We were trying to delete default admin user with another user having all permissions and was administrator. But while deleting default user, it shows error as " ERROR: update or delete on table "users" violates foreign key constraint "fk_rails_51975e21a8" on table "notification_recipients" DETAIL: Key (id)=(3) is still referenced from table "notification_recipients"."

How reproducible: always

Steps to Reproduce:
1. Login to satellite with default admin user
2. Create another user having all permissions and make administrator
3. Logout from admin
4. Login using another user created
5. Delete default admin user.

Actual results:
Not able to delete default admin user. It shows error as " ERROR: update or delete on table "users" violates foreign key constraint "fk_rails_51975e21a8" on table "notification_recipients" DETAIL: Key (id)=(3) is still referenced from table "notification_recipients"."

Additional info: Any User with administrator role can delete another user with administrator role but in case of deleting default admin it throws error.


Related issues

Related to Foreman - Bug #20316: unable to delete user. leads to foreign key violation Closed 07/17/2017

History

#1 Updated by Marek Hulán 2 months ago

  • Subject changed from Unable to delete default admin user to Unable to delete default admin user
  • Category set to Notifications

#2 Updated by Marek Hulán 2 months ago

Daniel, were you able to reproduce? It seems like a duplicate of #20316

#3 Updated by Marek Hulán 2 months ago

  • Status changed from New to Duplicate

I just verified the fix. This is a duplicate.

#4 Updated by Marek Hulán 2 months ago

  • Related to Bug #20316: unable to delete user. leads to foreign key violation added

Also available in: Atom PDF