Jira Internal Directory users unable to login due to missing permissions operations

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

After restoring Jira data from the Jira Cloud into the Jira Server via backup file the sysadmin user cannot log in to the Jira instance.

Diagnosis

  • The following error shows up in the atlassian-jira.log:

1 2 3 4 2023-04-24 14:17:40,135+0800 http-nio-8080-exec-19 ERROR anonymous 857x1340x1 wnyyvn 10.27.5.21 /login.jsp [c.a.j.security.login.LoginStoreImpl] com.atlassian.crowd.exception.ApplicationPermissionException: Not allowed to update user attributes 'sysadmin' in directory 'Jira Internal Directory'. com.atlassian.crowd.exception.OperationNotPermittedException: com.atlassian.crowd.exception.ApplicationPermissionException: Not allowed to update user attributes 'sysadmin' in directory 'Jira Internal Directory'. at com.atlassian.crowd.embedded.core.CrowdServiceImpl.setUserAttribute(CrowdServiceImpl.java:335) at com.atlassian.crowd.embedded.core.CrowdServiceImpl.setUserAttribute(CrowdServiceImpl.java:324)

  • Run the following SQL query, in the Jira database, to verify the allowed permission for the directories:

1 select * from cwd_directory_operation;

ℹ️ If the cwd_directory_operation has no data, we will need to manually create it.

Example:

(Auto-migrated image: description temporarily unavailable)

Cause

This behavior is due to the following bug: JRASERVER-72589 - Jira cloud backup when restored results in the user directory operations removed

Solution

  1. Create a backup of your Jira database;

  2. Stop Jira;

  3. Run the following inserts in the Jira database:

    1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'CREATE_GROUP'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'CREATE_ROLE'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'CREATE_USER'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'DELETE_GROUP'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'DELETE_ROLE'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'DELETE_USER'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'UPDATE_GROUP'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'UPDATE_GROUP_ATTRIBUTE'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'UPDATE_ROLE'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'UPDATE_ROLE_ATTRIBUTE'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'UPDATE_USER'); INSERT INTO cwd_directory_operation (directory_id, operation_type) VALUES(1, 'UPDATE_USER_ATTRIBUTE');
  4. Start Jira;

  5. Test the login again;

If the issue persists, you might need to reset the sysadmin password. Therefore, start Jira with the recover admin user: Restore Passwords To Recover Admin User Rights in Jira Server and Data Center

Updated on April 8, 2025

Still need help?

The Atlassian Community is here for you.