Kodi Community Forum
[Release] Backup (formerly XBMC Backup) - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Program Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=151)
+---- Thread: [Release] Backup (formerly XBMC Backup) (/showthread.php?tid=129499)



RE: [Release] Backup (formally XBMC Backup) - DruTheFu - 2015-01-14

(2015-01-05, 16:12)robweber Wrote:
(2015-01-05, 01:41)DruTheFu Wrote: Running Backup v1.0.1 on my Amazon Fire TV (Android) "Kodi 14.0 Helix" install. I cannot get to function after configuring. I receive a "Error: Script Failed! Backup" message when trying to run a backup job.

Once I disable the setting to "compress", I get the script to appear to function, but am warned that the write destination to my SMB share is detected ("Write Error Detected"). I proceed, the Add-On runs like it's backing up, I go onto my Windows box and see that the backup directories were created, but all folders are empty.

Please include a debug log. This is most likely due to a file write issue on the network share but the debug log would confirm.

I've finally been able to get the debug file uploaded. (xbmclogs)

Looking in the log, I'm wondering where the option setting is to enter my username and password credentials when mounting the smb directory location...


RE: [Release] Backup (formally XBMC Backup) - robweber - 2015-01-14

(2015-01-13, 22:44)DJLonely Wrote: Hello robweber,
today I have installed Kodi 14 (before I used XBMC 13.2) and I tried to restore the backup I made in XBMC.
First I have received a message that the backup was done in different version of Kodi and then it was running.
However, it didn't restore my movie library.

Is that known bug between the XBMC and Kodi backup/restore, or is it something new?

Thank you in advance for any advice.

It isn't really a bug, just the way Kodi works. When you are restoring from a backup made in an older version of XBMC/Kodi there are a few "tricks". By default when Kodi starts it tries to find a database matching the version it needs. So for Helix say the video database is MyVideo90.db for example. If it can't find it it will look for lower versions, like one from Gotham, and migrate their contents into a new MyVideo90.db file. When you restore from an older version you are putting back, for example, a MyVideo80.db file. Since Kodi already has a MyVideo90.db file it doesn't look at your old one, even after a reboot. What you have to do after the restore is delete the databases with the highest number, forcing Kodi to look at your old database and move all the data after a restart.

Kind of a pain I'm sure, but just restoring the old DB file isn't enough to make Kodi use it. I'm sure the next question is can't this all be done as sort of a cleanup within the addon - yea probably. There are a lot of edge cases where just deleting the highest DB numbers would probably destroy some stuff and get people all ticked off though so it's best left to a user operation at the moment. If someone wanted to tackle this - patches welcome!

(2015-01-13, 23:23)ed_davidson Wrote: I uninstalled the addon, didn't delete the backup folder in the userdata folder. Then I reinstalled the addon and I got the URL auth box and then everything worked.

I have put Kodi on several devices for friends. My question is. Would it be possible for my friends to restore from dropbox using my app folder? If so then I could push out (upload) backups to dropbox and they could then restore with dropbox.
How would this work.

Great addon by the way, have needed to use it lots.

Regards.

The addon isn't designed to use that way but you certainly could - as long as you weren't trying to update something complicated like the guisettings file that takes extra effort to get working. Your friends would need your dropbox secret and key for the developer account and then you'd wan to link it with your account. Note that for the developer account you can only add a few devices without paying for more. That's one of the reasons everyone has to add this themselves and it isn't included with the addon. From there just have them restore once you've created a backup.

As I said - syncing isn't really the goal but if you can get it to work that's great.

(2015-01-14, 02:10)DruTheFu Wrote: I've finally been able to get the debug file uploaded. (xbmclogs)

Looking in the log, I'm wondering where the option setting is to enter my username and password credentials when mounting the smb directory location...

it uses the same syntax Kodi would use when adding a source. Check this page on the wiki http://kodi.wiki/view/List_of_media_source_types#Windows_File_Sharing_.28SMB.2FSAMBA.2FCIFS.29

In short, for an SMB share you need:

Code:
smb://username:password@computername_or_ipaddress/sharename/path



RE: [Release] Backup (formally XBMC Backup) - DruTheFu - 2015-01-14

(2015-01-14, 18:01)robweber Wrote:
(2015-01-14, 02:10)DruTheFu Wrote: I've finally been able to get the debug file uploaded. (xbmclogs)

Looking in the log, I'm wondering where the option setting is to enter my username and password credentials when mounting the smb directory location...

it uses the same syntax Kodi would use when adding a source. Check this page on the wiki http://kodi.wiki/view/List_of_media_source_types#Windows_File_Sharing_.28SMB.2FSAMBA.2FCIFS.29

In short, for an SMB share you need:

Code:
smb://username:password@computername_or_ipaddress/sharename/path

Thanks for the reply robweber!

Where, within Kodi, could I edit/update the SMB mapping and credentials that may have been previously set? I couldnt find this 'user credential' option within Backup either. Should I uninstall the Backup Add-On and reinstall? Sorry for the noob question, but I am unable to locate this configuration option.

Thanks again

EDIT: On second thought, let me try to type in the path including the credentials manually. I'll report back...


RE: [Release] Backup (formally XBMC Backup) - ed_davidson - 2015-01-15

How can I check the log file on a device running mxlinux? I can't close the dialog box and get the URL because the next time I open backup the dropbox link changes.
Any ideas.


RE: [Release] Backup (formally XBMC Backup) - albertocv - 2015-01-16

(2015-01-10, 14:41)spinmaster Wrote:
(2015-01-05, 16:12)robweber Wrote:
(2015-01-04, 23:35)spinmaster Wrote: (...)
Can somebody tell me where that logfile is created (or which log is meant exactly) to pick up that auth url?

The URL is in the main xbmc log file. Looks like you are using OpenElec so something like /storage/.kodi/temp/xbmc.log.

Thanks! I picked up the auth url from the main log - backup to Dropbox works fine now... Smile
Hey, I have the same problem. I looked into the main log but wasn't able to find the auth info. What do i have to look for?


RE: [Release] Backup (formally XBMC Backup) - albertocv - 2015-01-16

(2015-01-16, 12:27)albertocv Wrote:
(2015-01-10, 14:41)spinmaster Wrote:
(2015-01-05, 16:12)robweber Wrote: The URL is in the main xbmc log file. Looks like you are using OpenElec so something like /storage/.kodi/temp/xbmc.log.

Thanks! I picked up the auth url from the main log - backup to Dropbox works fine now... Smile
Hey, I have the same problem. I looked into the main log but wasn't able to find the auth info. What do i have to look for?

Nevermind, I didn't realize that the log was rewritten at every startup. After switching on the device and trying to run the addon I found the URL. Everything's working now!


RE: [Release] Backup (formally XBMC Backup) - robweber - 2015-01-16

(2015-01-14, 18:08)DruTheFu Wrote: EDIT: On second thought, let me try to type in the path including the credentials manually. I'll report back...

That is most likely what you need to do. The example l posted is exactly how the string would appear when typing it out. Kodi is nice when adding sources through the gui in that it just asks you what you need to enter (ie, username/password) and then constructions this url string for you in the background. If you check your sources.xml and have a SMB source with a user/pass that is how it would look.

(2015-01-15, 17:29)ed_davidson Wrote: How can I check the log file on a device running mxlinux? I can't close the dialog box and get the URL because the next time I open backup the dropbox link changes.
Any ideas.

Your best bet is probably to use an SSH session via Putty or something. Just "tail" the log file and wait for the URL to pop up. If you can't do that is there a way to minimize Kodi while it's running and just find it on the filesystem? Sorry for all the trouble it takes to do this, Dropbox is designed for systems where you can pop open a browser window and authorize directly from that. Since Kodi doesn't have a browser this is the best we can do.


RE: [Release] Backup (formally XBMC Backup) - DruTheFu - 2015-01-16

(2015-01-16, 15:58)robweber Wrote:
(2015-01-14, 18:08)DruTheFu Wrote: EDIT: On second thought, let me try to type in the path including the credentials manually. I'll report back...

That is most likely what you need to do. The example l posted is exactly how the string would appear when typing it out. Kodi is nice when adding sources through the gui in that it just asks you what you need to enter (ie, username/password) and then constructions this url string for you in the background. If you check your sources.xml and have a SMB source with a user/pass that is how it would look.

Thank you for the link to the SMB mounting guide. One tidbit of info I did not find in the link is related to spaces in the name/path.

When manually entering the SMB path, how would I handle 'spaces' in the username? For example, let's say my username is on the machine I connect to is 'Dru The Fu'. Would my path then be 'smb://Dru%20The%20Fu:password@computername_or_ipaddress/sharename/path' ? Will Kodi translate the '%20' to a 'space' when navigating to that path?

As a side note, my Kodi install is on an amazon Fire TV, and I'm not certain on how to navigate and read the XML files I see referenced throughout this forum. #NoobProblems

Thank you for your continued help.


RE: [Release] Backup (formally XBMC Backup) - albertocv - 2015-01-17

I have a new problem. The backup process remains stuck at "Copying zip archive" forever.
Yesterday it did the same thing and at a certain point showed a message about a non-writeable folder. Now it's stuck and I am waiting for some change.

What could it be?


RE: [Release] Backup (formally XBMC Backup) - spinmaster - 2015-01-18

(2015-01-17, 12:57)albertocv Wrote: I have a new problem. The backup process remains stuck at "Copying zip archive" forever.

I had the same issue yesterday. Are you backing up to Dropbox? My initial thought was that the upload process to Dropbox just takes very long - but since there is no progress bar for the upload itself (would be could to have that!) nor do I know the filesize of the backup archive (I am using compression), I couldn't verify that. Even worse, when I hit cancel, the dialogue freezes and I have to restart my PC:

Image

(2015-01-17, 12:57)albertocv Wrote: Yesterday it did the same thing and at a certain point showed a message about a non-writeable folder. Now it's stuck and I am waiting for some change.

Also, similar problem here. I did another test today and after a while I had a - what seems to me - permission problem:

Image

I could'nt find anything wrong in my "Kodi Backup App" settings on the Dropbox website for the addon. According to the permission type, the App has write access to its own folder:

Image

Anybody knows what might be the problem?


RE: [Release] Backup (formally XBMC Backup) - robweber - 2015-01-20

(2015-01-17, 12:57)albertocv Wrote: I have a new problem. The backup process remains stuck at "Copying zip archive" forever.
Yesterday it did the same thing and at a certain point showed a message about a non-writeable folder. Now it's stuck and I am waiting for some change.

What could it be?

(2015-01-18, 17:44)spinmaster Wrote: I had the same issue yesterday. Are you backing up to Dropbox? My initial thought was that the upload process to Dropbox just takes very long - but since there is no progress bar for the upload itself (would be could to have that!) nor do I know the filesize of the backup archive (I am using compression), I couldn't verify that. Even worse, when I hit cancel, the dialogue freezes and I have to restart my PC:

Anybody knows what might be the problem?

The non-writeable folder error is just a generic error that is shown when copying the zip file fails. In most cases the failure to write files is due to this. In the dropbox situation it is probably just a failure to upload the file - maybe due to size. The issue you are seeing about the program freezing when trying to cancel out is somewhat normal. Once the copy process starts the thread is pretty much locked, it doesn't do any progress checks and the actual progress of the file copy is unknown. This is because the addon is handing off the copy process to another library and both the xbmcvfs module and the dropbox classes don't have a mechanism for monitoring a file copy.

That all being said I do see there is some sort of chunk uploader utility included in the Dropbox libraries. I might play around with this and see if it has better results copying large files. In general the dropbox python classes are pretty slow.


RE: [Release] Backup (formally XBMC Backup) - ed_davidson - 2015-01-21

I can't get the backup addon to restore from a backup after i do a fresh start using the fresh start addon.
It just does it very quickly and doesnt restore anythin
Any ideas?


RE: [Release] Backup (formally XBMC Backup) - networxguru - 2015-01-21

Hi Rob,

I have been using your great add on for ages butvI cant seem to get back up installed on Gotham anymore. I have a fresh install but cant find it anywhere in the Addonns listins under program add ons. I have downloaded 0.6.0 but Gotham doesnt see it on my USB stick. It sees 1.0.2 but wont install due to dependancies not being met.

Can you help me?


RE: [Release] Backup (formally XBMC Backup) - robweber - 2015-01-21

(2015-01-21, 01:23)ed_davidson Wrote: I can't get the backup addon to restore from a backup after i do a fresh start using the fresh start addon.
It just does it very quickly and doesnt restore anythin
Any ideas?

I would need debug log here. I'm assuming you configured the addon correctly in the settings before attempting a restore - making sure to select the items you actually want restored. If this is an issue with some gui settings just not showing up then I guess I can't help you, the guisettings problem is a well known issue and there are workarounds you'll have to find. The same if you are upgrading from Gotham to Helix and want your video databases and stuff back - there is a method to what you'll have to do and there is some manual work involved.

If either of those aren't the case feel free to post some debug information and I'll see what I can do.

(2015-01-21, 09:20)networxguru Wrote: Hi Rob,

I have been using your great add on for ages butvI cant seem to get back up installed on Gotham anymore. I have a fresh install but cant find it anywhere in the Addonns listins under program add ons. I have downloaded 0.6.0 but Gotham doesnt see it on my USB stick. It sees 1.0.2 but wont install due to dependancies not being met.

Can you help me?

that is odd it is not in the Gotham repo. It should be, I see it on the mirror site where the addons are pulled from. You can download the 0.6.0 version from github under the "Gotham" branch - https://github.com/robweber/xbmcbackup/tree/gotham


RE: [Release] Backup (formally XBMC Backup) - networxguru - 2015-01-22

hi Rob

thanks for that mate, great add on and great support.

worked a treat. This is the one Gotham wouldnt recognise script.xbmcbackup-0.6.0.zip

cheers
NWG