JIRA fails to start on system restart - Windows

Still need help?

The Atlassian Community is here for you.

Ask the community

Symptoms

  1. When Windows or Windows Server machine restarts, the JIRA service fails to start.
  2. The database engine for JIRA is running on the same machine as JIRA.

The following appears in the atlassian-jira.log:

2012-04-11 10:55:04,316 main ERROR      [NoModule] Error getting datasource via DBCP: JdbcDatasourceInfo{uri='jdbc:jtds:sqlserver://localhost:1433/jiradb', driverClassName='net.sourceforge.jtds.jdbc.Driver', username='jiradbuser', password='********', isolationLevel='null', connectionProperties=null, connectionPoolInfo=ConnectionPoolInfo{maxSize=15, minSize=2, maxWait=60000, sleepTime=300000, lifeTime=600000, deadLockMaxWait=600000, deadLockRetryWait=10000, validationQuery='null', minEvictableTimeMillis=null, timeBetweenEvictionRunsMillis=null}}
org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (Cannot open database "jiradb" requested by the login. The login failed.)

Diagnosis

JIRA fails to start every time (or almost every time) the server is restarted. Any other attempts to start JIRA are successful.

Cause

Because of the parallel nature of service startups in Windows, it is possible (but unusual) that the SQLSERVER service was not fully started by the time the JIRA service was online.

Workaround

To work around this issue, use services.msc to set the JIRA service to restart the service on failure.

Resolution

Atlassian recommends the greatest possible care when modifying the Windows registry. Be sure to back up your registry before making any changes to it. Incorrect changes to your registry can make your system fully inoperable.

  1. Open HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\<JIRA_service_name>
  2. Add MSSQLSERVER to the REG_MULTI_SZ key DependOnService

Last modified on Mar 30, 2016

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.