restoring jira from mysql dump: no issues imported

Eck Support May 1, 2013

Hi,

I am testing a restore from jira and it's mysql databases on a new server. Therefore i've made an sqldump and a tarball from the jira /data directory (with attachements and avatars).

On the new system with latest jira and mysql installed and running I imported the sql databases with common mysql commands. After that i copied the /data dir to the new machine and changed the rights for jira user.

After jira restart everything works, projects an Avatars/Attachements are there. BUT: most of the issues are gone (80% in one project and 100% in 3 other projects)! why does this happen? Are all data and settings stored in the database or do i have to backup jira-HOME either?

4 answers

1 accepted

8 votes
Answer accepted
darylchuah
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 1, 2013

Hi Elias

I guess you would need to perform a full reindexing first since you are restoring the database dump directly into JIRA.

Hopefully it helps!
Cheers:)

Yasith Tharindu April 25, 2016

Thanks for the info. Yep this is the correct resolution after a native DB restore.

1 vote
richie_gee
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 1, 2013

Hi Elias,

This seems very unique case you have there and it might take a while to really diagnose whether what is causing this, I would like recommend you to migrate using the following steps to avoid similar problem

  1. Create xml backup instead of sql dump
  2. Backup your JIRA home directory and transfer it to the new machine
  3. Create an empty database on the new machine
  4. Install JIRA setting your home directory to the transferred home directory
  5. Connect JIRA to your empty database
  6. Start JIRA
  7. XML import (Restore System)

It is a new setup, and in my opinion, it is better to perform the upgrade in a problem free method rather than spending too much time on troubleshooting.

Hope this gives an idea to you, cheers :)

0 votes
d_jeffbethune June 18, 2018

I am hoping to get some clarification on this topic, and did not want to start a new thread:

1) I am setting up Jira + Confluence and testing out the production backup, as recommended by many of the Atlassian articles (MySQL dump + copied home dir.).

2) I am a bit confused on when it is recommended to use XML dumps and when not to. It seems the recommendation for production servers is to not use XML, however the Restoring from other Backups page uses language that makes it sound out of the ordinary to use native DB tools to restore Confluence or Jira. Further, posts in this thread seem to suggest XML is the best way to backup/restore.

3) I am testing for disaster recovery, so really I just want to make sure whatever I use works. XML sounds like it eats up memory and CPU, so I would prefer restoring from the DB.

Question:

If DB backup tools are preferred for backing up the database, what is the preferred procedure for restoring an instance (scenario: disaster recovery)?

Thanks for the clarification

EDIT: See this thread as well restoring Jira. While the language doesn't make it clear, it appears this is the preferred method on restoring Jira and Confluence.

0 votes
Eck Support May 1, 2013

hi guys,

I just performed a full reindexing AFTER import of the sql databases. Now everything is working.

In atlassian docs XML backup is not recommended for production use (slow, no transaction security due to no db locking) so the decision was mysql dump.

darylchuah
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 1, 2013

Glad to hear that everything is working fine for you right now :)

Please accept the answer if you found it useful :p

shery fletcher July 16, 2016

Hi I have used this method and it`s worked perfectly

Suggest an answer

Log in or Sign up to answer