Posts: 1,344
Threads: 99
Joined: Jul 2013
Reputation:
6
I currently maintain MSP on three tablets and I'm adding a fourth one as I write this. This is probably overkill for most users, but I was a beta tester and I still like to try new releases somewhere where it doesn't matter if it all goes tits up.
Now - my backup file is 2+ Gb and it takes quite a while to restore it and this started me wondering about restoring to more than one tablet at a time. I realise there is little to save in terms of time, because it's four times the data to move, but it would be nice to start it running and go and do something more useful while all the tablets did their thing.
I haven't tried this because I think it's doomed to failure at the moment? When you link a tablet to Companion, the first thing it does is to read whatever is currently on the tablet - I can only conjecture what this would do if it was trying to read more than one tablet at a time, but I don't think it would be very pretty .
However, if Companion first asked if you wanted to read the contents of a tablet and you elected not to do so, maybe a restore could be made concurrently to more than one tablet?
I guess only Mike knows the answer to this, but I would like to know if it's a possibility for a future upgrade?
Sometime ago, we talked about incremental/differential backups and Mike did say he would look at implementing them at some unspecified time. Maybe what I am talking about above would be easier to implement?
Posts: 13,539
Threads: 302
Joined: Apr 2012
Reputation:
241
The companion is definitely not designed in a way that would support multiple concurrent tablet connections. While I could change the connection code to support this, the rest of the app definitely isn't set up in a way where you could switch what tablet you are currently looking at. I know you are only thinking of things in term of restoring backups, but I can't really just isolate that one piece when supporting the concept of multiple concurrent connections.
Another possibility would be to modify the companion and tablet to be able to change the port numbers used for the connection. You could then load up multiple companion applications where each one is connected to a different device. In order for this to work well, I'd probably want to add support for specifying the port numbers on the command line so you could load different shortcuts for different devices (so you wouldn't have to change the port numbers each time). I could see some potential problems I'd need to consider (ensuring that I don't lock read access to the backup file while restoring it for example), but I'm sure I could work through those during testing.
If you have enough space on your device, you could also upload the backup file to Dropbox or Google Drive and just restore it from there on each of the devices, but that might wind up slower...
If I recall, the incremental backup feature was more about backing up new information to an existing backup file. The restore of the backup would still be the same though. I hadn't really considered supporting some form of incremental restore. If I moved away from the idea of keeping the backup data all in one file, I guess I could generate an additional file for each incremental backup where that backup file contained only the database file and files that were added since the last backup (calculating the delta between the current library and the backup file is the hard part). I could then in theory allowing restoring of just those incremental pieces which would meet your needs. As long as I linked together the first backup files to all the others, doing a restore wouldn't be too bad, although I could imagine if you started to have a lot of incremental backups, managing all of those files might get troublesome really fast.
I'm a little tired so I think my thoughts are a little jumbled. I'll have to think more on all of this. One other thing for you to consider: I'm not sure how many computers/laptops you have in your home, but each one could be responsible for restoring the backup to one tablet. You can also use VMs with a free application like VirtualBox so that each VM could be restoring to one tablet. If you store the backup file in a shared area (either shared network storage or a shared folder on your PC), I could see that working.
Mike
Posts: 1,344
Threads: 99
Joined: Jul 2013
Reputation:
6
Mike, thanks for the quick response. You're right, the initial discussion about incremental backups was nothing to do with restoring a backup to the tablet/s, merely to speed up making the backup.
This all sounds like a lot of additional work for you, with not a lot of gain for the users. I'm probably an unusual case anyway, I doubt many other users are doing quite what I do. Unless you think it really worth the effort, then I'm happy for you to forget all about it.
I tried the Dropbox route, but it is slower. It also eats up my data allowance (I have a satellite link and it's restricted to 25Gb per month).
This house is full of computers!! Three desktop PC's, two laptops and four Android tablets (plus another one that I need to repair) - and there's only two of us here . Other than one of the desktops, which is used for music production and deliberately has no net access whatsoever, all are networked together. I'll have a think about your alternative suggestion.
Posts: 1,049
Threads: 112
Joined: Dec 2015
Reputation:
12
Well, I doubt I will maintain my sheets on more than two devices (tablet and smartphone and I expect to use the smartphone in very unprepared cases I'm without a tablet anyway).
But I won't backup my data with the backup function since for my use the backups get to big and take too long. Maybe your interested in my way:
I don't let MSP maintain the sheets and have my own structured folder with the sheets on the SD card.
I keep a mirror of this on my PC and also on the SD card on my phone.
I also have a separate dir in my sheets dir on the SD Card into which I copy the database files from the Android system folder. I update these system files occasionally if there have been changes in my MSP database.
For a complete backup I just use a comparison/sync program to sync my sheets folder on the tablet/smartphone and the folder on the PC. This is like an incremental backup for me and I can mirror/backup my sheets and MSP files with the least amount of time and data transfer.
As long as Mike doesn't introduce more settings that aren't saved or copied with the "system files" this should be a safe backup method as well. Right Mike?
Posts: 1,344
Threads: 99
Joined: Jul 2013
Reputation:
6
Interesting approach - I'll look into it a little more and check it would be OK with my workflow.
Posts: 1,234
Threads: 194
Joined: May 2015
Reputation:
13
If the Dropbox approach works, but consumes your network allowance a local cloud server (e.g., ownCloud) could be worth considering.
Johan
johanvromans.nl — hetgeluidvanseptember.nl — mojore.nl -- howsagoin.nl
Samsung Galaxy Note S7FE (T733) 12.4", Android 13.0, AirTurn Duo & Digit (Gigs).
Samsung Galaxy Note S4 (T830) 10.5", Android 10.0 (maintenance and backup).
Samsung A3 (A320FL), Android 8.0.0 (emergency).
Posts: 1,049
Threads: 112
Joined: Dec 2015
Reputation:
12
03-04-2016, 01:40 AM
(This post was last modified: 03-04-2016, 01:40 AM by BRX.)
It's probably obvious to you, but I forgot to add: For a (complete) restore you'd have to sync the PC to the devices *and* then copy back the system files from the SD card back to the system dirs on the device (with the filemanager of your choice).
Posts: 13,539
Threads: 302
Joined: Apr 2012
Reputation:
241
BRX - yes, that's a safe way to backup as long as you expose the database file so that it's backed up as well. The one thing you don't save that way are the application settings, as those files are not exposed in any way.
Posts: 1,234
Threads: 194
Joined: May 2015
Reputation:
13
Maybe it would help to have a "backup/restore settings only"?
Johan
johanvromans.nl — hetgeluidvanseptember.nl — mojore.nl -- howsagoin.nl
Samsung Galaxy Note S7FE (T733) 12.4", Android 13.0, AirTurn Duo & Digit (Gigs).
Samsung Galaxy Note S4 (T830) 10.5", Android 10.0 (maintenance and backup).
Samsung A3 (A320FL), Android 8.0.0 (emergency).
Posts: 13,539
Threads: 302
Joined: Apr 2012
Reputation:
241
If people care, I could create a different option to archive/restore the settings through a different mechanism. I don't want to give people the option to create backup files that may be missing their song files and/or database file. I know for a fact people will shoot themselves in the foot if I do that, so I think it's best to not make that optional.
Mike
Posts: 1,234
Threads: 194
Joined: May 2015
Reputation:
13
You are right, as usual.
But a way to save and restore the settings would be nice!
Johan
johanvromans.nl — hetgeluidvanseptember.nl — mojore.nl -- howsagoin.nl
Samsung Galaxy Note S7FE (T733) 12.4", Android 13.0, AirTurn Duo & Digit (Gigs).
Samsung Galaxy Note S4 (T830) 10.5", Android 10.0 (maintenance and backup).
Samsung A3 (A320FL), Android 8.0.0 (emergency).
Posts: 13,539
Threads: 302
Joined: Apr 2012
Reputation:
241
I'll create an enhancement request for that so it's captured. Hopefully once I've knocked off some of the bigger tasks I can work on some of the lower priority tasks like that.
Thanks,
Mike
Posts: 1,903
Threads: 296
Joined: Sep 2014
Reputation:
33
Great. Synchronizing the song files, copying the database and maintaining separate settings for everyt tablet would be a perfect solution for a situation like Graeme's.
|