Reset admin password JIRA 7 H2 database

 Hi, 

Is there a way I can reset the admin password on an instance with the next characteristics:

  • Server
  • JIRA 7.2.2
  • H2 db

I tried to follow the directions on the Atlassian documentation but when I open the H2 query UI, I only see the USERS table.

Thanks.

1 answer

1 accepted

1 vote

So I tried to follow this KB, and at first I ran into problems getting this to work as well.   In my case, I found that the problem was the JDBC URL that I was using.   But I did find that the instructions in Accessing JIRA's H2 embedded database where accurate in getting this work.

The default value in that field was something like

jdbc:h2:~/

But I found that I needed to lookup the specific path of the Jira H2 database from the JIRAHOME/dbconfig.xml and use that value:

jdbc:h2:file:/Users/aheinzer/jira/750/jira/database/h2db

It is also very important to Stop Jira first.  When I stopped Jira, and used this value in the dbconfig file, I was able to connect to the database and see all the expected Jira tables.  For me the confusing part was that you can enter just about any value for the JDBC URL and still connect.  So it isn't always clear why those tables would not appear.  

Since you're not seeing the Jira tables, I suspect that your URL is incorrect and in turn you are not actually connecting to the Jira database as expected.

Once you can do that, you should then be able to follow the steps in Retrieving the Jira Administrator password.

 

But I would still recommend getting away from the H2 platform entirely.  (Mostly because it's not particularly stable, and is known to be easily corrupted if still running when the OS is shutdown.)  The steps in JIRA How to migrate from HSQL database to an external database explain the way move your data to a more reliable platform.

Thanks,

This is a sandbox instance, but you're right I better will create a new database because I can actually enter to the Query UI but I cannot still see the tables. Thanks for your answer.

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 Monday in Jira Software

How large do you think Jira Software can grow?

Hi Atlassian Community! My name is Shana, and I’m on the Jira Software team. One of the many reasons this Community exists is to connect you to others on similar product journeys or with comparabl...

506 views 6 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