Backup and Restore XBMC (Kodi) With XBMC Backup Add-on

Backup and Restore XBMC (Kodi) With XBMC Backup AddonThis is a quick tutorial on how to backup and restore XBMC (Kodi) with XBMC Backup Add-on. The XBMC backup add-on is a great add-on that will grab your userdata and roaming XBMC (Kodi) folder and log them in a folder of your choice ALL from within the XBMC (Kodi) UI. You can also use this process to backup your XBMC (Kodi) install and migrate it to another machine. As an alternative to this or if you simply want to understand what is being backed up and restored you can check out my post on migrating XBMC settings and install to a new Windows machine.

This is extremely simple, but some may have issues, some may not have heard of this and others will want to know recommended settings. Also, if you have customized system files such as for Weather Underground API then it will be overwritten when restoring via an add-on.

How to Install XBMC Backup Add-on
How to Configure XBMC Backup Add-On for Local Backups
How to Configure XBMC Backup Add-On for Dropbox Backups
How to Configure XBMC Backup Add-On for Network Drive Backups
Backup and Restore XBMC (Kodi) With XBMC Backup Add-on

How to Install XBMC Backup Add-on

Fortunately, the XBMC Backup add-on is found within a default repository, so installation is simple:

  1. Settings
  2. Add-ons
  3. Get Add-ons
  4. XBMC.org Add-ons
  5. Program Add-ons
  6. XBMC Backup
  7. Install:

Install XBMC Backup Addon

How to Configure XBMC Backup Add-On for Local Backups

I personally keep this local because I back my machines up to a NAS and my install is 1.5 gb. I do not pay for DropBox.

  1. Settings
  2. Add-ons
  3. Enabled Add-ons
  4. Program Addons
  5. XBMC Backup
  6. Configure

^ if you have the shortcut enabled, and you should at some point, ignore the above. My recommended specs for this setup are below:

  • On General Tab
  • Remote path type = Browse Path
  • Browse Remote Path = Wherever you’d like – create a folder for this purpose
  • Check Compress Archives for storage purposes (this will zip all but your latest backup – do not check if you don’t have a tool to unzip files)
  • Backups to keep = 10 (Leave on 0 if you want all backups and have the storage)
  • File Selection Tab
  • Check Addon Data
  • Leave all else default in most cases
  • Scheduling Tab
  • Check enable scheduler
  • Settings as you see fit, but make sure you have the storage if you’re keeping all backups

XBMC Backup Addon Settings

How to Configure XBMC Backup Add-On for Dropbox Backups

  1. Create API Key. Go to the developer page on Dropbox.
  2. Log in if not already
  3. “Create an App” in the top right
  4. “Dropbox API App”
  5. Files and datastores
  6. Yes – my app only needs access to files it creates
  7. Name it anything
  8. Create appBackup XBMC to Dropbox
  9. Leave this next page open and note your App Secret, App Key and Folder created for the app:Dropbox Kodi Backup
  10. Back to XBMC (Kodi)
  11. Settings > Addons > Enabled Addons > Program Addons > XBMC Backup > Configure
  12. General Tab
  13. Remote Path Type = Dropbox
  14. Dropbox key = Paste your unique key from Dropbox
  15. Dropbox Secret = Paste your unique secret from Dropbox
  16. As Alberto pointed out, we’ll still need to authorize our DB app.
  17. Launch the XBMC/Kodi backup program and you’ll see a message “Check log for Dropbox authorize URL….” Do NOT click “OK” just yet:

    Backup Kodi with Dropbox

  18. Minimize Kodi/XBMC or hit “\” to put it into windowed mode. Make sure that you can view hidden files on your Windows machine and open your log file in a text editor found at the below path:

    C:\Users\Trevor\AppData\Roaming\Kodi\kodi.log

    Note that “Trevor” is your username and if you’re running XBMC 13.2 or below just swap out “Kodi” with “XBMC”

  19. Once this file is open hit ctr+f and search for “script.xbmcbackup-1.0.2: Authorize” – no quotes. Copy this URL from the log file:

    Kodi Backup to Drop Box

    *Note the time stamp. If you’ve tried this multiple times look for the latest URL as the others will return expired warnings

  20. Open your browser for which you’re logged into Dropbox and paste this URL in the web address bar.
  21. Click “Allow” on the following prompt:

    Kodi Backup with Dropbox

  22. Return to XBMC/Kodi and hit “OK” on the message.
  23. Use additional settings from previous section and you’re done

How to Configure XBMC Backup Add-On for Network Drive Backups

Do you know your SMB address? Skip to step 5.

  1. Grab your SMB location
  2. Windows Explorer
  3. Click your drive
  4. Right click path and copy as plain text (note you’ll need to format later)
    Backup XBMC to Network Drive
  5. XBMC/Kodi > Settings > Addons > Enabled Addons > Program Addons > XBMC Backup > Configure
  6. General Tab
  7. Remote Path Type =  Type Path
  8. Type your path in this format – SMB://TREVORNAS/folder
  9. Use additional settings from local backup section and you’re done.

Backup and Restore XBMC (Kodi) With XBMC Backup Add-on

Now that it’s installed and configured we’re going to backup and restore. If you’re restoring an older version of XBMC to an updated version it should work the same, though, some add-ons and other misc. items may not be compatible.

Backup XBMC (Kodi):

  1. Programs
  2. XBMC Backup
  3. Backup (if you don’t have a backup already – this manually runs)

Restore XBMC (Kodi) from XBMC Backup Add-on File:

  1. Programs
  2. XBMC Backup
  3. Restore
  4. Select the backup you want to restore
  5. Click “Yes” on restore advanced settings file first
  6. Restart XBMC

That’s it. That’s how you backup and restore XBMC (Kodi) with XBMC Backup Add-on.

You may also like...

42 Responses

  1. Alberto says:

    Hi, thanks for the post, really useful. After configuring Dropbox, though, I have a problem. If I run a backup, it asks to specify a URL. what should I do?

  2. Marcos says:

    Hello! I have a problem. I do all that you in this tutorial say for Dropbox. When I try to open in my browser the URL that I take from kodi.log Dropbox say: “The request to link the application ist not valid”. What is the problem?

  3. Marcos says:

    Hello. I have a problem. I do all you say but I can’t do the backup. I use Dropbox but when I have to copy in my browser the URL from kodi.log dropbox not find the website and say an error. What can I do?

    • Trevor Ayers says:

      This means that you initiated the link more than once from within Kodi/XBMC. When you initiate a new link the older ones will be invalidated and return the warning. Initiate the link again and check your log; there are time stamps next to each item. Make sure that you grab the most recent link.

  4. Chris says:

    Hi,

    I’m trying to copy my Kodi settings from one m8 box to another.

    I’ve done the backup but when I come to restore on the new device, I get an empty black box titled ‘ Backup – Backup Folder Name’.

    The correct file path has been entered but it does not see the backup from previous box?

    Any ideas?

    • Trevor Ayers says:

      With the correct path it should find and restore. You could try unzipping your backup prior to trying to restore from within Kodi. The backup plugin is not the only solution. You could copy your appdata folder and paste it on your new M8, which is the manual approach for what the backup plugin does. As a one-off it should work as well.

  5. amrk says:

    Thanks for your tutorial. What about if I am running my Pi from flash drive? Is any way to use this method for back up? Thanks in advance

    • Trevor Ayers says:

      I don’t have a Pi to play with, but it should work the same. In the configuration set a storage area on your USB drive for the backup file. If you want to use the Dropbox method you will need to find your app data folder. I don’t know the path to share. You could enable debug log in Kodi and look for the path there.

  6. amrk says:

    I have chosen custom location. Disabled all other folders and still getting scrip failed:
    – NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
    Error Type:
    Error Contents: Error connecting to “api.dropbox.com”: [Errno 1] _ssl.c:504: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
    Traceback (most recent call last):
    File “/storage/.kodi/addons/script.xbmcbackup/default.py”, line 37, in
    backup = XbmcBackup()
    File “/storage/.kodi/addons/script.xbmcbackup/resources/lib/backup.py”, line 44, in __init__
    self.configureRemote()
    File “/storage/.kodi/addons/script.xbmcbackup/resources/lib/backup.py”, line 57, in configureRemote
    self.remote_vfs = DropboxFileSystem(“/”)
    File “/storage/.kodi/addons/script.xbmcbackup/resources/lib/vfs.py”, line 122, in __init__
    self.setup()
    File “/storage/.kodi/addons/script.xbmcbackup/resources/lib/vfs.py”, line 134, in setup
    token = sess.obtain_request_token()
    File “/storage/.kodi/addons/script.xbmcbackup/resources/lib/dropbox/session.py”, line 176, in obtain_request_token
    response = self.rest_client.POST(url, headers=headers, params=params, raw_response=True)
    File “/storage/.kodi/addons/script.xbmcbackup/resources/lib/dropbox/rest.py”, line 260, in POST
    return cls.IMPL.POST(*n, **kw)
    File “/storage/.kodi/addons/script.xbmcbackup/resources/lib/dropbox/rest.py”, line 207, in POST
    post_params=params, headers=headers, raw_response=raw_response)
    File “/storage/.kodi/addons/script.xbmcbackup/resources/lib/dropbox/rest.py”, line 177, in request
    raise RESTSocketError(host, e)
    RESTSocketError: Error connecting to “api.dropbox.com”: [Errno 1] _ssl.c:504: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
    –>End of Python script error report<–

    • Trevor Ayers says:

      Okay, so you’re trying to backup to Dropbox. The paths look right. At what step do you start seeing this error? After you enter your key and app secret are you getting the “check dropbox log” message to validate the API or is this when it’s shooting the error? I don’t have a Pi, but this should work.

    • Trevor Ayers says:

      Try unchecking “compress archives” if you haven’t already.

  7. amrk says:

    So compress archives cannot be used?

    I am playing with this program now on Amazon Fire Stick and getting error. But I also noticed that compress archives is checked.

    If that could be the reason I will check one more time without this option checked.

    Thanks

  8. Dave says:

    amrk
    The reason you are getting this error is because when creating the app you have not highlighted “Files and Datastores”

    Instead you have left it on the default “Datastores Only” Option

    Create a new dropbox app from step one & make sure you check the “Files And Datastores” option pal.

    Good luck

  9. John says:

    My M8 box is not working properly, so I made a backup of my MXQ box on an SD card. I want to restore it to my M8 box. But when I open USB SDCard Wizard, & click on restore, I don’t get the Full restore option. When I click on restore it flashes up to the little dots.

  10. John says:

    OK, I’ve pretty much got it figured that for some reason I’m not backing up to SD card, When I go to USB SD Wizard, Configure, It shows External Storage, but when I click on External Storage it should show SD Card & then click OK. but when I click on External Storage my SD card doesn’t show up there, so of course no backup.

    • Trevor Ayers says:

      In Confluence

      System > File Manager > Add Source > Browse > Choose Your Drive (SD Card)

      • John says:

        Thank you so much..
        I have one other small problem.. On my M8S box, Video Shortcuts. I have 7 icons, 1 Channel, Project Free TV, Robin Hood, Phoenix, Genesis, Ice Films etc. For some reason the picture of Genesis & Ice Films disappeared. The printing of both are still there, & I can open both. I would like to get the pictures of both back if possible… Don’t know how they got wiped off. I tried to un-install Genesis, then re-install, but that didn’t work. Help will be much appreciated..

  11. John says:

    Thanks Trevor it didn’t work. I followed his instructions to where I got to the file I was supposed to delete. But when I clicked on it I don’t get a menu with option to delete.

    I went to System, get add ons, & uninstalled both Genesis & Ice Films, then reinstalled them both. The pictures (thumbnails) show beside both of them. So I shut down & re-opened Kodi & still no pictures under Video only the printing. I can click on them & open both.. I went to Add Ons under Video, & both Genesis & Ice Films show a blue jig saw puzzle where their pictures should be.. Got me puzzled, pun intended.

  12. Kondratev says:

    HI, i have the same problem,, i when i hit restore it just comes to a blank box.. i know i have done the right directory.. and it is no zipped. any ideas.

    thank you

    • Trevor Ayers says:

      I can only troubleshoot without seeing your Kodi.log. First, make sure that you have a working backup this program can read. The folder name should be year/month/day/time without spaces. for example, a backup on Feb, 2015 at 5:04 pm would be 201502221704. Within this folder you should see two folders and one file named xbmcbackup.val. The folders are userdata and addon. Without all of this aligning, the program won’t see the backup.

  13. Louis says:

    I did a back up using USB SD card wizard everything went fine and now I want to do a restore and the USB SD card wizard can’t find the backup. What I’m I doing wrong?

    • Trevor Ayers says:

      The USB wizard shouldn’t have anything to do with the process. Please double-check your paths. Also, look at my comment to Kondratev today that will help you analyze if the backup worked; meaning, if you have a backup file the addon can restore.

  14. Tom says:

    Hello Trevor. Excellent tutorial. I used the written tutorial with the YouTube video you made. I followed your tutorial on how to backup using Dropbox. The instruction were EXACT. I now have an APP created with a test backup of Kodi from my laptop. When I tried to restore the backup to an android device, using the same App Key and App Secret, the pop up “Check Log for Dropbox authorize URL” came. Is it possible to restore from Dropbox to another device? If so, is there a how to link? Thank you for the AWESOME tutorial.

    • Trevor Ayers says:

      Thanks for the feedback! You need to authorize each device. I don’t have a tutorial because I don’t have an Android or Fire device to play with. The authorization would go the same – grab the URL from your log and paste in a browser on any machine to authorize. Check out the below link for a path to the Kodi log on Android device:

      http://kodi.wiki/view/Log_file/Advanced

  15. John says:

    Hi I’ve got problems with backup on my galaxy S5 running lollipop… I can backup to internal storage fine but not to external sd … get message warning me that files may not be able to be written and get pop up after backup saying not all files were written (or something like that…) As I said works fine on internal storage… but I have limited space… have not zipped files…

  16. Dave says:

    Hello Trevor,

    Is there a way to backup from my amazon fire tv stick to dropbox? Also can I restore to a nee fire tv stick from that same backup stored in dropbox?

    Dave

  17. lee says:

    hi I did a custom build on my m8s android box using aeon nox I used usb sd wizard and did a backup to a usb stick I try to restore on my other m8s box and get addon structure not correct error any ideas how to fix any help appreciated thanks

    • Trevor Ayers says:

      Have you double-checked your paths? Are you using a zipped backup? You could try a backup not compressed. Also, make sure you have all the files in the same folder on your SD card.

  18. Tuc says:

    Well, there seems to be no URL in the logfile anymore nor a popup saying that there is a url in the logfile. The version1 API for doprbox isnt there anymore, wehere i could select Datastore+Files.
    How can the activationurl be received? On the other hand dropbox allows me to generate a accesstoken myself, but i see to way to enter this to the addon.

  19. bryan says:

    Hello when I use the backup feature I make sure all correct paths and instructions have been made but I get a error message the destination may not be writeable( would I like to continue)? And when I continue there is no backup file

  20. Paige says:

    Hi Trevor,
    I was trying to backup kodi on an apple tv 4 box following your outline. I’ve gotten as far as setting up the dropbox account and I’ve gone through creating the API app as far as I can get without help. I do not know how to find where the kodi log would be in the box to authorize or show hidden files (steps 18-21). Any help would be appreciated. Thanks!

Leave a Reply

Your email address will not be published. Required fields are marked *