"No suitable driver found for >jdbc:h2:file" Edited

When trying to access JIRA's H2 embedded database, I get the error:

"No suitable driver found for >jdbc:h2:file:C:\Program Files\Atlassian\Application Data\JIRA/database/h2db 08001/0
java.sql.SQLException: No suitable driver found for >jdbc:h2:file:C:\Program Files\Atlassian\Application Data\JIRA/database/h2db 
    at java.sql.DriverManager.getConnection(Unknown Source) 
    at java.sql.DriverManager.getConnection(Unknown Source) 
    at org.h2.util.JdbcUtils.getConnection(JdbcUtils.java:282) 
    at org.h2.server.web.WebServer.getConnection(WebServer.java:759) 
    at org.h2.server.web.WebApp.login(WebApp.java:957) 
    at org.h2.server.web.WebApp.process(WebApp.java:211) 
    at org.h2.server.web.WebApp.processRequest(WebApp.java:170) 
    at org.h2.server.web.WebThread.process(WebThread.java:137) 
    at org.h2.server.web.WebThread.run(WebThread.java:93) 
    at java.lang.Thread.run(Unknown Source) "

 

Could someone help point me in the right direction to resolve this?

3 answers

1 vote

That suggests either an installation that was for one of the supported databases, or a damaged install that the database driver has been rendered unusable.

Corrupt files, incorrect permissions or virus checkers can all kill the access to the driver.  The usual culprit is permissions, but you should also disable anti-virus to see if it's that.  Corrupt or lost files are a bit more involved to fix.

Good afternoon Nic,

After some time of looking at it since posting that today, I'm nearly 100% sure it's database corruption. My own fault really and I'm working to try to restore as best as possible.

I did try your antivirus suggestion as one was installed last Friday but no luck.

Thank you though!

0 vote

Hi Audra,

What steps are you following when you get this error?   If you are following the steps in Accessing JIRA's H2 embedded database then I would expect that you have have to first call a java jar file that is expected to handle the driver aspects for connecting to this database.

That guide has steps for both GUI and Command line interfacing with this database.  I think the GUI tends to be easier to use, but you do tend to need to call that jar file via the windows command prompt to start.

Could you let me know what version of Jira this is?

Since this is a Windows environment, I would expect you might have to adjust path since Windows paths are denoting directories with '\' whereas Unix/Linux paths are denoting directories with '/'.

If you are still seeing this error, I would be interested to see if you can post a screenshot of your display when this happens.  I would be interested to see exactly how you are seeing this specific error.

Regards,
Andy

Good afternoon Andy,

I am in a Windows environment and I was following the steps exact. Navigating to the appropriate directory, opening a command prompt there, and calling the java jar file (though mine wasn't java -jar h2-1.4.187.jar, it was java -jar h2-1.4.185.jar). From there, I went and found my dbconfig file and pasted exact (in this case: jdbc:h2:file:C:\Program Files\Atlassian\Application Data\JIRA/database/h2db) and tried to connect.

I have a feeling that was just the tip of the iceberg though as I got a new error of "General error: "java.lang.NullPointerException" [50000-185] HY000/50000". As stated above, I now believe it is database corruption.

 

Thank you though!

Audra

0 vote

If you are looking maintain your Jira data and migrate it off this potentially corrupted H2 database, I would recommend these steps:

  1. Select a database type/version from our Supported platforms - Atlassian Documentation  (it's important to find the correspond version of this page that meets your version of Jira)
  2. Create a new blank database per Connecting JIRA to a database, (paying close attention to the correct collation for that database type)
  3. Gather an XML backup of your JIRA instance.  Even if you can't start JIRA, you can likely still find a recent one of these backups in the filesystem of the JIRA server.  By default this is saved in <jira-home>/export/ folder.  
  4. Stop JIRA,
  5. Run the JIRA Configuration tool to tell JIRA to use the new blank database, save these changes, (if you can't run this, then you can just directly edit the <jira-home>/dbconfig.xml file to make these changes)
  6. Start JIRA up again (when JIRA starts with an empty database, it automatically launches the setup wizard)
  7. Copy the export XML zip file from <jira-home>/export/ into <jira-home>/import/
  8. Then you can import the backup using the 'Import your data' link in the setup wizard

By following these steps you can then import your previous data into a supported database with the correct database setup.

Good afternoon Andy,

This is actually what I'm trying to do now, but I'm experiencing a different issue, haha. It seems I'm just having problems with JIRA today.

Thank you.

Audra

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Sarah Schuster
Posted Mar 28, 2018 in Jira Software

Can a company’s culture make or break agile adoption?

Can a new-to-agile team survive and thrive in a non-agile culture? If so, what advice would you give to those trying to be agile in a non-agile culture? What's the key(s) to success? Share your thoug...

13,139 views 15 13
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