Backup and restore using ubports-installer
-
Hi all, I'm doing some modifications to the ubports-installer in order to be able to manage user and system data backup and restore.
I have added a backup button on the install screen :
When you click on it you will have the following screen :
The installer will read the size of both system and userdata partition and give you an estimated sized need on your disk. You can name your backup. When you will click ok let's go, the phone will reboot into recovery and the backup will start :
At this and the phone will reboot into the OS. you will be able to find 2 tar file on your computer disk : one for the system-data, the other one for the user-data.
It is actually working fine on Meizu Pro 5.
BUT, in one of my previous thread, I had the issue that in recovery image, the user and system data partition was not mounted on /data.In the installer code, I added for the Meizu Pro 5 the mounting of sda44 on /data/
So my questions to you are :
- Who else on different phone models have the partition /data/user-data, /data/system-data not mounted in recovery ? If that is the case, what is your partition device to mount ?
- does every one have the folder user-data and system-data in the /data folder while in recovery ?
- Are you ok with this feature or do you find it usless ?
I will now write the restore option.
-
@AlainW94 This looks great, will try later. Thanks
-
I find it very userul! Thank you! And a question: can this be used to migrate data from one phone to another, maybe even between different types of UT phones?
-
@mihael Thanks ! I already use this method to backup a Meizu Pro5 to another Meizu Pro5, but I can't try it with a different model as I didn't have other model.
I don't know if a system backup can work on a different phone model. -
@Lakotaubp Thanks !
-
Great work! Thanks @AlainW94
-
Thanks @3arn0wl !
-
@AlainW94 Is this available now for all models, it's not showing yet for OPO on 0.4.11 beta
-
HI,
An this backup option will accept any phone in its factory setting ? -
@Lakotaubp Not yet, I have to cleanup my code before to push it, and I only tried it on Meuzu Pro 5
-
@lool_lauris Only working with UbPorts phones, I tried it with a Meizu Pro5 on Android and it's not working.
-
@AlainW94 said in Backup and restore using ubports-installer:
@lool_lauris Only working with UbPorts phones, I tried it with a Meizu Pro5 on Android and it's not working.
When I was asking about any phone, I was meaning the available phones for UT, of course.
-
@lool_lauris And this is also why I asked if everybody had the folders "user-data" and "system-data" on their devices while in recovery mode, because this folder will be the one to be backing up.
-
@AlainW94 My fault being to keen and not reading properly. Will check other stuff.
-
Does this work while the phone is booted normally or in recovery/bootloader mode?
Looks cool, has it been merged already? -
@kugiigi It will work only on recovery, because it need to read or write system data. It is not merged yet, I will do it asap.
-
@AlainW94 It writes? may I know for what?
Anyway, I just thought I can use it for backing up/restoring my MultiROM UT installs
Good luck with this -
@kugiigi Backup AND RESTORE so yes, write
-
@kugiigi Yes it write if you restore a backup ! The backup tool will backup the content of 2 folders : /data/user-data and /data/system-data.
If you open a shell on the recovery, and typels /data
And if you can see in there the previouly named folders, then the backup tool will be able to backup this file on your multirom device.
-
Of course, restoring will write data....what a stupid question from me
I'll check this functionality once it's merged in the app.
Thanks.