'username' failed to sign in com.google.gerrit.server.account.AccountException: Cannot assign external ID "username:username" to account 1000298; external ID already in use

1,104 views
Skip to first unread message

kiran mandala

unread,
May 23, 2019, 3:55:52 AM5/23/19
to Repo and Gerrit Discussion
Affected Version:2.16.4
Suddenly one of user lost the access to gerrit. when user tries to login the gerrit he gets a error as authontication failed.

Error log in gerrit: com.google.gerrit.httpd.auth.ldap.LdapLoginServlet : 'loginid' failed to sign in
com.google.gerrit.server.account.AccountException: Cannot assign external ID "username:loginid" to account 1000298; external ID already in use.

We have done the tests to resolve this issue by updating and deleting the old username and external_ids from reviewDB. But we couldn't able to delete or update the old login details like username and external_id in NoteDB. There is no options to update the accounts and external_ids by administrator in NoteDB.

There are no options to change the username and external_ids through REST API for NoteDB. Are there any other options to modify this accounts in NoteDB??


What is the expected output?
Gerrit shouldn't try to create a new account or external_id for user how is able to login previously.

What do you see instead?
Gerrit should have options for updation of external_ids and usernames in NoteDB.

Matthias Sohn

unread,
May 23, 2019, 4:19:58 AM5/23/19
to kiran mandala, Repo and Gerrit Discussion
On Thu, May 23, 2019 at 9:55 AM kiran mandala <kirank....@gmail.com> wrote:
Affected Version:2.16.4
Suddenly one of user lost the access to gerrit. when user tries to login the gerrit he gets a error as authontication failed.

Error log in gerrit: com.google.gerrit.httpd.auth.ldap.LdapLoginServlet : 'loginid' failed to sign in
com.google.gerrit.server.account.AccountException: Cannot assign external ID "username:loginid" to account 1000298; external ID already in use.

We have done the tests to resolve this issue by updating and deleting the old username and external_ids from reviewDB. But we couldn't able to delete or update the old login details like username and external_id in NoteDB. There is no options to update the accounts and external_ids by administrator in NoteDB.

There are no options to change the username and external_ids through REST API for NoteDB. Are there any other options to modify this accounts in NoteDB??

did you try to set the old account to inactive [1] ?
-Matthias
What is the expected output?
Gerrit shouldn't try to create a new account or external_id for user how is able to login previously.

What do you see instead?
Gerrit should have options for updation of external_ids and usernames in NoteDB.

--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/repo-discuss/e19bd53e-d3fc-4d48-8962-5cbba470c3e7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

kiran mandala

unread,
May 23, 2019, 4:24:42 AM5/23/19
to Repo and Gerrit Discussion
Yes...But that didn't help. Same error again.

Thursday, May 23, 2019 at. 10:19:58 UTC + 2 wrote Matthias Sohn:
On Thu, May 23, 2019 at 9:55 AM kiran mandala <kirank...@gmail.com> wrote:
Affected Version:2.16.4
Suddenly one of user lost the access to gerrit. when user tries to login the gerrit he gets a error as authontication failed.

Error log in gerrit: com.google.gerrit.httpd.auth.ldap.LdapLoginServlet : 'loginid' failed to sign in
com.google.gerrit.server.account.AccountException: Cannot assign external ID "username:loginid" to account 1000298; external ID already in use.

We have done the tests to resolve this issue by updating and deleting the old username and external_ids from reviewDB. But we couldn't able to delete or update the old login details like username and external_id in NoteDB. There is no options to update the accounts and external_ids by administrator in NoteDB.

There are no options to change the username and external_ids through REST API for NoteDB. Are there any other options to modify this accounts in NoteDB??

did you try to set the old account to inactive [1] ?
-Matthias
What is the expected output?
Gerrit shouldn't try to create a new account or external_id for user how is able to login previously.

What do you see instead?
Gerrit should have options for updation of external_ids and usernames in NoteDB.

--
--
To unsubscribe, email repo-d...@googlegroups.com

More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-d...@googlegroups.com.

Nate West

unread,
May 8, 2020, 2:20:34 AM5/8/20
to Repo and Gerrit Discussion
We recently upgraded a gerrit instance to 2.16.16 and have he exact same problem.  Some years could not login a day or two latter.  Looks like gerrit tries to create a second account with the same user name when the login with ldap.

Raviraj Karasulli

unread,
May 11, 2020, 5:31:15 AM5/11/20
to Repo and Gerrit Discussion


Are the account name in the account_external_ids table and LDAP user name have different cases?
When a user logs in for the first time, gerrit stores the user name. Next time when the user tries to log in with a different case, we see this issue.

david charles

unread,
May 11, 2020, 10:20:46 AM5/11/20
to Repo and Gerrit Discussion
Reply all
Reply to author
Forward
0 new messages