Automation script to restore Jira data xml backup

Suresh Bhandiwad September 17, 2018

Hello Team,

I need a help with automation script to restore Jira xml data backup on Jira server. We have a requirement to have Jira cloud backup and restore on Jira server for internal purpose. We are now successful in automating the Jira cloud backup using bash script on Linux server. We are now able to restore the data Manually without any issue: https://confluence.atlassian.com/adminjiraserver071/restoring-data-from-an-xml-backup-802592998.html

We would like to automate this one using bash script as Jira application is running on Linux server. Can anyone help me with the script to automate it or a link which would redirect me towards the script would be great?

Note: Restore backup without attachments.

Thanks in advance!

Thanks,
Suresh

1 answer

1 accepted

0 votes
Answer accepted
Keri
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 20, 2018

Hi Suresh, 

 

The following post has a suggestion for restoring: 

https://community.atlassian.com/t5/Answers-Developer-Questions/Restore-Jira-XML-via-bash/qaq-p/489299

 

As per the post, since there isn't a REST API endpoint specifically for restoring you'd need to authenticate to retrieve the cookie and token and then hit the following URL: 

https://<BASE URL>/secure/admin/XmlRestore.jspa?filename=<FULL PATH TO FILE>&atl_token=<TOKEN>

 

Let us know how it goes - and please update the post if you get this working to help others who may be looking for something similar! 

 

Cheers, 

Keri

Nijas Rawther November 17, 2022

@Keri Is there an automated way to restore a backup with both database files and attachments ?


Thanks in advance.

Suggest an answer

Log in or Sign up to answer