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

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
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published Sunday in Agility

You asked for it, so we delivered: images on issues have arrived

A picture tells a thousand words. And agility boards have just released their latest feature: cover images on issues – so now your board can tell a story at first glance. Upload attachmen...

218 views 2 11
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