Hi Everyone
Two weeks back our VM which is hosting JIRA service rebooted automatically. So, we didn't have a chance to properly shutdown Tomcat. The restart of JIRA was failing as embedded DB was not starting up. Upon close inspection of logs, we found that DB was corrupted due to abrupt shutdown of tomcat server.
Now we have inducted a new external DB (Oracle SQL), and it is running. We have also created a new JIRA-HOME directory, and changed the configuration in jira-application.properties file. Fortunately, the data in embedded hSQL DB is backed up in export folder.
The question is: how do I restart JIRA because now I won't get the option of connecting to an external DB in a startup GUI? How do I do it? Once JIRA starts successfully, we will import the backed up data.
Need Help!
Regards
Hey Aditya,
The database can be configured in a file called dbconfig.xml in Jira's home directory. We've got documentation on what goes in this file as well as a sample you can reference and modify.
But, even easier than that, you can simply remove or rename the file and Jira's setup wizard will run again when you start it up! The lack of the dbconfig.xml file is what triggers the setup wizard.
One additional thing I'll note since you mentioned you're on Oracle - you'll want to use the version 12.2.0.1 driver which you can obtain here from Oracle. The ojdbc8.jar file needs to go into the lib folder in your application install directory, and any older ojdbc8.jar/ojdbc7.jar files should be removed from that directory. Other releases of the Oracle 12c drivers have had various issues working correctly with Jira.
Cheers,
Daniel
Hi @Daniel Eads
If I go for option 1 (dbconfig.xml), will JIRA pick up the DB config and connect itself to oracle instead of hSQL?
We have downloaded and placed an ojdbc8.jar in the lib folder :)
My only fear is will the backed-up data import properly? Will the user accounts & projects be safe?
NB: Our new JIRA-HOME directory doesn't have any file & folders. It is completely empty. It will fill up only upon a restart.
Regards
Aditya
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If I go for option 1 (dbconfig.xml), will JIRA pick up the DB config and connect itself to oracle instead of hSQL?
There will already be a dbconfig.xml file in place that instructs Jira to connect to the h2/hSQL embedded database. If you modify the connection parameters in that file, it won't try to use hSQL anymore.
If that file isn't there, then the configuration wizard will guide you though a database connection when you start Jira. If it's a new empty Oracle database, you should also have the option to import when the wizard runs! Note that Jira will expect to import from an XML file (you would generate this from a running Jira). It won't pick up the data from an old embedded hSQL database automatically. We've got docs for generating the XML backup if that's not the backup you're referring to that you already have.
Jira's home directory contains files like attachments that aren't included in a database backup (like the XML backup). You'll need to copy in these files separately to make sure they are imported.
The users, projects, and issues are in the database/XML backup. The attachments on issues are in the home directory and need to be manually copied in to your new home directory.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.