Hello,
I am in the process of updating our Atlassian Jira backup script to use the new download URL, per this post here: https://confluence.atlassian.com/jirakb/removal-of-webdav-directory-support-for-jira-cloud-instances-859477758.html
After going through the individual commands of the script, I eventually arrive at the following when I run a Curl call to get the status of the backup:
roger@ubuntu16 ~ $ curl --silent --show-error --cookie $COOKIE_FILE_LOCATION --request GET --url https://${INSTANCE}/rest/obm/latest/getprogress.json | python -m json.tool { "alternativePercentage": "Estimated progress: 100 %", "concurrentBackupInProgress": false, "currentStatus": "Preparing export file", "fileName": "/plugins/servlet/ondemandbackupmanager/download/5c54d4af-7447-4478-81f4-3ed838669c13/jira_export_20170111_123723.zip", "size": 26233530 }
However, when I try and download that file, I get a "401 unauthorized". This happens in the browser as well. Also note that the "currentStatus" of "Preparing export file" seems to be stuck and never changes.
roger@ubuntu16 ~ $ sudo wget --load-cookies=$COOKIE_FILE_LOCATION -t 0 --retry-connrefused "https://${INSTANCE}/$FILE_NAME" -O "$LOCATION/JIRA-backup-${today}.zip" --2017-01-11 12:44:02-- https://intacctops.atlassian.net//plugins/servlet/ondemandbackupmanager/download/5c54d4af-7447-4478-81f4-3ed838669c13/jira_export_20170111_123723.zip Resolving intacctops.atlassian.net... 165.254.227.2 Connecting to intacctops.atlassian.net|165.254.227.2|:443... connected. HTTP request sent, awaiting response... 401 Unauthorized Authorization failed.
Has anyone experienced this issue? Atlassian support does not seem to know what to make of this issue, either.
The old site where I used to download from Webdav no longer works, as noted in the link earlier in this post.
Thanks,
Philip
OK I figured it out. There was a flaw in the script that Atlassian provides.
I used --location with Curl and it worked.
Here is a snippet of what could be revised in their script.
if [[ $FILE_NAME == *"ondemandbackupmanager/download"* ]]; then # Download the new way, starting Nov 2016 curl --silent --show-error \ --location \ --cookie $COOKIE_FILE_LOCATION \ --request GET \ --url "https://${INSTANCE}${FILE_NAME}" \ --output "${LOCATION}/${RENAME_BACKUP_FILE}"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.