Bulk update user information in Jira server
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
The content on this page relates to platforms which are not supported for JIRA. Consequently, Atlassian cannot guarantee providing any support for it. Please be aware that this material is provided for your information only and using it is done so at your own risk.
Solution
Goal
Modify users information for a large amount of users in JIRA
Information may be:
userFullName
userEmail
newUserId (on JIRA 6.1+, not applicable for JIRA Cloud)
activate or deactivate (not applicable for JIRA Cloud)
Problem:
There is no built in method for admins to update large amount of users on one go in JIRA or the Cloud User Management.
Database access is restricted on Atlassian Cloud making manual changes to the users information only possible through the User Management.
Workaround
Use the JIRA Command Line Interface created by Bob Swift to update users using a text file.
Solution Example:
Steps to bulk update email addresses: (to update different information, modify the list on step 3 and the parameter name 'userEmail' on step 4)
Get the JIRA Command Line Interface by following the Installation and Use guide.
Test the CLI connection: (replacing SERVER, USER and PASSWORD with your instance URL and administrator user details)
1
./jira.sh --server https://SERVER --user USER --password PASSWORD --action getServerInfo
Generate a file with the information to be changed for each user and place it inside the CLI folder where the jira.sh executable is.
for example:
data.txt
1 2
user email@email.com otheruser email2@email.com
Bulk update the emails:
1
cat data.txt | xargs -n 2 sh -c './jira.sh --server https://SERVER --user USER --password PASSWORD --action updateUser --userId $0 --userEmail $1'
Other Solutions
You may want to be interested in alternative bulk update solution using JIRA REST API:
Was this helpful?