0

I bought second Asus ZS570KL as backup phone since my old one starts to do... weird things. I created full backup using:

./adb backup -apk -all -obb -shared -v -f /backups/phone8.ab

And later performed

./adb restore /backups/phone8.ab

But it only restored files. When I checked out adb logcat -b system I noticed:

04-06 22:29:45.596 10100 10256 W DefContainer: Failed to parse package at /data/cache/backup_stage/pl.m4x.sphinx_customer_android_mobile_app_v2: android.content.pm.PackageParser$PackageParserException: Failed to parse /data/cache/backup_stage/pl.m4x.sphinx_customer_android_mobile_app_v2
04-06 22:29:45.617  2214 10078 D BackupManagerService: [discarding file content]
04-06 22:29:45.624  2214 10078 I chatty  : uid=1000(system) adb-restore identical 52 lines
04-06 22:29:45.624  2214 10078 D BackupManagerService: [discarding file content]
04-06 22:29:45.625  2214 10078 I BackupManagerService: Package pl.neptis.yanosik.mobi.android not installed; requiring apk in dataset
04-06 22:29:45.625  2214 10078 D BackupManagerService: APK file; installing
04-06 22:29:45.625  2214 10078 D BackupManagerService: Installing from backup: pl.neptis.yanosik.mobi.android
04-06 22:29:49.671 10100 10256 W DefContainer: Failed to parse package at /data/cache/backup_stage/pl.neptis.yanosik.mobi.android: android.content.pm.PackageParser$PackageParserException: Failed to parse /data/cache/backup_stage/pl.neptis.yanosik.mobi.android
04-06 22:29:49.699  2214 10078 D BackupManagerService: [discarding file content]
04-06 22:29:49.805  2214 10078 I chatty  : uid=1000(system) adb-restore identical 100 lines
04-06 22:29:49.805  2214 10078 D BackupManagerService: [discarding file content]
04-06 22:29:49.805  2214 10078 I BackupManagerService: Package ru.dront78.pulsedroid not installed; requiring apk in dataset
04-06 22:29:49.805  2214 10078 D BackupManagerService: APK file; installing
04-06 22:29:49.805  2214 10078 D BackupManagerService: Installing from backup: ru.dront78.pulsedroid
04-06 22:29:49.811 10100 10256 W DefContainer: Failed to parse package at /data/cache/backup_stage/ru.dront78.pulsedroid: android.content.pm.PackageParser$PackageParserException: Failed to parse /data/cache/backup_stage/ru.dront78.pulsedroid
04-06 22:29:49.812  2214 10078 I BackupManagerService: Package ru.zdevs.zarchiver not installed; requiring apk in dataset
04-06 22:29:49.813  2214 10078 D BackupManagerService: APK file; installing
04-06 22:29:49.813  2214 10078 D BackupManagerService: Installing from backup: ru.zdevs.zarchiver
04-06 22:29:50.296 10100 10256 W DefContainer: Failed to parse package at /data/cache/backup_stage/ru.zdevs.zarchiver: android.content.pm.PackageParser$PackageParserException: Failed to parse /data/cache/backup_stage/ru.zdevs.zarchiver
04-06 22:29:50.304  2214 10078 D BackupManagerService: [discarding file content]
04-06 22:29:50.305  2214 10078 I BackupManagerService: Package simple.hexadecimal.color not installed; requiring apk in dataset
04-06 22:29:50.305  2214 10078 D BackupManagerService: APK file; installing
04-06 22:29:50.305  2214 10078 D BackupManagerService: Installing from backup: simple.hexadecimal.color
04-06 22:29:50.470 10100 10256 W DefContainer: Failed to parse package at /data/cache/backup_stage/simple.hexadecimal.color: android.content.pm.PackageParser$PackageParserException: Failed to parse /data/cache/backup_stage/simple.hexadecimal.color
04-06 22:29:50.473  2214 10078 D BackupManagerService: [discarding file content]

So it seems to crash. Google backup only seems to back up 80 of my 380 apps and definitely doesn't back up largest ones. What are my other options to perform full device mirror including all apps data, settings, credentials and everything? I'd like to have exactly mirrored 2 devices.

  • 1
    You didn't state the Android version on your two devices. A guess: Nougat (Android 7)? And what failed where all those apps? Known bug then. If you still have the original install (i.e. didn't factory-reset after the backup), take a look at my tool Adebar. Let it generate the backup scripts, perform the app backup (gives you one archive per app), and then use abrestore from the tools/ subdir to restore, which works around the bug (details don't fit in a comment here). – Izzy Apr 6 at 23:15
  • 1
    It's Android 8 btw. I used Adebar with much better results than my naive attempt to use adb backup. It's still far from perfect but at lest some apps properly migrated settings so I guess that's already something. – Lapsio Apr 7 at 15:27
  • 1
    Apart from those that failed with a file size of 41 or 0 bytes (usually because their devs opted them out from backup) which cannot be restored: did the restore work directly, or had you to revert to tools/abrestore? Oh: and no, data should be backed-up and restored fine without root this way. Except for those where devs disallowed it for their apps. – Izzy Apr 7 at 16:16
  • 1
    @Izzy I used standard restore (userbackup/sysbackup + userrestore/sysrestore) just added -obb flag to script. For some reason shared files backup done by Adebar didn't work so I used adb backup -shared directly to restore files before using Adebar restore scripts. As result most of apps migrated properly. Most of those which didn't either required user to log in (so I assume those apps had disabled backup). Others backed up partially (eg. settngs didn't get restored but bookmarks did or other weird cases of partial settings restoration). I copied settings manually so now it's ok. – Lapsio Apr 7 at 22:28
  • 1
    @Izzy I think it was this bug if it works the way you said. I didn't mention but I used Asus Data Transfer before Adebar to migrate all apps (without settings) and then Adebar scripts to restore settings. So I in fact used Adebar to only restore settings, not apps since they were already installed by Asus app at the time of running userrestore/sysrestore. That said I tried to do adb restore after adb backup -obb -all having apps installed by Asus app before and it also didn't work. So I guess bulk restore of all apps settings never works. Nasty issue. Gave me real struggle. – Lapsio Apr 9 at 9:03
1

To manage the system and not give it root access, you neex to use a custom recovery.

A custom recovery will allow you to backup your DATA & SYSTEM Partitions so thst you can restore everything easily and safely.

The most common custom recovery in my opinion is TWRP or Team Win Recovery Project, this would be the newest most common in succession from Clock Work Mod as the most common.

I searched for TWRP for your device, and i got this installation guide... . Zenfone 3 & 3 Delux TWRP

Once you've successfully flashed TWRP you can do the device clone that you want by going to Backup and performing a full device backup to the External SD Card.

Now install TWRP on Device 2.

Place your SD Card from Device 1 with the new backup into Device 2

Boot into TWRP on Device 2

Go to Restore and select External SD

Select your backup

Restore the backup.

The second device will be entirely replaced with the data from the first device excluding some stuff like IMEI number etc, depending on your TWRP Version....


Locked Bootloader ?

Asus provides an Official unlock tool for your specific device at the Asus website...

Here's a direct link...

Asus Unlock Tool

Reference ;
www.asus.com/Phone/ZenFone-3....

  • I assume it requires unlocking bootloader? Zenphone 3 Deluxe has factory locked bootloader. – Lapsio Apr 7 at 10:48
  • @Lapsio yes it does. Even if you just want to run it (fastboot boot twrp.img) instead of flashing it. Someone said having seen exceptions to that, but those are very very rare. – Izzy Apr 7 at 16:17
  • I looked into the guides everywhere, and i can't find anything about unlocking your bootloader.. Are you sure you can not just run fastboot oem unlock or fastboot oem unlock-go – Zillinium Apr 7 at 21:10
  • With a method i used, i somehow managed to unlock my bootloader by looking at the actaul handling of the unlock, Using certain commands before using unlock will allow the Unlock... For example the unlock code has this comment written by the developer... "If unlock fails, try lock first" ... So i managed to find 3 commands that needed to be run consecutively to unlock a locked bootloader... The first command ( i can't remember ) it was something like fastboot flashing unlock and then fastboot oem lock & finally fastboot oem unlock........ It will look like the first two commands fail ! – Zillinium Apr 7 at 21:14
  • 1
    UPDATED ANSWER WITH OFFICIAL UNLOCK TOOL FROM ASUS. – Zillinium Apr 7 at 21:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.