Accidental deletion of mysql database... What now? The JIRA instance says its locked.

Bummer. Major bummer.

The DB is missing all the tables that get created when you INSTALL jira; but we already have it installed. It just needs to re-create the tables, and then I can use RESTORE or even a mysqldump file.




3 answers

1 accepted

1 vote
Accepted answer

Hi Carle!

If you have a dump, you may try to restore it and all the tables will be recreated. After that just point your Jira to the new database.

You can point it on dbconfig.xml file in your JIRA Home Directory.

Click here for more info.

If you do not have a dump, then I suggest you to create another Jira so the tables will be recreated. Of course since the data was on the database it will be lost. But you'll be able to point your Kira do the new database also using the dbconfig.xml.

0 votes

I'm not sure what the question is here.

If you start Jira and point it at an empty database, it will create all the tables and start "clean". However, you don't need the tables there to restore a backup, that's the point of a database backup.

Jira is locked now because you're running it. Stop it (cleanly). Then start it when you've got the database in the state you need it in.

Thanks everyone. I've got it working again. The weird thing was that when I created the database; using "create database jiradb character set utf8..." the database is just an empty database. That's no surprise. But when I tried to read in my DUMP file, it kept reporting that it wasn't doing anything. That would indicate that it wasn't re-creating the TABLES...

Regarding the comment that was because I had JIRA running, was a bit confusing because I DID shut it down cleanly, and restart it using the startup scripts used by ROOT. Still, it found a reason to LOCK it up because it couldn't find the TABLES it needed in my empty DB. (That was BEFORE I ran the "source" command in mysql to read in the DUMP file.)


So with the 2nd half of my last reply; I'm saying JIRA did NOT re-create the tables, as was mentioned. Instead it chose to go into LOCKED mode.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Oct 16, 2018 in Jira

Looking for anyone who made the switch to Data Center

The Jira Marketing team is putting together an ebook on migrating to Data Center. We're looking for pro tips on how you staffed your project team and organized your Proof of Concept. Share yo...

1,372 views 17 10
Join discussion

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