How I fixed my bootloop problem without any format / data loss - Samsung Galaxy S7 Edge Guides, News, & Discussion

Hello everyone, I was able to fix my bootloop occuring after flashing a zip on magisk, without any data loss. I wanted to share what I did to fix since it may be helpful for others. It is useful method worth trying if you know what caused the bootloop. It is definitely not a universal method of fixing bootloops or anything, but If you have a similar problem, you can try these steps.
The bootloop happened after I flashed a zip on Magisk that I downloaded using EdXposed Manager app. I remember downloading the latest alpha version zip and flashing it using Magisk (I had already had the riru core and riru edxposed modules installed on Magisk but on Edxposed manager app, it was showing some error, so I also flashed the zip that I downloaded using the app. I think this caused the bootloop somehow. ) I had no backups.
(I had also "unable to mount /data" problem on TWRP, I am explaining how I fixed that also, if you don't have the problem, you can skip this paragraph)
My TWRP version was 3.2.1.0. And when I was in recovery mode, I was getting "unable to mount /data" error. This is actually a well-known error, but I was able to fix it without a format by just updating my TWRP to 3.3.1.0. After the update, somehow, internal storage could be mounted and everything was fine. My goal by trying to fix this problem is to be able to have a backup using TWRP (using backup feature on TWRP) (just make sure that you didn't choose the compression option on options tab of TWRP backup page).
If you don't have "unable to mount data" problem at all, just make a TWRP backup. (just make sure that you didn't choose the compression option on options tab of TWRP backup page).
So, after having a TWRP backup of everything (actually just System and Data backup would also be fine), I tried to edit my backup files to fix the problem that caused the bootloop.
I changed 2 things in my backup files (you can edit the backup files ending with .win001 etc using 7zip on windows or anything similar. since the backup files are not compressed, you can just delete files) (I edited only the "Data" backup files due to my specific problem, but if your problem is something different, you may have to edit different files also):
1) I deleted everything about EDXposed manager(com.xx.edxposedmanager files) (It might have nothing to do with the fix, I am not sure)
2) In one of the data backup files (probably in the last one), there is a folder called "adb". In adb, there is a "modules" folder. I deleted riru core and riru edxmanager folders in modules.
After these steps, I restored "Data" and "System" using TWRP restore. Bootloop is fixed without any data loss.
If your bootloop is caused by something different, (the point I am trying to tell is) you can edit the nandroid backup files if you know the root of the problem and maybe fix your phone. When I was editing the backup files, I had no hope. As I said, I think this method is worth trying.

I Found this to be true. I also don't see the reason to reflash everything to fix a problem. Thank you for this tutrorial this is an undocumented tactic and i don't know why. Before i discovered this type of surgery i operated under the assumtion that android must be different from other operating systems in some way which would make this impossible. But like you i delved deeper and discovered that this is like a dark art the devs keep to themselves because of what ever but it works. I like this type of post and usually aside from asking for help or a little feed back this is the only type of post i ever make. I mean how do you expect people to learn how to do anything if you never teach them anything useful. EX: "You didn't do it exactly right from the beginning because if left out one thing in my tutorial so you would fail now erase everything and start over." "I only did that to teach you to backup" such bull ****! Thanks again for fighting the good fight.

Related

[XT1032] CM 12 - Flashing TWRP v2.8.6.0 has caused bootloop

Hello,
XT1032 CM 12 latest nightly (I think)
I flashed TWRP v2.8.6.0 using their manager app. I entered recovery mode and everything seemed to work fine. I made a NANDroid backup then rebooted. Unfortunately the device was then stuck at the bootlogo and kept looping. I can still access recovery and fastboot but for some reason adb doesn't see the device, nor can my device's data be access under Windows 7. I don't recall if I had USB debugging on or not. I would like to try to backup a few files to my computer (the backup for instance) but I am unable to since I can't use adb as the device is not recognized. MTP through TWRP doesn't seem to work either. I do have the Universal drive pack installed already on Windows.
Any help would be greatly appreciated. Thanks for your time.
To start with, let's make sure the files you want still exist.
1. Boot into TWRP recovery
2. Go to "Mount" and check that your "Data" partition is selected
3. Go back and then go to "Advanced" and then to "File Manager"
4. Navigate around (maybe /sdcard/ ? Depends what you're looking for) and find the files you need
If you can't find your file, you'll need some more help. Let's say you do see your file. Do you have a USB-OTG cable? You could plug a USB drive into your phone and mount that. Then you could copy your file to that drive. If you don't have the cable you do have some other options, but let us know how far you get.
EDIT: I know I haven't addressed the problem of the bootloop at all. Many of those solutions involve wiping so we need to make sure you've backed up all the files you need first.
First of all thanks for the help. :good:
I've been trying to find a solution and in fact flashing CWM worked. I was able to adb pull all the files and make a backup.
I backed up the content of the sdcard. I tried restoring the CWM nandroid with data only so it did reinstall the apps but unfortunately all their data and settings are gone. Making a full restore just goes back to bricking. So I have the nandroid and the data manually backed up to a computer but no idea how to restore it.
I've tried pushing the nandroid back to /mnt/shell/emulated/clockworkmod/backup after an unsuccessful restore but now it doesn't even work. (protocol failure, the push command fails)
honestly at this point I think the best solution is just to make a clean install. In fact it would be a good idea to just reset the whole phone and start with a clean slate with CM13 including wiping system files and maybe manually restore some key files and configuration (I've got all the .com files of relevant apps)
Do you know how to do that? :laugh:
frustratedwhiteman said:
First of all thanks for the help. :good:
I've been trying to find a solution and in fact flashing CWM worked. I was able to adb pull all the files and make a backup.
I backed up the content of the sdcard. I tried restoring the CWM nandroid with data only so it did reinstall the apps but unfortunately all their data and settings are gone. Making a full restore just goes back to bricking. So I have the nandroid and the data manually backed up to a computer but no idea how to restore it.
I've tried pushing the nandroid back to /mnt/shell/emulated/clockworkmod/backup after an unsuccessful restore but now it doesn't even work. (protocol failure, the push command fails)
honestly at this point I think the best solution is just to make a clean install. In fact it would be a good idea to just reset the whole phone and start with a clean slate with CM13 including wiping system files and maybe manually restore some key files and configuration (I've got all the .com files of relevant apps)
Do you know how to do that? :laugh:
Click to expand...
Click to collapse
I'm not really a Nandroid expert, but I can take a few shots in the dark. When you did your backup you got a TAR file for System and one for Data, etc., right? Then you convert those to IMGs? If you upgraded and then restored the system backup I can see why that would result in a boot loop. Restoring the data image shouldn't cause such problems though. Is this what you've tried so far? You're right, though. The safest method is to manually restore the data of just the apps where you need that data, and do it one at a time. This would allow you to pinpoint what is causing the issue. Of course, I may have no idea what I'm talking about. I've never actually needed to restore a Nandroid backup! Hopefully someone with more experience there will chime in.
I thought to hell with it I went and solved the issue by installing CM13
Thanks for taking the time to help and see you next time

Oneplus 6 bootloop after upgrade to 9.0.4 (+failed to restore the nandroid backup!)

So I have the OP6 for a while now. Everytime a new version released I download the new official zip file and then flash it with twrp. (follow this post - https://forum.xda-developers.com/showpost.php?p=76596833&postcount=3)
So I did it for 9.0.4, I first took nandroid backup, flash the new firmware, flash twrp, reboot to recovery, flash magisk. And then when I tried to reboot the system I got a message "Shutting down..." when the android system tried to load so I was stuck at bootlooping.
I thought that maybe something in the installation went wrong, so I might just get it restored. I did the restore using the latest twrp (v9.91) and now the system is completly corrupt, the phone no longer able to load anyhing (no oneplus loading screen with the rolling dot) and I when it boot to twrp it no longer can decrypt the filesystem (doesn't ask for my password).
I don't know I could I meesed this up, I did the same step every new upgrade. Apperiate any insight to my situasion.
What do you think caused this? Can I decrypt the files on my phone somehow and restore them?
Thank you in advanced.
b217260 said:
So I have the OP6 for a while now. Everytime a new version released I download the new official zip file and then flash it with twrp. (follow this post - https://forum.xda-developers.com/showpost.php?p=76596833&postcount=3)
So I did it for 9.0.4, I first took nandroid backup, flash the new firmware, flash twrp, reboot to recovery, flash magisk. And then when I tried to reboot the system I got a message "Shutting down..." when the android system tried to load so I was stuck at bootlooping.
I thought that maybe something in the installation went wrong, so I might just get it restored. I did the restore using the latest twrp (v9.91) and now the system is completly corrupt, the phone no longer able to load anyhing (no oneplus loading screen with the rolling dot) and I when it boot to twrp it no longer can decrypt the filesystem (doesn't ask for my password).
I don't know I could I meesed this up, I did the same step every new upgrade. Apperiate any insight to my situasion.
What do you think caused this? Can I decrypt the files on my phone somehow and restore them?
Thank you in advanced.
Click to expand...
Click to collapse
Ok this is a giant pain in the backside but I have done this before and I know it works. Here is a step by step guide to restore.
1. https://forum.xda-developers.com/oneplus-6/how-to/rom-stock-fastboot-roms-oneplus-6-t3796665 go here and download the fastboot rom for the rom YOU HAD ON THE PHONE WHEN YOU MADE THE NANDROID BACKUP. Step by step on how to install it is there.
2. Install the rom and boot up the phone. Don't bother signing in to google or downloading apps or any of that. Just get through all the menus.
3. Install TWRP. Bluspark TWRP is recommended.
4. Install Magisk, but make sure IT IS THE SAME VERSION OF MAGISK AS WAS INSTALLED IN THE NANDROID BACKUP
5. Reboot to system and make sure the phone still works, then reboot to TWRP
6. Restore Nandroid backup.
I know this is a giant hassle, but it works every time. I haven't found a better way to restore a backup since this whole A/B partitioning started.
Thank you for making the time writing this, it is relief to hear that you figure this out. Will try this first in the morning.
I did a bad mistake running the flash-all.bat thinking it will only flash the partitions of the system.
Well it is all gone now...Dam if only I wait until the morning I might not made this mistake.
tabletalker7 said:
Ok this is a giant pain in the backside but I have done this before and I know it works. Here is a step by step guide to restore.
1. https://forum.xda-developers.com/oneplus-6/how-to/rom-stock-fastboot-roms-oneplus-6-t3796665 go here and download the fastboot rom for the rom YOU HAD ON THE PHONE WHEN YOU MADE THE NANDROID BACKUP. Step by step on how to install it is there.
2. Install the rom and boot up the phone. Don't bother signing in to google or downloading apps or any of that. Just get through all the menus.
3. Install TWRP. Bluspark TWRP is recommended.
4. Install Magisk, but make sure IT IS THE SAME VERSION OF MAGISK AS WAS INSTALLED IN THE NANDROID BACKUP
5. Reboot to system and make sure the phone still works, then reboot to TWRP
6. Restore Nandroid backup.
I know this is a giant hassle, but it works every time. I haven't found a better way to restore a backup since this whole A/B partitioning started.
Click to expand...
Click to collapse
This guide can also be used to restore from other roms;
b217260 said:
I did a bad mistake running the flash-all.bat thinking it will only flash the partitions of the system.
Well it is all gone now...Dam if only I wait until the morning I might not made this mistake.
Click to expand...
Click to collapse
What did you do?
---------- Post added at 02:14 PM ---------- Previous post was at 02:13 PM ----------
petran07 said:
This guide can also be used to restore from other roms;
Click to expand...
Click to collapse
I guess so. I never had to use a backup to restore on a custom ROM yet.
tabletalker7 said:
What did you do?
Click to expand...
Click to collapse
After extracting the stock zip flasher, there is file "flash-all.bat" on the root of the folder. (Guess I needed to use the "flash-all-partitions-fastboot.bat)
Thinking it will only flash the android system partitions I've run it and realize that my internal stoarge was formatted.
Really stupid mistake from my part, sorry for couldn't verify your guide.
Hoping that someone who read this in the future won't do my mistake.
b217260 said:
After extracting the stock zip flasher, there is file "flash-all.bat" on the root of the folder. (Guess I needed to use the "flash-all-partitions-fastboot.bat)
Thinking it will only flash the android system partitions I've run it and realize that my internal stoarge was formatted.
Really stupid mistake from my part, sorry for couldn't verify your guide.
Hoping that someone who read this in the future won't do my mistake.
Click to expand...
Click to collapse
It's my bad. I always store my backups on an SD card with my OTG card reader. I forget others don't think like I do sometimes
tabletalker7 said:
Ok this is a giant pain in the backside but I have done this before and I know it works. Here is a step by step guide to restore.
1. https://forum.xda-developers.com/oneplus-6/how-to/rom-stock-fastboot-roms-oneplus-6-t3796665 go here and download the fastboot rom for the rom YOU HAD ON THE PHONE WHEN YOU MADE THE NANDROID BACKUP. Step by step on how to install it is there.
2. Install the rom and boot up the phone. Don't bother signing in to google or downloading apps or any of that. Just get through all the menus.
3. Install TWRP. Bluspark TWRP is recommended.
4. Install Magisk, but make sure IT IS THE SAME VERSION OF MAGISK AS WAS INSTALLED IN THE NANDROID BACKUP
5. Reboot to system and make sure the phone still works, then reboot to TWRP
6. Restore Nandroid backup.
I know this is a giant hassle, but it works every time. I haven't found a better way to restore a backup since this whole A/B partitioning started.
Click to expand...
Click to collapse
tabletalker7, can you please explain a little technical detail? If i follow your procedure, what is the difference from me just restoring boot, system and data from a Nandroid backup of a system that used to boot? What causes the restored system to no longer boot?
Because you seem to be suggesting a solution for the the problem I had. I normally do plenty of backups and play around with the system quite a lot, but Op6 burned me: I was unable to restore from a backup like I always did on other phones. I tried suggestions from other posters to no avail. So I set up a clean system from a fastboot rom and reinstalled everything from Titanium. I wonder, after I set pretty much identically, should I just risk and to once more try to restore from that Nandroid that was failing to restore (that only had system and data btw)? I'd greatly appreciate if you can enlighten.
b217260 said:
So I have the OP6 for a while now. Everytime a new version released I download the new official zip file and then flash it with twrp. (follow this post - https://forum.xda-developers.com/showpost.php?p=76596833&postcount=3)
So I did it for 9.0.4, I first took nandroid backup, flash the new firmware, flash twrp, reboot to recovery, flash magisk. And then when I tried to reboot the system I got a message "Shutting down..." when the android system tried to load so I was stuck at bootlooping.
I thought that maybe something in the installation went wrong, so I might just get it restored. I did the restore using the latest twrp (v9.91) and now the system is completly corrupt, the phone no longer able to load anyhing (no oneplus loading screen with the rolling dot) and I when it boot to twrp it no longer can decrypt the filesystem (doesn't ask for my password).
I don't know I could I meesed this up, I did the same step every new upgrade. Apperiate any insight to my situasion.
What do you think caused this? Can I decrypt the files on my phone somehow and restore them?
Thank you in advanced.
Click to expand...
Click to collapse
Had faced this many times. ...after trying diff options and failed Qualcome MSM method works perfectly.
Yep, You cant restore data i think as it being already formated as per knowd based on your steps above on diff posts
ahacker said:
tabletalker7, can you please explain a little technical detail? If i follow your procedure, what is the difference from me just restoring boot, system and data from a Nandroid backup of a system that used to boot? What causes the restored system to no longer boot?
Because you seem to be suggesting a solution for the the problem I had. I normally do plenty of backups and play around with the system quite a lot, but Op6 burned me: I was unable to restore from a backup like I always did on other phones. I tried suggestions from other posters to no avail. So I set up a clean system from a fastboot rom and reinstalled everything from Titanium. I wonder, after I set pretty much identically, should I just risk and to once more try to restore from that Nandroid that was failing to restore (that only had system and data btw)? I'd greatly appreciate if you can enlighten.
Click to expand...
Click to collapse
1. Changing Android security updates makes changes to phone encryption. It will make the data itself on the backup unreadable to the operating system. That is why people playing with many different custom ROMs had problems with data stored on their phones.
2. By using the fastboot rom you ensure that both partitions have the same operating system. A/B partitioning seems like a great idea on paper but it seems to be executed in the most horrible way possible.
tabletalker7 said:
1. Changing Android security updates makes changes to phone encryption. It will make the data itself on the backup unreadable to the operating system. That is why people playing with many different custom ROMs had problems with data stored on their phones.
2. By using the fastboot rom you ensure that both partitions have the same operating system. A/B partitioning seems like a great idea on paper but it seems to be executed in the most horrible way possible.
Click to expand...
Click to collapse
Thanks a lot. It is plausible and I remeber seeing folder names to which random hex strings were appended (I did not see file contents though). But after last restores I verified that the folder names in /data/data folder were looking allright. Twrp apparently could decrypt the data partition, but the system would still not boot. If I were to encypr the data partition I'd use the whole partition as one encrypted block and not bother doing it on file or folder basis, which is more error-prone. Another sourse of doubt is that I never played with OS version upgrades nor with installing other roms.
Can you also please answer the following? Do you think I can try to restore my boot+system to a different slot and then come back to my original slot if my playing there is unsuccesfull? Being scared that restoring a previous state can fail is a major problem.
ahacker said:
Thanks a lot. It is plausible and I remeber seeing folder names to which random hex strings were appended (I did not see file contents though). But after last restores I verified that the folder names in /data/data folder were looking allright. Twrp apparently could decrypt the data partition, but the system would still not boot. If I were to encypr the data partition I'd use the whole partition as one encrypted block and not bother doing it on file or folder basis, which is more error-prone. Another sourse of doubt is that I never played with OS version upgrades nor with installing other roms.
Can you also please answer the following? Do you think I can try to restore my boot+system to a different slot and then come back to my original slot if my playing there is unsuccesfull? Being scared that restoring a previous state can fail is a major problem.
Click to expand...
Click to collapse
I would not recommend doing that. While you may have different roms on different partitions you only have one data partition. That is asking for trouble
tabletalker7 said:
I would not recommend doing that. While you may have different roms on different partitions you only have one data partition. That is asking for trouble
Click to expand...
Click to collapse
I would have data backed up, sure.
What bothers me is that an essential property of a digital automaton is that if you start it from the same state it will continue the same. Nandroid used to capture all that mattered for identical runs. It no longer does, something is missing, such as some encryption keys for data partition, as you seem to suggest. This bothers me.
ahacker said:
I would have data backed up, sure.
What bothers me is that an essential property of a digital automaton is that if you start it from the same state it will continue the same. Nandroid used to capture all that mattered for identical runs. It no longer does, something is missing, such as some encryption keys for data partition, as you seem to suggest. This bothers me.
Click to expand...
Click to collapse
What bothers you here are things I call "security". If the nandroid backup has the encryption keys to decrypt it, then the data is not secure.
tabletalker7 said:
What bothers you here are things I call "security". If the nandroid backup has the encryption keys to decrypt it, then the data is not secure.
Click to expand...
Click to collapse
Nandroid backups should be encrypted when created with a user supplied key. Twrp allowed this since ages ago. Not allowing the user to restore a backup is not a right substitution for this.
ahacker said:
Nandroid backups should be encrypted when created with a user supplied key. Twrp allowed this since ages ago. Not allowing the user to restore a backup is not a right substitution for this.
Click to expand...
Click to collapse
TWRP didn't do this. Android didn't do this. Ya know, if this is anywhere near as horrible for you as you are making it sound, my advise for you would be to buy Apple products. Bottom line is a new feature was added to Android, and your backup does work.
tabletalker7 said:
TWRP didn't do this. Android didn't do this. Ya know, if this is anywhere near as horrible for you as you are making it sound, my advise for you would be to buy Apple products. Bottom line is a new feature was added to Android, and your backup does work.
Click to expand...
Click to collapse
-It is as horrible as not being able to restore a full backup. No more, no less.
-Twrp has an ability to encrypt your backups, with your experience you must know this.
-You are suggesting someone to switch to iphone only because they point out that the things are wrong or dont add up.
-It is quite a common knowlege that you get good security out of encryption if you make things explicit and clear. And not how you may think it is. Cause you don't seem to know where the keys are stored for the data partition. Obviousely, because the phone eventually decrypts your data, the keys must be stored somewhere or derived from you swipe pattern.
tabletalker7 said:
Ok this is a giant pain in the backside but I have done this before and I know it works. Here is a step by step guide to restore.
1. https://forum.xda-developers.com/oneplus-6/how-to/rom-stock-fastboot-roms-oneplus-6-t3796665 go here and download the fastboot rom for the rom YOU HAD ON THE PHONE WHEN YOU MADE THE NANDROID BACKUP. Step by step on how to install it is there.
2. Install the rom and boot up the phone. Don't bother signing in to google or downloading apps or any of that. Just get through all the menus.
3. Install TWRP. Bluspark TWRP is recommended.
4. Install Magisk, but make sure IT IS THE SAME VERSION OF MAGISK AS WAS INSTALLED IN THE NANDROID BACKUP
5. Reboot to system and make sure the phone still works, then reboot to TWRP
6. Restore Nandroid backup.
I know this is a giant hassle, but it works every time. I haven't found a better way to restore a backup since this whole A/B partitioning started.
Click to expand...
Click to collapse
Following these instructions seems to be the only way of restoring a nandroid backup (at least for my Op6 bought on AliExpress from China). Important: step 1 wipes your sdcard, so the backup you want to restore must be on otg usb stick.
After spending many hours I managed to restore a backup at least once. Fortunately for me I have no plans of upgarding Android and will likely forever stick with the following set:
1) 5.1.11-OREO-OnePlus6Oxygen_22_OTA_015_all_1808102118_770880-FASTBOOT.zip (found here)
2) twrp-3.2.3-x_blu_spark_v9.85_op6.img + twrp-3.2.3-x_blu_spark_v9.85_op6.zip (found here)
3) Magisk-v18.1.zip (found here)
My plan is to fully debloat the phone and then I will keep everything unchanged for years, because nowadays updates are more about twisting your arms than giving you usefull features. I almost got to that state, but one little glitch forced me to roll back and the whole hell with the Nandoid backups on Op6 started.
PS: It's very interesting what is really going on with this A/B system. There must be a storage where the encryption keys are stored (if it is the encryption that does prevent the phone from restoring. Which I doubt because Twrp sees the files fine). There also probbaly stored what slot is used. That information does not get captured by the Nandroid backup.
(Btw, It seems that blu_spark Twrp is really NOT encrypting your backups with the passwod you supply. Official Twrp does. I have plenty of old encypted backups, from wich I could not extract any personal data (/data/data folder) but yesterday I could extract my private information from a backup done by blu_spark Twrp. This is serious iussue. I'll double check and will post if confirmed.)
Not confirmed, I was looking at unencrypoted file.

TWRP backup restore stuck in bootloop and different exotic issues (1913 Europe)

After my experiment of trying out Beta 3 of Android Q failed apocaliptical I tried to restore the backup I made minutes before. But no matter what I do, I keep getting:
- bootloops (straight rebooting after showing the unlocked bootloader warning)
- restart into recovery
- Oxygen OS loading animation stuck and animation being very slow
- not getting it anymore but had it yesterday in the early stages of my disaster management: Qualcomm Crash POST
Despite that the backup was generated succesfully (at least thats what TWRP said)
I tried almost every guide out there.
- switching to rm -rf
- restoring only data, only boot, only system and a mix of those
- flashing the OTA before restoring backup
- uninstalling magisk und reinstallating magisk (with and without separate reboots)
-multiple wipes of single partitions and data formatting
The only good thing is that I don't get the 255 error anymore I had at the beginng, allthough I don't really know anymore how I did it.
At the end I am only able to restore everything with the MSNTOOL out there.
Is there any golden hint to get the data the be restored? The backup of /data is critical as there my authenticator and banking data are in there.
Thank you in advance
Edit: As I am slowly getting fed up with OnePlus and the problems (proximity sensor, adaptive brightness, whatspps microphone, twrp issues, lacking tech guides if at all) I thought about migrating to Pixel 5. Is it possible to migrate the data partition? Or are all backup partitions strictily device specific?
anphex said:
After my experiment of trying out Beta 3 of Android Q failed apocaliptical I tried to restore the backup I made minutes before. But no matter what I do, I keep getting:
- bootloops (straight rebooting after showing the unlocked bootloader warning)
- restart into recovery
- Oxygen OS loading animation stuck and animation being very slow
- not getting it anymore but had it yesterday in the early stages of my disaster management: Qualcomm Crash POST
Despite that the backup was generated succesfully (at least thats what TWRP said)
I tried almost every guide out there.
- switching to rm -rf
- restoring only data, only boot, only system and a mix of those
- flashing the OTA before restoring backup
- uninstalling magisk und reinstallating magisk (with and without separate reboots)
-multiple wipes of single partitions and data formatting
The only good thing is that I don't get the 255 error anymore I had at the beginng, allthough I don't really know anymore how I did it.
At the end I am only able to restore everything with the MSNTOOL out there.
Is there any golden hint to get the data the be restored? The backup of /data is critical as there my authenticator and banking data are in there.
Thank you in advance
Edit: As I am slowly getting fed up with OnePlus and the problems (proximity sensor, adaptive brightness, whatspps microphone, twrp issues, lacking tech guides if at all) I thought about migrating to Pixel 5. Is it possible to migrate the data partition? Or are all backup partitions strictily device specific?
Click to expand...
Click to collapse
Try, booting into twrp... Format data. Type yes to format. Restore. Should boot.
@soka said:
Try, booting into twrp... Format data. Type yes to format. Restore. Should boot.
Click to expand...
Click to collapse
I did just exactly that on stock 10.0.0.11 to no avail, the TWRP restore went through fine but upon system reboot the phone stayed on the bootloader unlocked warning for about two minutes, then it rebooted straight into stock recovery.
It's beyond my understanding yet how the user data partition can cause the whole system to effing die.
My only hunch is that it has something to do with Magisk I had installed during the backup (encryption was disabled btw). But as I said I already tried running Magisk installer and uninstaller on different occasions with the same result. Also the only thing that should happen is that after restore and reboot the phone should tell me that Magisk isn't installed anymore.
Edit: So for now I reverted to full stock 10.0.11 and for the sake of experimenting I made a backup with system, boot and data of this stock rom and restored it succesfully. When I restore my actual data backup I get the same old restart and then it throws me back into TWRP. Is there any log I can check to see what's happening there?
Sorry for double post, but I think this might be very interesting for people with a similar problem as this seems to be very common with OnePlus phones.
So I found a very dirty and hacky way to get a least my most importants app running in the state they had during my backup I was trying to restore. Here's what I did, without any guarantee it might work for you or be stable in the end.
Code:
1. Revert the phone to a clean stock rom and update to the latest stable version (at the time of writing 10.0.11), it should be fully factory reset, aka like new. I am not sure but it may be necessary that you install the apps you want to restore first since the I am not sure the partition we use later contains the app AND the data too.
2. Unlock bootloader and flash latest TWRP, may it be official or mauronofio's
3. Make a backup of that current stock data partition
4. Restore data partition from your actual needed twrp backup (if it ends with 255, try to format data partition before in TWRP)
5. With the TWRP file manager navigate to the /data/data folder and copy everything to an external storage (I chose USB)
6. Restore the stock data partition
7. Now again with the TWRP file manager navigate to the /data/data folder on your external storage (should be /usbstorage) and search for the apps you need to restore (probably banking apps, authenticator, etc.), the name will be something like com.google.authenticator2.
8. Copy the folder of any needed app into the /data/data folder on your phone. Best you do it one by one just to make sure.
Now you can reboot to system. The apps should be fully restored. In my case it worked with Google Authenticator, Blizzard Authenticator, Consorbank Secure Plus (shows undefined error yet), Hue Pro. Maybe I will try more.
Edit: Consorsbank Secure Plus as you might guess is a tan generation banking app. When entering the pin when opening the app it shows "An error has occured". Dunno why, maybe a security checksum error or something. I found com.android.keychain and copied for the sake of trying too but it didn't help.
If you have any questions, suggestions or improvements, feel free to post!

Backup methods, .win versus .img, when to use each type?

When I used payload dumper on the OTA for this device I ended up with 34 .img files. When I used TWRP to backup all the partitions from the OxygenOS I end up with 12 .win files. When I used dd commands to get copies of boot_a & boot_b and persist, I end up with .img files. When I used dd commands to get EFS backup I ended up with modemst1.bin and modemst2.bin.
I have all these back ups now but I'm not sure which type of file to use and when.
I have TWRP and Lineage on my 8T and they're working great. But I'd like to now restore OxygenOS, install the latest OTA, re-install TWRP, then install a newer version of Lineage. There's a good chance I'll slip up and have to recover my phone at some point and I'd like to know first if I'm better off trying to get TWRP booted and then restoring all the .win backups, or if I should just flash all the .img files from the payload dumper.
Can anyone offer some tips or explain the difference?
Look in TWRP thread. It mentions what partitions to backup (and restore) when changing ROMs.
Look in TWRP thread. It mentions what partitions to backup (and restore) when changing ROMs.
Click to expand...
Click to collapse
I've read through that thread and made a lot of notes, but I guess I'm just wondering at this point, since we have a fully-functional TWRP is it the case that as long as I have the .win files from the TWRP backup of boot, dtbo, super and data partitions that should be all I need?
Persist.img & Modemst1/2.bin & boot_a/b.img can be discarded? Or would you keep these on hand for other reasons?
FakeGemstone said:
I've read through that thread and made a lot of notes, but I guess I'm just wondering at this point, since we have a fully-functional TWRP is it the case that as long as I have the .win files from the TWRP backup of boot, dtbo, super and data partitions that should be all I need?
Persist.img & Modemst1/2.bin & boot_a/b.img can be discarded? Or would you keep these on hand for other reasons?
Click to expand...
Click to collapse
Persist and modem images presumably contain IMEI information, so better keep them somewhere safe. Boot_a/b.img can be discarded.
It's starting to make sense. Thank you for your explanation.
My phone had Lineage and TWRP installed and was running great, but I wanted to try out the backup and restore option of TWRP. So I backed up /data then used TWRP to restore the OxygenOS to the version I was using right before I installed Lineage. I restored OxygenOS to both slots and also I formatted /data.
After doing an minimal setup on OxygenOS, taking a quick look around to see if everything looked okay and rebooting to system a couple of times, I used TWRP to install LineageOS again. That seemed to work fine. I did minimal setup, took a look around, rebooted a couple of times, so far; so good.
I then followed the instructions from theincognito on Steps for backing up and restoring data in TWRP to restore the data partition:
It seemed to work fine, except I was never presented with a blank screen (a clue?) and the phone just booted to system normally. My apps and settings appeared to be restored BUT the 3-button system navigation icons (home/back/switchapps) were missing. So whenever I navigated away from the home screen there was no way to get back except to reboot the phone. It didn't matter if I switched to 2-button navigation or gesture navigation, none of it worked. So I guess the navigation options are all apps and those apps malfunctioned when /data was restored. Also, I could not enable Advanced Restart for the Power Menu. That's probably a system app, too. I didn't have a password on the phone at any time, or a SIM card installed. I know the TL;DR instructions in post #3 say that you should just reboot to system again if you have this problem, but doing so didn't fix the problem for me. I must have made a mistake at some point.
I ended up wiping the phone, doing a clean install of Lineage and setting up the apps and preferences the old-fashioned way.
I'd like to try this again to see if I can get it to work. Does anyone have suggestions of what went wrong?
Should I have tried restoring /data a second time before giving up and wiping the phone?
Does the fact I didn't get the expected blank screen after restoring /data have any significance?
Did the problem more likely originate with the backup process or the restore process?
Oh boy, it just dawned on me... Should I have also restored the backup of Boot/dtbo/Super? I assumed those wouldn't change if you were restoring to the exact same version of Lineage so I didn't bother with it.
I stumbled across a trick to get the restored data backup working again. I went to Settings --> Apps & Notifications --> App Info. Then I selected the option "Show System" from the list at the top with the 3 vertical dots. From the list of apps I selected 3-button navigation and then selected "force stop". After that, I rebooted and all the settings that were missing before were magically back in place, and both the Status Bar and the Navigation Bar were functioning and configured just the way I had them when I did the backup. I don't know anything about how system apps work so I can't explain why this helped, but I tested it twice with fresh installations of LineageOS and it worked exactly the same both times.
I should add that between this post and the one above from February 1st, I have re-installed Oxygen OS many times using old and new OTA zips, and installed Lineage OS several times, first on one slot then the other. And each time I've restored various back ups of LineageOS system files and LineageOS data files following the instructions, but always the result was a partial restoration of user configurations and missing status and navigation bars. I wonder that I'm the only person who found that booting twice after a data restore didn't bring back those menus. But hopefully if it happens to someone else they'll find this post and know what to do.

7 Pro stuck in boot after removing Magisk

I've been having a bunch of problems recently with my rooted 7 Pro including Magisk Manager constantly "keeps stopping", not being able to access Hide to add new applications, banking apps starting to detect that I'm rooted and camera issues: the camera app not starting, the camera not popping up automatically and the image being usually reversed and occasionally upside down as well, depending on the app I'm using.
Given that Magisk appears to be dead/dying, having lost its developer to Google, I thought I'd start by getting rid of that and then performing a firmware upgrade in necessary to see if that fixes the other issues.
I uninstalled the Manager then ran the uninstall zip within TWRP. Rebooting though hangs on the initial "ASUS" screen.
I can get back to TWRP ok so I guess I'm not bricked yet. My next thought was to try a system upgrade but I seem to need to know the exact version I need, which, seemingly, I can only get via a working phone?
From the back, it says only model I002D along with SN and IMEIs.
I've done a TWRP backup to the external uSD card, and I have a syncthing copy of all of the internal memory that I can access without root.
My questions:
1. Is there something there which can help my figure out which firmware I need to download?
2. Is there any way to install this without wiping the phone?
Please see this post.
When I try to burn rom with TWRP, img burns but it doesn't start and zip gives an error and cannot burn.
When I first burned custom ROM (unofficial AEX), it did not start, so when I deleted the data from TWRP, it seems that I deleted things that should not be erased, so even if I burn it from the zip file, with the error message in the image below I...
forum.xda-developers.com

Categories

Resources