Jump to content
- Rename the user in LDAP (on terbium):
- Find the user's current information:
ldaplist -l passwd <shell-account-name>
- Ensure the new CN doesn't conflict with another user's CN
ldapsearch -LLL -x -D 'cn=proxyagent,ou=profile,dc=wikimedia,dc=org' -w $(grep -Po "(?<=BINDPW).*" /etc/ldap/ldap.conf) -b 'ou=people,dc=wikimedia,dc=org' 'cn=<new-cn>'
- Change the user's CN
modify-ldap-user --cn="<new-cn>" <shell-account-name>
- Rename the user in Wikitech (via Special:RenameUser)
- Rename the user in Gerrit
- Connect to Gerrit's database
ssh -p 29418 gerrit.wikimedia.org gerrit gsql
- Find the user's current information
select * from account_external_ids where external_id like 'gerrit:<old cn>'
(this sometimes might not be the casing you expect, hence the like)
- Update gerrit: entry
update account_external_ids set external_id = 'gerrit:<new cn>' where external_id = 'gerrit:<old cn>'
- Wait for caches to clear, or alternatively force clear them
ssh -p 29418 gerrit.wikimedia.org gerrit flush-caches --all
-