Restoring data from a (native database) daily-backup

Kevin Mote
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 27, 2014

I am trying to test that my native database backup tool is working. I followed these steps:

  1. made a backup of my jiradb using SQL Server, (using SQLServer Mgt Studio)
  2. transferred it to my test server,
  3. restored the jiradb from the backup, (using SSMS)
  4. confirmed from SSMS that the jiradb on the test server looks ok.
  5. I then used /bin/config.bat to confirm that JIRA on my test server is pointed at jiradb (as instructed here)

But when I launch Jira, it acts like there is no database and displays the "JIRA Setup" window. From there it asks if I have "existing data", and if I click that link it asks for the path to the xml backup file. (I didn't make one).

The Help documentation only explains how to restore from an xml backup (even though another page strongly recommends that native db backup tools are used. But I can't find any documentation for restoring the database on the new server from the DB backup file.

3 answers

1 vote
Liam Jones January 27, 2014

Kevin, you'll need to copy your application 'Home' directory as well as the DB content. Among other things (like attachment binaries), the application data directory contains a config file telling JIRA what DB connection details to use.

Kevin Mote
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 27, 2014

I'm pretty sure I already had the config file -- which is why step 6 worked. But I hadn't thought about the attachments, etc. Thanks

1 vote
Steve Thornhill
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 27, 2014

Might be worth trying this... If your test server did not have an active database before, let the JIRA setup run through that process, then stop the server and perform the database restore.

Restart JIRA after this and you should see your data. Ensure that any plugins, etc are added to JIRA before the restore, just in case.

Kevin Mote
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 27, 2014

Well, I can't test your suggestion now, because I gave up and went with the xml backup (which worked fine, btw). But the next time I want to port my production version over to the test server, I'll give you suggestion a try. Thanks.

0 votes
Kevin Mote
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 27, 2014

[I get a 405 Not Allowed when I try to edit my own question. Here's the updated version]

I am trying to test that my native database backup tool is working (as strongly advised at the end of step 2 on this page). I followed these steps:

  1. made a backup of my jiradb using SQL Server, (using SQLServer Mgt Studio)
  2. transferred it to my test server,
  3. stopped jira service on test seraver
  4. restored the jiradb from the backup, (using SSMS)
  5. confirmed from SSMS that the jiradb on the test server looks ok.
  6. I then used /bin/config.bat to confirm that JIRA on my test server is pointed at jiradb (as instructed here), and tested connection
  7. restarted jira service

But when I open Jira in a browser, it acts like there is no database and displays the "JIRA Setup" window. From there it asks if I have "existing data", and if I click that link it asks for the path to the xml backup file. (I didn't make one).

The Help documentation only explains how to restore from an xml backup (even though another page strongly recommends that native db backup tools are used. But I can't find any documentation for restoring the database on the new server from the DB backup file.

Suggest an answer

Log in or Sign up to answer