[GH-ISSUE #3304] How to change admin user without losting configuration #7110

Closed
opened 2026-08-05 01:11:37 -04:00 by saavagebueno · 1 comment
Owner

Originally created by @sergefedorow on GitHub (Feb 10, 2025).
Original GitHub issue: https://github.com/netbirdio/netbird/issues/3304

I have a Keycloak IDP and lost my 'netbird' user. It was deleted during an export/import process. The new 'netbird' user does not have admin privileges; his UI only shows the peer menu. The management log shows the old admin ID:
management-1 | 2025-02-10T12:59:14Z WARN management/server/account.go:757: user decf693c-696a-4b27-b244-cc8eff6bd47a not found in IDP

The solution in issue #1372 involves deleting the management volume. This helps, but it deletes the entire configuration.
Is it possible to change the 'netbird' admin user ID to a new one without recreating the whole configuration?"

Originally created by @sergefedorow on GitHub (Feb 10, 2025). Original GitHub issue: https://github.com/netbirdio/netbird/issues/3304 I have a Keycloak IDP and lost my 'netbird' user. It was deleted during an export/import process. The new 'netbird' user does not have admin privileges; his UI only shows the peer menu. The management log shows the old admin ID: `management-1 | 2025-02-10T12:59:14Z WARN management/server/account.go:757: user decf693c-696a-4b27-b244-cc8eff6bd47a not found in IDP` The solution in [issue #1372](https://github.com/netbirdio/netbird/issues/1372) involves deleting the management volume. This helps, but it deletes the entire configuration. Is it possible to change the 'netbird' admin user ID to a new one without recreating the whole configuration?"
Author
Owner

@braginini commented on GitHub (Feb 10, 2025):

I have a Keycloak IDP and lost my 'netbird' user. It was deleted during an export/import process. The new 'netbird' user does not have admin privileges; his UI only shows the peer menu. The management log shows the old admin ID: management-1 | 2025-02-10T12:59:14Z WARN management/server/account.go:757: user decf693c-696a-4b27-b244-cc8eff6bd47a not found in IDP

The solution in issue #1372 involves deleting the management volume. This helps, but it deletes the entire configuration. Is it possible to change the 'netbird' admin user ID to a new one without recreating the whole configuration?"

Hey @sergefedorow, you can modify the table users by changing the user role.
Look for store.db if you are using sqlite and then find the new user by ID. Update the role.

<!-- gh-comment-id:2648796458 --> @braginini commented on GitHub (Feb 10, 2025): > I have a Keycloak IDP and lost my 'netbird' user. It was deleted during an export/import process. The new 'netbird' user does not have admin privileges; his UI only shows the peer menu. The management log shows the old admin ID: `management-1 | 2025-02-10T12:59:14Z WARN management/server/account.go:757: user decf693c-696a-4b27-b244-cc8eff6bd47a not found in IDP` > > The solution in [issue #1372](https://github.com/netbirdio/netbird/issues/1372) involves deleting the management volume. This helps, but it deletes the entire configuration. Is it possible to change the 'netbird' admin user ID to a new one without recreating the whole configuration?" Hey @sergefedorow, you can modify the table users by changing the user role. Look for store.db if you are using sqlite and then find the new user by ID. Update the role.
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: DYNR/netbird#7110