Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Error connecting to database

I have installed Jira instance on server VM machine in Jan 2018.  I am using Jira since January 2018 for project tracking purpose. settings as per follow.

1. Configured in built database.

If I navigate to Jira URL it shows me database connection error message.

Please suggest workaround.



1 answer

HI @kapil_kinikar

Could you please share with us error message or screenshot for the same.

Sure, Please see attached screenshot

Start Up Error.PNG

HI @kapil_kinikar

As mentioned in the error screenshot please check whether the Database is running or not and the confirm that have you been provided database details are correct?

Thanks for the reply.

We are using Inbuilt jira Database, so how do I confirm that database is running?

I haven't set any username or password at the time of configuration in the server.xml file.

The built-in database does not "run", it's a file and memory based system that is read at the time of startup.

The error message suggests that the connection to it is not working, which usually means the database has failed in the case of H2.  You can read the application logs for more, they will usually tell you where there is an error, but if it has failed, it is likely that you have lost a lot of data, and will need to look for a backup (and then moving to a proper database as soon as possible)

Thanks for the reply,

Application log says,

018-08-20 04:18:31,128 JIRA-Bootstrap ERROR [c.a.config.bootstrap.DefaultAtlassianBootstrapManager] Could not successfully test your database:
org.h2.jdbc.JdbcSQLException: IO Exception: "C:/Program Files/Atlassian/Application Data/JIRA/database/" [90028-185]
at org.h2.message.DbException.getJdbcSQLException(
at org.h2.message.DbException.get(
at org.h2.mvstore.db.MVTableEngine.init(
at org.h2.engine.Database.getPageStore(
at org.h2.engine.Database.openDatabase(
at org.h2.engine.Database.<init>(
at org.h2.engine.Engine.openSession(
at org.h2.engine.Engine.openSession(
at org.h2.engine.Engine.createSessionAndValidate(
at org.h2.engine.Engine.createSession(
at org.h2.engine.Engine.createSession(
at org.h2.engine.SessionRemote.connectEmbeddedOrServer(
at org.h2.jdbc.JdbcConnection.<init>(
at org.h2.jdbc.JdbcConnection.<init>(
at org.h2.Driver.connect(
at java.sql.DriverManager.getConnection(
at java.sql.DriverManager.getConnection(
at com.atlassian.config.bootstrap.DefaultAtlassianBootstrapManager.getTestDatabaseConnection(
at com.atlassian.jira.config.database.JdbcDatasource.getConnection(
at com.atlassian.jira.config.database.DatabaseConfig.testConnection(
at java.util.Iterator.forEachRemaining(
at java.util.Spliterators$IteratorSpliterator.forEachRemaining(
at com.atlassian.jira.startup.BootstrapContainerLauncher.start(
at com.atlassian.jira.startup.DefaultJiraLauncher.preDbLaunch(
at com.atlassian.jira.startup.DefaultJiraLauncher.lambda$start$0(
at com.atlassian.jira.startup.DefaultJiraLauncher.start(
at com.atlassian.jira.startup.LauncherContextListener.initSlowStuff(
Caused by: java.lang.IllegalStateException: Could not open file nio:C:/Program Files/Atlassian/Application Data/JIRA/database/ [1.4.185/1]
at org.h2.mvstore.DataUtils.newIllegalStateException(
at org.h2.mvstore.MVStore.<init>(
at org.h2.mvstore.MVStore$
at org.h2.mvstore.db.MVTableEngine$Store.<init>(
... 44 more
Caused by: java.nio.channels.ClosedByInterruptException
at java.nio.channels.spi.AbstractInterruptibleChannel.end(
at org.h2.mvstore.cache.FilePathCache$FileCache.size(
2018-08-20 04:18:31,144 JIRA-Bootstrap ERROR [] JIRA couldn't connect to your database
2018-08-20 04:18:31,144 JIRA-Bootstrap ERROR [] JIRA failed to establish a connection to your database.
This could be because:
- Your database isn't running
- The configuration of your dbconfig.xml file is incorrect (user, password, or database URL etc.)
- There is a network issue between JIRA and your database (e.g. firewall, database doesn't allow remote access etc.)

There are several other solutions you can try, review our documentation and see what works for you.

2018-08-20 04:18:31,159 JIRA-Bootstrap INFO [c.a.jira.startup.JiraStartupLogger] Running JIRA startup checks.
2018-08-20 04:18:31,159 JIRA-Bootstrap FATAL [c.a.jira.startup.JiraStartupLogger] Startup check failed. JIRA will be locked.
2018-08-20 04:18:31,316 JIRA-Bootstrap INFO [c.a.jira.startup.LauncherContextListener] Memory Usage:
Heap memory : Used: 60 MiB. Committed: 489 MiB. Max: 745 MiB
Non-heap memory : Used: 40 MiB. Committed: 42 MiB. Max: 1264 MiB
TOTAL : Used: 100 MiB. Committed: 530 MiB. Max: 2009 MiB
2018-08-20 04:18:31,316 localhost-startStop-1 INFO [c.a.jira.startup.DefaultJiraLauncher] Stopping launchers
2018-08-20 04:18:31,331 localhost-startStop-1 ERROR [o.a.c.c.C.[Catalina].[localhost].[/]] Exception sending context destroyed event to listener instance of class com.atlassian.jira.startup.LauncherContextListener
at com.atlassian.jira.startup.ClusteringLauncher.stop(
at com.atlassian.jira.startup.DefaultJiraLauncher.stop(
at com.atlassian.jira.startup.LauncherContextListener.contextDestroyed(
at org.apache.catalina.core.StandardContext.listenerStop(
at org.apache.catalina.core.StandardContext.stopInternal(
... 3 filtered
at java.util.concurrent.ThreadPoolExecutor.runWorker(
at java.util.concurrent.ThreadPoolExecutor$

Please suggest workaround.

Hi Kapil,

Did you find any solution regarding the issue you mentioned

Hi, I am also facing same issue. Our jira server had issue with memory. Drive got full but after expanding drive, we are still getting this issue. I am also using inbuild jira database

I also faced this issues almost each time I installed JIRA SD, and got this error. I spent a lot of time without any luck and ended up re installation. Fortunately, I now take backup of system until I get any solution of this issue. Will look this thread and if I find anything, will post here.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Jira Software

How to create Jira issus from Excel file?

When to use CSV importer When managing your processes in Jira, there are many occasions where you need to create a lot of tasks. Creating them one by one will cost you a lot of time and effort and i...

4,326 views 22 31
Read article

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you