How to bulk set users to inactive via SQL

Trying to take all users in Internal Directory and set tehm to inactive status, however testign out our SQL it does not seem to make a user inactive. We set active = 0 where user is in directory 1 (internal) for a specific user. We can see the changes take place in the cwd_user table, however I can still login as that user. if I set the user to inactive using the Edit mode in JIRA, I can see in SQL the active flag sets to 0, and I no longer can login as this user. What is missing? I looked at the scheme and we are not seeing where else we need to change to make the user inactive. We have 300+ users in our internal directory we want to force to login with AD, and wish to set all to inactive on internal directory.

2 answers

1 accepted

1 vote
Accepted answer

Hi Mick,

Sorry if my answer seems silly, but just to make sure. Are you restarting Jira after making the changes on the database?

Also, if you want to use AD as primary Directory, you can put the Internal on the second position and the AD on the top. Afetr that you can disable the Internal, this will make all users inside this directory to be automaticaly disabled.

Hi Bruna, thansk for the answer. We had not restarted JIRA, apparantly it caches this data. We do have AD as primary and Internal as secondary, but we want to leave internal running since we have our emergency login if AD goes down, as well as some rest script logins there. Thanks!

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Nov 27, 2018 in Portfolio for Jira

Introducing a new planning experience in Portfolio for Jira (Server/DC)

In the past, Portfolio for Jira required a high degree of detail–foresight that was unrealistic for many businesses to   have–in   order to produce a reliable long-term roadmap. We're tur...

2,954 views 19 22
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you