Recover data from soft-bricked (bootloop) phone - Huawei P9 Plus Questions & Answers

Background:
Went to update Magisk via TWRP, phone now bootloops (and gets really hot when charging).
Before I go ahead with flashing an older firmware, to try and get it running again, I was wondering if there was any way of retrieving data from the phone?
I can still boot into TWRP without issue, although I did notice if i go to Install and select source, Internal Storage shows as empty, while External is fine.
Failing data recovery, any suggestions for unbricking it without wiping anything? I've tried un/reinstalling Magisk via TWRP, wiping data/cache/dalvik, but no luck so far.
Thanks

I know where i ****ed up now. By flashing Magisk directly from TWRP.
Tried reflashing it via the guide on page one:
"Instructions for Root Access"
A) Workaround for flashing Magisk with TWRP – for Advanced Users:
Now getting past the warning screen, but not past the Huawei logo.
Going to try remove Magisk altogether, and see if it boots up. If so, will install Magisk again.

Flashed original ramdisk.img and it now shows the boot animation, but doesn't get past there....progress i guess.

Related

Oneplus 3T stuck in boot animation after root attempt

I have a stock Oneplus 3T, updated to 4.1.3. I wanted root access to allow Cerberus more control.
So I followed the Oneplus 3T root guide by "Theunlockr" .com
I downloaded:
TWRP v3.1.0-1-oneplus3t.img
SuperSU v2.78 SR5
No-Verity opt encript v5.1​
I followed the instructions as closely as I could, I installed the TWRP and cleared the phone (that booted normally),
Then I went to flash SuperSU and No-Verify, cleared the cache, restarted and my phone, and It didn't boot, the red dot logo animation would just play on a loop, I left it for an hour because it did warn me that it would take a while.
When I was satisfied that it wasn't going to start, I restarted it a couple of time, no-dice.
I also tried flashing a more up-to-date SuperSU. (v2.79), still didn't work.
So, now I've gotten myself further stuck, I flashed the stock recovery back onto the phone and decided i wanted to flash the Open Beta 5 OS.
But now when I go into recovery (stock), I can't connect to ADB properly.
I click " Install from ADB " - I've been using this, but it only seems to allow Sideload, but If I try to sideload it, it tells me it can't read the ROM.
So I changed ADB versions to the ones from mfastbootv2.
and now it says "error: protocol fault (no status)",
I can't use the push command because it just says "Error: closed"
So I'm kinda stuck for what I can do from this point forward to get my phone working again...
Android Debug Bridge version 1.0.31
Any suggestions?
Thanks for your time
Evan
There's so many different builds of SuperSU that it's getting hard to keep track of which one works. I know that flashing an older version does tend to cause endless boot animation. SuperSU 2.79 should work, though you'll likely need to dirty flash OOS again before flashing it.
I've also found ADB to be rather finicky in recovery. My advice is to use an USB OTG adapter and load any files that you need on a flash drive. Afterwards, follow these steps:
1) Boot into fastboot and flash TWRP again using your PC and fastboot commands
2) Download whatever version of OOS you want (stable or open beta) and somehow load it onto your phone, whether through ADB or USB OTG
3) Boot into TWRP and flash the OS that you've downloaded, wipe cache/Dalvik. You can clean flash if you want, though dirty flashing should suffice in this situation.
4) Flash either SuperSU v2.79, or Magisk v12.0. Both Magisk and SuperSU will root your phone, I just prefer Magisk due to its extra capabilities and more straight-forward development.
5) Reboot, the rebooting process shouldn't take more than a few minutes.
Using a flash drive also has other benefits, you can save nandroids directly onto it through TWRP. This both saves space in internal storage and keeps the backups safe in the event that your phone gets inadvertently wiped from any unforeseen incidents.
Additional notes:
-You don't need to flash the no-verity.zip if you flash either SuperSU or Magisk, both of them contains the necessary scripts
Fantastic!
Thanks a ton, that solved my issues completely.

[SOLVED] BRICKED S7 (G930FD) when going from v14.0 to v15 using updater in Magisk app

I had Magisk v14.0 running on my phone, which was installed using the patched_boot.img method. I had the stock recovery, stock ROM and kernel. But... a Magisk module I wanted to install required me to update Magisk, which I did using the in-app updater. On rebooting, the phone hung with a pulsating Samsung logo. I left it overnight to ensure it wasn't just a very long boot up.
I have seen a number of threads with people with the same solution. A fix appears to be to flash the latest Magisk-uninstaller zip then move back to Magisk 14.0. In order to do this, I flashed TWRP after reading the official thread but didn't swipe right (step 9 of the official guide) to allow system modifications and I didn't install SuperSU. I figured this may interfere with Magisk's systemless root. I did immediately flash no-verity-opt-encrypt-6.0 after flashing TWRP but I was still stuck at the pulsating Samsung logo. Since flashing TWRP, I have tried uninstalling Magisk, flashing no-verity-opt-encrypt-6.0 and reinstalling v14.0, v15.3, or removing Magisk completely. Doing combinations of these in the various sequences as suggested by those who have solved the issue from reading this thread and similar ones.
Should I allow TWRP to modify the system by swiping right and try the steps above again?
Assuming it's my boot.img that's cuasing this, I have tried signing but boot image with Chainfire's .zip that's mentioned here but that zip stopped flashing with an unexpected error.
The last thing I tried was to flash the original unpatched boot.img via TWRP. This gave a boot loop initially but when I reflashed it and immediately flashed no-verity-opt-encrypt-6.0, it progressed a bit further but got stuck at the pulsating Samsung logo again.
This thread shows someone who fixed the issue by installing a custom kernel. I haven't tried that yet. Is this a good idea?
I would be very grateful if you can suggest a way to repair my phone.
ssteward said:
I had Magisk v14.0 running on my phone, which was installed using the patched_boot.img method. I had the stock recovery, stock ROM and kernel. But... a Magisk module I wanted to install required me to update Magisk, which I did using the in-app updater. On rebooting, the phone hung with a pulsating Samsung logo. I left it overnight to ensure it wasn't just a very long boot up.
I have seen a number of threads with people with the same solution. A fix appears to be to flash the latest Magisk-uninstaller zip then move back to Magisk 14.0. In order to do this, I flashed TWRP after reading the official thread but didn't swipe right (step 9 of the official guide) to allow system modifications and I didn't install SuperSU. I figured this may interfere with Magisk's systemless root. I did immediately flash no-verity-opt-encrypt-6.0 after flashing TWRP but I was still stuck at the pulsating Samsung logo. Since flashing TWRP, I have tried uninstalling Magisk, flashing no-verity-opt-encrypt-6.0 and reinstalling v14.0, v15.3, or removing Magisk completely. Doing combinations of these in the various sequences as suggested by those who have solved the issue from reading this thread and similar ones.
Should I allow TWRP to modify the system by swiping right and try the steps above again?
Assuming it's my boot.img that's cuasing this, I have tried signing but boot image with Chainfire's .zip that's mentioned here but that zip stopped flashing with an unexpected error.
The last thing I tried was to flash the original unpatched boot.img via TWRP. This gave a boot loop initially but when I reflashed it and immediately flashed no-verity-opt-encrypt-6.0, it progressed a bit further but got stuck at the pulsating Samsung logo again.
This thread shows someone who fixed the issue by installing a custom kernel. I haven't tried that yet. Is this a good idea?
I would be very grateful if you can suggest a way to repair my phone.
Click to expand...
Click to collapse
Try flashing magisk 15.3 + no verity stuff as suggested on that thread...
Sent from my MI 5 using Tapatalk
ssteward said:
I had Magisk v14.0 running on my phone, which was installed using the patched_boot.img method. I had the stock recovery, stock ROM and kernel. But... a Magisk module I wanted to install required me to update Magisk, which I did using the in-app updater. On rebooting, the phone hung with a pulsating Samsung logo. I left it overnight to ensure it wasn't just a very long boot up.
I have seen a number of threads with people with the same solution. A fix appears to be to flash the latest Magisk-uninstaller zip then move back to Magisk 14.0. In order to do this, I flashed TWRP after reading the official thread but didn't swipe right (step 9 of the official guide) to allow system modifications and I didn't install SuperSU. I figured this may interfere with Magisk's systemless root. I did immediately flash no-verity-opt-encrypt-6.0 after flashing TWRP but I was still stuck at the pulsating Samsung logo. Since flashing TWRP, I have tried uninstalling Magisk, flashing no-verity-opt-encrypt-6.0 and reinstalling v14.0, v15.3, or removing Magisk completely. Doing combinations of these in the various sequences as suggested by those who have solved the issue from reading this thread and similar ones.
Should I allow TWRP to modify the system by swiping right and try the steps above again?
Assuming it's my boot.img that's cuasing this, I have tried signing but boot image with Chainfire's .zip that's mentioned here but that zip stopped flashing with an unexpected error.
The last thing I tried was to flash the original unpatched boot.img via TWRP. This gave a boot loop initially but when I reflashed it and immediately flashed no-verity-opt-encrypt-6.0, it progressed a bit further but got stuck at the pulsating Samsung logo again.
This thread shows someone who fixed the issue by installing a custom kernel. I haven't tried that yet. Is this a good idea?
I would be very grateful if you can suggest a way to repair my phone.
Click to expand...
Click to collapse
Dont flash unpatched boot images using twrp
flash unpatched boot image or v14 boot image(that you made earlier) using pc ODIN/ any other prefered tool. Just flash the boot.img nothing else or you can use fastboot to only flash boot.img, it works 100% all times,after flashing it should boot normal
then make a new patched boot image for v15.3 from magisk app just as you made for v14 and flash using pc,then it should boot normally
many phones seem to show stuck at boot logo after moving from v14 to v15(especially v15.1 and v15.2) and also some some devices with f2fs storage seems working weirdly with audio mods.
teddy0209 said:
Try flashing magisk 15.3 + no verity stuff as suggested on that thread...
Click to expand...
Click to collapse
I'm pretty sure that's one of the permutations I tried before but having just flashed those two zips again, after making sure any previous Magisk installations had been removed, I get the same result - stuck at the pulsating Samsung logo.
If someone can tell me what parts of the system the problematic in-app upgrade from v14.0 to v15.0 would have affected then I could perhaps have a better idea of what I need to fix to get my phone starting up again.
ssteward said:
I'm pretty sure that's one of the permutations I tried before but having just flashed those two zips again, after making sure any previous Magisk installations had been removed, I get the same result - stuck at the pulsating Samsung logo.
If someone can tell me what parts of the system the problematic in-app upgrade from v14.0 to v15.0 would have affected then I could perhaps have a better idea of what I need to fix to get my phone starting up again.
Click to expand...
Click to collapse
Have you tried flashing your stock boot image or even dirty flashing your entire system with ODIN (as suggested above)? Magisk only edits the boot image, nothing else.
Supreme Genius said:
Dont flash unpatched boot images using twrp
Click to expand...
Click to collapse
Sorry, my mistake. I did flash boot.img via Odin. It was the original boot.img file that I fed into Magisk v14.0 so it could create patched_boot.img.tar that originally worked. I'm going to try that again now.
Didgeridoohan said:
Have you tried flashing your stock boot image or even dirty flashing your entire system with ODIN (as suggested above)? Magisk only edits the boot image, nothing else.
Click to expand...
Click to collapse
That's good to know, thanks. I do have the full system from sammobile from which I extracted boot.img, so could try that if the 'lighter touch' approaches fail.
UPDATE:
After using TWRP to uninstall Magisk v15.3, which restores the stock boot.img, the phone hangs with a pulsating Samsung logo.
Using Odin to flash boot.img.tar (which I extracted from stock ROM) in the AP slot, I get a different behaviour - a boot loop which shows the "Samsung Galaxy S7 | powered by android" screen momentarily before going black and repeating.
So, even with a stock boot.img (assuming I've got the correct .img, which I'm pretty sure I have) and that I flashed it correctly, again, I think I have) then there seems to be more going on than just a corrupted/incorrect boot.img.
What next? A dirty flash of the stock rom?
ssteward said:
UPDATE:
After using TWRP to uninstall Magisk v15.3, which restores the stock boot.img, the phone hangs with a pulsating Samsung logo.
Using Odin to flash boot.img.tar (which I extracted from stock ROM) in the AP slot, I get a different behaviour - a boot loop which shows the "Samsung Galaxy S7 | powered by android" screen momentarily before going black and repeating.
So, even with a stock boot.img (assuming I've got the correct .img, which I'm pretty sure I have) and that I flashed it correctly, again, I think I have) then there seems to be more going on than just a corrupted/incorrect boot.img.
What next? A dirty flash of the stock rom?
Click to expand...
Click to collapse
Probably try that... Hope it's not a corrupt boot partition...
Sent from my MI 5 using Tapatalk
ssteward said:
UPDATE:
After using TWRP to uninstall Magisk v15.3, which restores the stock boot.img, the phone hangs with a pulsating Samsung logo.
Using Odin to flash boot.img.tar (which I extracted from stock ROM) in the AP slot, I get a different behaviour - a boot loop which shows the "Samsung Galaxy S7 | powered by android" screen momentarily before going black and repeating.
So, even with a stock boot.img (assuming I've got the correct .img, which I'm pretty sure I have) and that I flashed it correctly, again, I think I have) then there seems to be more going on than just a corrupted/incorrect boot.img.
What next? A dirty flash of the stock rom?
Click to expand...
Click to collapse
did you flash the previous v14 patched boot image again using ODIN? this should work
same boot loop problem prevailed on my s7 active and lenevo k8 and flashing the v14 patched boot image and then making new v15.3 boot image gave a perfectly working magisk, although my redmi 3 was showing same boot loop problem and i have to flash the stock rom ( used twrp to restore nandroid backup but boot loop was not solved )
It seems your lots of permutations and combinations have damaged post_fs config of the kernel so you have only option left is to dirty flash the ROM.
teddy0209 said:
Probably try that... Hope it's not a corrupt boot partition...
Click to expand...
Click to collapse
Sounds ominous. How would I recognise this and fix it?
Supreme Genius said:
did you flash the previous v14 patched boot image again using ODIN? this should work.
Click to expand...
Click to collapse
I don't seem to be able to find the patched_boot.img.tar that I used originally with Odin. I've checked a few different machines and on various SD cards but I only have the unpatched boot.img.
ssteward said:
Sounds ominous. How would I recognise this and fix it?
I don't seem to be able to find the patched_boot.img.tar that I used originally with Odin. I've checked a few different machines and on various SD cards but I only have the unpatched boot.img.
Click to expand...
Click to collapse
Then you need to flash the ROM , if you got another device then you can make a patched v15.3 image and flash it
I used another phone to created a patched_boot.img.tar for v15.3 and flashed that with Odin but that gave me a boot loop. Trying this again but flashing no-verity-opt-encrypt-6.0 afterwards allowed me to get to the pulsating Samsung logo. So giving up on this approach, I dirty flashed my stock ROM and this worked but I was left looking at a pulsating Samsung logo for a nerve-racking 5 mins or more.
Thank you everyone for your help. I have my phone booting up again!
Now I need to work out install the latest Magisk successfully. If I try using the patched_boot.img.tar method with v15.3 then I'm back to the pulsating Samsung logo. Again. Using TWRP to flash the v15.3 zip gives the pulsating Samsung logo. I did select 'Preserve AVB 2.0/dm-verity. I also tried again with a clean stock ROM install and flashed the v15.3 zip and no-verity-opt-encrypt-6.0, as suggested by someone who'd successfully installed v15.3. I'm at a bit of a loss.
One clue, TWRP couldn't see the internal SD card data (iow /data). I wasn't able to check this option in the 'Mount' menu in TWRP either. I think this points to /data being encrypted. TWRP could see it yesterday, so perhaps I've inadvertently encrypted this. I was careful to uncheck 'Preserve force encryption' in Magisk Manager. I guess now that I've unbricked my phone, I should start another thread for this magisk install issue but any help or pointers to relevant threads that I may have missed would be great.
Thanks again for all your help.

Have you installedMagisk v15.x on Samsung S7 G930F?

I soft bricked my G930FD when going from v14.0 to v15 using the in-app update but got it back by dirty flashing my stock ROM thanks to the help I got here.
Now I'd like to install the latest Magisk to get root back but despite reading a lot of threads where people solved similar issues going to v15 on Samsung devices and following their suggestions, I can't get Magisk to work and always get stuck on boot, either a boot loop, or more often, the pulsating Samsung logo.
If I try using the patched_boot.img.tar method with v15.3, which is technique I used originally to install v14.0, then I get stuck at the the pulsating Samsung logo. If I use TWRP to flash the v15.3 zip, I get a boot loop. At that point, flashing the stock boot.img allows me to boot or if I flash no-verity-opt-encrypt-6.0 then I get to the pulsating Samsung logo. I did select 'Preserve AVB 2.0/dm-verity' in Magisk Manager.
I also tried again with a clean stock ROM install and flashed the v15.3 zip and immediately flashed no-verity-opt-encrypt-6.0, as suggested by someone who'd successfully installed v15.3 on an S7, but again, stuck at the pulsating Samsung logo.
One clue perhaps, TWRP couldn't see the internal SD card data (iow /data). I wasn't able to check this option in the 'Mount' menu in TWRP either. I think this points to /data being encrypted. TWRP could see it before I dirty flashed the ROM, so perhaps I've inadvertently encrypted this. I was careful to uncheck 'Preserve force encryption' in Magisk Manager , which seemed to default on.
I'm at a bit of a loss so would really appreciate it if you can tell me how to get up and running with Magisk v15 on my Samsung Galaxy S7 if you've managed this yourself.
Can anyone share how they've done this?

Help with bootloop issue (pettyl)

After installing at least one Magisk module the phone bootloops every 2nd reboot and it is consistent. Flashing a no-verity zip gives a few more reboots before bootlooping but the issue is quite annoying because I need to restore a backup from TWRP every time a bootloop occurs, so I have to reinstall everything again.
Maybe returning to full stock firmware (I have the original boot image, but not the original recovery) can help, but the lolinet mirrors do not have the latest firmware available.
Apparently, wiping data after restoring backup helped a lot, phone has survived 5 reboots so far with 2 Magisk modules flashed
Nevermind, latest reboot was a bootloop, but I think the culprit here is the Magisk Manager for Recovery Mode, I will restore backup again and see if that module is the cause of it
If it helps, TWRP showed an error before cleaning caché:
"E:Error creating fstab"

Stuck in boot loop

Hi, I got a situation here. I had to reinstall the rom in my Note 7 Pro after nearly 2 years from teh last time I had to do it.
Unfortunately, I had no idea that the new Magisk version can't be flashed by custom recoveries anymore. I simply flashed my rom using Orange Fox, restarted to the system, used the cell for 2 days, installed everything I needed, and yesterday I downloaded the latest 24310 Magisk version, flashed it using my custom recovery, and restarted in the system again.
Magisk greeted me with a message that it needed extra setup to be fully functional. I restarted in recovery, nothing happened, restarted to system, Maghisk still stuck in the need extra setup to be functional. I resolved to uninstall it using the app, got an error message in the console, tried restoring images, another error. Tried to reboot to recovery to try to reflash magisk, no more recovey, gone. Used adb to reflash recovery, rebooted to it, now I have a message that says Error opening: 'data/adb/magisk' (operation not permitted). Tried to use the Orange Fox option to remove Magisk, got some error messages Error opening: 'data/adb/magisk' (operation not permitted), but it said it was done. Tried to reboot, stuck in boot loop, back in recovery, dirty flashed my actual ROM, still stuck in boot load.
Any way to delete this locked magisk folder to try to completely remove magisk and try to reinstall it the correct way now? Or the only solution is a complete reinstallation of the ROM formatting all partitions? I haven't tried it yet because after 2 years of doing this procedure I barely remember how to do a clean install correctly.
Blackdragonbird said:
Hi, I got a situation here. I had to reinstall the rom in my Note 7 Pro after nearly 2 years from teh last time I had to do it.
Unfortunately, I had no idea that the new Magisk version can't be flashed by custom recoveries anymore. I simply flashed my rom using Orange Fox, restarted to the system, used the cell for 2 days, installed everything I needed, and yesterday I downloaded the latest 24310 Magisk version, flashed it using my custom recovery, and restarted in the system again.
Magisk greeted me with a message that it needed extra setup to be fully functional. I restarted in recovery, nothing happened, restarted to system, Maghisk still stuck in the need extra setup to be functional. I resolved to uninstall it using the app, got an error message in the console, tried restoring images, another error. Tried to reboot to recovery to try to reflash magisk, no more recovey, gone. Used adb to reflash recovery, rebooted to it, now I have a message that says Error opening: 'data/adb/magisk' (operation not permitted). Tried to use the Orange Fox option to remove Magisk, got some error messages Error opening: 'data/adb/magisk' (operation not permitted), but it said it was done. Tried to reboot, stuck in boot loop, back in recovery, dirty flashed my actual ROM, still stuck in boot load.
Any way to delete this locked magisk folder to try to completely remove magisk and try to reinstall it the correct way now? Or the only solution is a complete reinstallation of the ROM formatting all partitions? I haven't tried it yet because after 2 years of doing this procedure I barely remember how to do a clean install correctly.
Click to expand...
Click to collapse
Reflash the stock unrooted boot.img of your room in bootloader. Use adb
Fastboot flash boot boot.img
Similar problem here...
I tried reflashing stock recovery and stock boot.img - now whenever I reboot it just boots into recovery! I don't seem to be able to boot into system any more...
Any ideas?
I'm running AOSIP on a Xiami Mix Mi 3 - I hadn't updated to the latest Magisk in quite some time (since before the app could do it automatically). I have to use the recovery method.
Steps I took are:
Get recovery.zip from my ROM, patched it through the app, then flashed through fastboot. I rebooted while holding down the up arrow to reboot into recovery, then released for the phone to boot.
I got an error after booting that said "there's an internal error with your device" - and it was super buggy, couldn't tap the screen, super slow to load stuff, etc.... I figured it was a magisk issue, so tried to reflash recovery and boot... Not I'm stuck booting into recovery!
Help.
Edit: so - I think it turns out I have one of those RARE xiaomi devices that DOES have ramdisk even though the app doesn't detect it... Go figure. A clean install of the ROM, followed by patching the BOOT image rather than the recovery image - and we're up and running.

Categories

Resources