[guide] how to get out of bootloop while updating - OnePlus 7T Guides, News, & Discussion

At the moment of writing this guide TWRP for our device is not fully working so sometimes it's quite difficult to get out of bootloop we get into while updating the device.
This guide is for rooted users only.
As we know we have to install magisk to inactive slot after OTA sometimes we forget or neglect to remove our modules which is the major reason for such bootloops so not only disabling but removing the modules is the key to avoid such condition, but in case we are into it
just let it be in bootloop and connect your device to the PC and have mini adb and fastboot installed From Here
and put insert the command below
adb wait-for-device shell magisk --remove-modules
wait for device to reboot properly.

Related

[TUT] how to fix swr50 with working fastboot

hi people,i wanna share a fix solution for any smartwatch 3 with working fastboot mode...
so,presuming u already have adb drivers installed lets proceed
https://drive.google.com/open?id=0B14BmzmcIZ4cVDBjRnliUDVXU1k is link to a shared folder with all needed files,inside folder are :
repacked rom 5.0.1 - swr50.zip
stock recovery image - swr50.img
twrp recovery image for old rom version - twrp.img
twrp recovery image for new rom version - twrpnew.img
update packages that can also be sideloaded if watch dosent update itself after first flash
updatep-k.zip -its from verison lwx48p tp lwx48k
then k to d and d to lca43(5.1.1)
so,boot into fastboot and fastboot boot twrp.img (that will boot twrp image on watch).then,adb push swr50.zip /sdcard/swr50.zip
in twrp push install and select the newly copied swr50.zip flashable rom...flash it,then adb reboot
let watch reboot,presuming all went fine,ull watch will boot in 5.0.1 rom,let it connect to phone.inside settings,open options/about,and push built version until u get dev mode...in dev mode enable usb debug,confirm also on phone
so right now u have watch connected to pc with usb debug on....write adb reboot bootloader ,so watch goes in fastboot again
now,flash stock recovery...fastboot flash recovery swr50.img (watch will get the stock recovery),after u can fastboot continue
right now u can update watch,connected to phone,via own update ota service,settings/about/system update,it will download and install next version,the update again and again.if u dont wanna wait thatu can adb sideload files i provided,its actualy stock ota update
so....
adb reboot recovery,select adb sideload,and adb sideload updatep-k.zip,reboot watch and let update,then sideload again updatek-d.zip,reboot and let it update,then again last update
AFTER THIS UPDATE TWRP.IMG NO LONGER WORK,DONT BOOT IT,WATCH WILL ENTER BOOT LOOP,WE WILL BOOT TWRPNEW.IMG.....becouse 5.1.1 updated also boot image,so fastboot twrpnew.img if u wanna use twrp in some way.....
i hope its was helpfull,any questions fell free to leave,im no developer,i just like to play with things
BIG thanx to those who packed,repacked flashes and recovery images!!!!
l
alex_SW said:
hi people,i wanna share a fix solution for any smartwatch 3 with working fastboot mode...
so,presuming u already have adb drivers installed lets proceed
https://drive.google.com/open?id=0B14BmzmcIZ4cVDBjRnliUDVXU1k is link to a shared folder with all needed files,inside folder are :
repacked rom 5.0.1 - swr50.zip
stock recovery image - swr50.img
twrp recovery image for old rom version - twrp.img
twrp recovery image for new rom version - twrpnew.img
update packages that can also be sideloaded if watch dosent update itself after first flash
updatep-k.zip -its from verison lwx48p tp lwx48k
then k to d and d to lca43(5.1.1)
so,boot into fastboot and fastboot boot twrp.img (that will boot twrp image on watch).then,adb push swr50.zip /sdcard/swr50.zip
in twrp push install and select the newly copied swr50.zip flashable rom...flash it,then adb reboot
let watch reboot,presuming all went fine,ull watch will boot in 5.0.1 rom,let it connect to phone.inside settings,open options/about,and push built version until u get dev mode...in dev mode enable usb debug,confirm also on phone
so right now u have watch connected to pc with usb debug on....write adb reboot bootloader ,so watch goes in fastboot again
now,flash stock recovery...fastboot flash recovery swr50.img (watch will get the stock recovery),after u can fastboot continue
right now u can update watch,connected to phone,via own update ota service,settings/about/system update,it will download and install next version,the update again and again.if u dont wanna wait thatu can adb sideload files i provided,its actualy stock ota update
so....
adb reboot recovery,select adb sideload,and adb sideload updatep-k.zip,reboot watch and let update,then sideload again updatek-d.zip,reboot and let it update,then again last update
AFTER THIS UPDATE TWRP.IMG NO LONGER WORK,DONT BOOT IT,WATCH WILL ENTER BOOT LOOP,WE WILL BOOT TWRPNEW.IMG.....becouse 5.1.1 updated also boot image,so fastboot twrpnew.img if u wanna use twrp in some way.....
i hope its was helpfull,any questions fell free to leave,im no developer,i just like to play with things
BIG thanx to those who packed,repacked flashes and recovery images!!!!
l
Click to expand...
Click to collapse
Thanks for putting this together. My sw3 has been stuck on the MM dots / symbols for some time. After several attempts of running various roms, img, simg, XC, etc, I could get no further than the original software issue. With your post, I was able to get it to the LCA43 update. Although, for some reason I could not use the twrp.img in your file list (I found another one) and I could not adb the recovery file (I had to flash it), nevertheless, it provided a way for me to update the sw3. I did not flash the updates, but just let the watch do it. While that was a slow process, it was working so I continued...until.
I could not get the MM update to work though. It downloaded and installed on the sw3. But when booting up, I got the dreaded 4 dots / symbols again. If you are still around and have any ideas of updating this procedure to include the MM updates, it would be much appreciated. Again, the XC does not work for me even though both the repair and update options in the software said they were successfully installed.
Hi!
I really need to do this for activate the NFC and use to check glicemia on the watch.
But i'm stuck almost at the first point.
I already activate the adb on the watch and put him "runnig fastboot".
On the pc I write on command prompt "adb reboot bootloader" and returns: "error: device '(null)' not found"
Anyone can helps?
Regards,
Same position as Moitas
Realy would appreciate if somebody could help me and at the same time moitas. I run windows10 and have the same problem. The device is called Tetra when it shows up in fastboot and I can´t get any driver to work with it. Have tried several differet ones but none seem to fit. Any clever one with a solution I would salute you
@moitas @tobas70 you need to install the correct drivers - http://forum.xda-developers.com/attachment.php?attachmentid=2480396
ajolly said:
@moitas @tobas70 you need to install the correct drivers - http://forum.xda-developers.com/attachment.php?attachmentid=2480396
Click to expand...
Click to collapse
Thanks Ajolly! I finally managed to get it done. As new to this rooting buisness there were a lot of steps that where more complicated than the manual I followed applied
Hi! i have problem after downgrade...
After I push SWR50.zip and reboot, my devices is unauthorized. When i enter in fastboot manually there's any devices (null). I install drivers like You said, and form adb, google. If somebody can help me this i will be very grateful
any one can help me. After failed up SW3 by sideload, they ignored PC conncetion. Try "adb devices", fastboot mode, recovery mode, MTP, - anything happend in device manager.
ajolly said:
@moitas @tobas70 you need to install the correct drivers - http://forum.xda-developers.com/attachment.php?attachmentid=2480396
Click to expand...
Click to collapse
I just got a new SWR50 for the sole purpose of using NFC (with FreeStyle Libre).
On the Win10 PC I don't have "Android Device" as a hardware type. -- I'm not sure if this is causing the problem that in Fastboot (white background) I cannot communicate with the watch from the PC anymore.
Also, when turned on for the first time watch automatically upgrades to M1D64T and I don't seem to be able to stop that and don't seem to be able to downgrade to be able to use this package.
Any suggestions? Thanks
Restore to the latest firmware
After downgrading to LCA43, what would be the easiest way to restore the watch to the latest firmware, is there a real factory reset?
Not pair after downgrade
I have downgraded from version M1D64T to LWX48P and now my phone do not see the watch in bluetooth devices. I tried few things to start BT working like:
- remove Android Wear from phone
- clear Google Play Services
- send few intent through adb like bluetooth.REQUEST_DISCOVERABLE
- return to M1D64T by Sony PC Companion
Bluetooth still not works and I cannot connect to any phone.
Maybe somebody have an idea how to repair my watch?
Ok, I've got another issue when downgrading the watch.
When I get to the Install the swr50.zip it starts to complain.
It says, Unable to mount /cache, Unable to mount data and so on. So clearly something is not going right at this point (or earlier more likely).
What's going wrong and how do I fix it?
Same thing here - /data can't be mounted read/write
I'm seeing the same thing. I can use "adb shell" and "mount -r /data" (readonly) which works, but when I try to mount it normally ("mount /data") I get an error about a bad argument. This is certainly related to the errors re. not being able to mount /data, which I see when I try using twrpnew.img to install the SWR50.zip image.
I'm stuck!
Maybe a solution...
(I'm still going through applying updates, but this looks hopeful!)
I found that apparently the "unable to mount data" seems to have to do with the /data partition (in my case, "/dev/block/mmcblk0p32") having some internal flag which seemed to not allow it to be mounted read/write. I could do "adb shell" to get to the watch and then to "mount -r /data" and that worked just fine. I decided to rebuild the entire /data partition. Use "adb shell" to get a shell prompt on the watch, do "mount" to make sure /data is NOT mounted. If it is, do "umount /data", which should unmount it. you can see what's being mounted where via "cat /etc/fstab". You want to rebuild the disk partition which will be mounted on /data. On my watch this was "/dev/block/mmcblk0p32", so "/sbin/make_ext4fs /dev/block/mmcblk0p32". Then "exit" to get back to your system where you're running adb.
So, I followed the "How to install NFC on Sony Smartwatch3" instructions (I'm not allowed to post a link or else I would, but you probably have these instructions already.)
(I'm doing the "downgrade" part of the instructions, which is where the "install" failed.)
Just after "fastboot boot twrpnew.img", I inserted the above work to rebuild the /data partition. DO NOT mount /data after having rebuilt it! You should also should see that /cache is NOT mounted at this time. Do "exit" to get back to your adb system and continue following instructions at "adb push SWR50.zip /sdcard/", and the "install" worked for me after this!
frippegubben said:
Ok, I've got another issue when downgrading the watch.
When I get to the Install the swr50.zip it starts to complain.
It says, Unable to mount /cache, Unable to mount data and so on. So clearly something is not going right at this point (or earlier more likely).
What's going wrong and how do I fix it?
Click to expand...
Click to collapse
Sony Smartwatch SWR50 unable to install SWR50.zip
Hello Friends,
Iam trying to configure NFC on my Sony Smart Watch 3. After command adb push SWR50.zip /sdcard/, I try to intall SWR50.zip, It's not flashing.
It says Failed with message " UNABLE TO MOUNT" etc
Can you kindly help please
KIR71 said:
Hello Friends,
Iam trying to configure NFC on my Sony Smart Watch 3. After command adb push SWR50.zip /sdcard/, I try to intall SWR50.zip, It's not flashing.
It says Failed with message " UNABLE TO MOUNT" etc
Can you kindly help please
Click to expand...
Click to collapse
I was working with a Sony Smartwatch 3 a few years ago (using the NFC to read a Blood Glucose sensor) and encountered this same error during installation of some of the code. Here are my notes on the solution, in case it helps:
I found that apparently the "unable to mount data" seems to have to do with the /data partition (in my case, "/dev/block/mmcblk0p32") having some internal flag which seemed to not allow it to be mounted read/write. I could do "adb shell" to get to the watch and then to "mount -r /data" and that worked just fine. I decided to rebuild the entire /data partition. Use "adb shell" to get a shell prompt on the watch, do "mount" to make sure /data is NOT mounted. If it is, do "umount /data", which should unmount it. you can see what's being mounted where via "cat /etc/fstab". You want to rebuild the disk partition which will be mounted on /data. On my watch this was "/dev/block/mmcblk0p32", so "/sbin/make_ext4fs /dev/block/mmcblk0p32". Then "exit" to get back to your system where you're running adb.​
Hope this helps! Good luck!
Thank you for this tutorial, I'm having the same problem. My swr50 stuck on the dots screen after battery replacement. I tried to follow the steps above but my system does not see the device at all.
I tried to add legacy device drivers but it come back with code 10.
After connecting swr50 device manager don't detect any device and I can't install drivers. So when I run ADB I get message "device null" Did someone had the same problem? Is there any solution?
Help please, When I plug in my watch to the charger sometimes it gets stuck on sony logo and sometimes doesn't display anything also tried connecting to pc but it keeps on booting also tried pressing the power key to get into the fastboot mode but doesn't work.

magisk instructions

guys please give me noob friendly instructions for installing magisk latest ver on my lenovo p2 15.1 latest build .
Same
First make sure you have USB debugging enabled on your phone, then install ADB on your PC. Connect the phone to the PC and in the installation folder (ADB > platform-tools) shift right click and choose Open command window here. Type adb devices and authorize your PC on the phone. Download the ROM and extract boot.img from it, transfer it to your phone. On the phone install Magisk Manager and patch the boot.img (Install > Patch boot image). Transfer patched_boot.img back onto the PC (to the ADB > platform-tools folder), then boot your phone into fastboot (VOL down and POWER buttons). Repeat the Open command window here step and type fastboot flash boot patched_boot.img. Reboot your phone (fastboot reboot). You are now rooted on custom ROM.
After installing magisk , do I need to install any module to prevent boot loop like f2fs loop module etc .
Check if you can install modules. If you're facing problems, then you will need to change a few things. The "cannot mount magisk_merge.img" issue for example can be solved by patching and flashing boot image from here https://forum.xda-developers.com/lenovo-p2/development/kernel-f2fs-upstreamed-kernel-twrp-t3845976. I tried tinkering with modules for it and ended up bricking my phone. I would also recommend using TWRP from this thread, it got rid of my second problem (which I now forgot).
Just remember that you will need to flash the patched custom kernel after any ROM update.

Bootloop Caused by a Magisk module, can't use adb commands..

Magisk module causing bootloop in 10.0.12/10.3.4 (Indian) oneplus 7T update , can't use adb as it is disabled in recovery, I even flashed back stock boot image to enable USB debugging but it didn't worked out..
Patched boot image of 10.3.4 /10.0.12 with magisk core only enabled will solve the problem..
I know this is a common case for oneplus 7t users as no full fledged custom recovery is available So mentioning your methods here how you escape from this situation will be helpful to other users....
Stock recovery w/ adb enabled, can mount data re (namely /data/adb/modules/) located in this thread:
https://forum.xda-developers.com/oneplus-7t/development/recovery-adb-shell-enabled-t4024661
I just created a recovery for 10.0.12 global. It may work for all devices.
To flash/use from the command line while at the bootloader:
fastboot reboot fastboot
fastboot flash recovery (filename).
fastboot reboot bootloader
Choose reboot to recovery.
Enter your pin to decrypt
Adb should work and you should be able to disable modules in /data/adb/modules/. Reboot and the module should be disabled and you can then delete it from magisk manager.
Hope this helps
Uraniam9 said:
I know this is a common case for oneplus 7t users as no full fledged custom recovery is available So mentioning your methods here how you escape from this situation will be helpful to other users....
Click to expand...
Click to collapse
The way i remove my modules with out installing any custom recovery is just by turning off the phone, connect to pc, go to command prompt, type the path of the folder where fastboot and adb is, type the following command: adb wait-for-device shell magisk --remove-modules,(while phone is off) hit enter turn phone on wait for it to get to the boot screen it will reboot, once it reboots modules will be uninstalled.
Mind you that I have never installed or modified the recovery of my OnePlus , I bought it and just unlocked the bootloader. My model is 1900

Magisk Method for my phone, XT1952-T, doesn't seem to be working

From what I understand, the REVVLRY is just the Moto G7 Play rebranded. From that, I assumed that the method of using Magisk to root Moto devices would also work for the device (Unlocking bootloader, patching a file with Magisk using the stock firmware [learned that the hard way, ty sd_shadow], flashing that file with ADB, rebooting).
However, when finishing this and rebooting the phone, instead of "bad key" or "N/A" showing up, a serial code-like text is in its place. I hadn't taken the time to figure out what it actually is or means, but all I know is that it gets stuck on that screen, forcing me to use LMSA again which successfully returns the phone back to normal.
I am not a professional in development or code, but one thing I can point out is that the final number of the build number is different from my current one (file QPYS30.85-18-9-8 vs device QPYS30.85-18-9-10). Maybe this could be the issue? Although I have seen threads that managed to root even with a different version. Is there any potential reason that this happens? And what guide should I follow to root the REVVLRY if it is possible?
A question I probably should have asked from the start; about how long should I wait for the phone to reboot after Magisk is flashed? I may have just been impatient with the phone and not given it enough time to finish whatever it needed to.
Try this method instead:
Reflash stock and boot normally > (unlock bootloader if you haven't already) > reboot into bootloader > fastboot boot twrp > adb sideload magisk zip > reboot into system > install magisk apk
adb: sideload connection failed: closed
adb: trying pre-KitKat sideload method...
adb: pre-KitKat sideload connection failed: closed
This is what I get when doing sideload with the magisk.zip. Is this normal, or is this already a sign of doing something wrong?
Thfaro said:
adb: sideload connection failed: closed
adb: trying pre-KitKat sideload method...
adb: pre-KitKat sideload connection failed: closed
This is what I get when doing sideload with the magisk.zip. Is this normal, or is this already a sign of doing something wrong?
Click to expand...
Click to collapse
Looks like the ADB connection isn't getting established. In TWRP, make sure to go into the Options (I think) mention and select the "ADB Sideload" option.
It seems to have worked, neither TWRP nor the Command returned any bad results. From here, do I continue as normal from the Magisk method?
Thfaro said:
It seems to have worked, neither TWRP nor the Command returned any bad results. From here, do I continue as normal from the Magisk method?
Click to expand...
Click to collapse
Yeah, after you flash the Magisk.zip, reboot back into the OS, rename Magisk.zip into Magisk.apk, and then install it like a normal app. Open it up and it'll detect root.
Flashing the zip went well, so I opened the app after renaming it and the "Installed" says N/A. Do I continue from there? I am sorry about all the questions by the way, it's my first go at rooting, and I haven't proven successful so far lol
Just to rule out the possibility of using Magisk to then patch the file like normal, sure enough, I get the same text. This time I managed to get a picture of it, though, not very clear.
The second picture is what happens after I wait for a bit. I'm going to put the phone back to the state after the zip flash with TWRP though.
Edit: Redoing all the step and not continuing forward, the string of text also seems to happen anyways, but I do manage to get past it and start the phone like normal. Magisk still says N/A however.

How To Guide How to get out of a bootloop

Just managed to get myself out of a bootloop I caused by freezing the wrong service (com.android.location.fused) with Titanium. Maybe someone will find this useful:
Basically, adb is available for a short period of time while the phone is booting up, so if you're quick enough you have a few seconds to open an adb shell, type su and then pm enable com.android.location.fused (or whatever other commands you need to fix stuff).
I'm glad this worked because we don't have an installable recovery right now, and I'm not sure if there's any other way to get a shell working on the phone...
If anybody else can contribute an alternative method I think we'd all appreciate it. Is there a working recovery image we can RAM-boot into with fastboot without installing? Or any shell that will work from a boot image?
BTW if you suspect the bootloop to be caused by a Magisk module, keeping VOLUME DOWN pressed while the phone is starting (while the Android/Xperia logos are showed) is supposed to make Magisk start in "safe mode" (all modules disabled).
Please note that modules will remain disabled when you do this, they're not disabled just for that boot. You'll have to go into Magisk end re-enable them. Also the deny list will be cleared and "enforce deny list" will be disabled, so SafetyNet will not pass and apps on the list will stop working until you re-enable those.
You'd probably want to enter fastboot by turning the phone off and pressing the volume down while connecting the usb cable. From this mode you can also use "fastboot reboot recovery" from you computer to enter the built in recovery.
Does the builtin recovery come with a shell? I thought it just lets you do factory reset.

Categories

Resources