Question Updated a magisk module, now phone is bootlooping. Unable to use adb to shell in and fix. HELP! (SOLVED) - OnePlus 9 Pro

So I updated a magisk module, and it's now causing a bootloop. After 2-3 times it boots to stock recovery and sits there. If I power off the phone and connect a cable, I can see the device in adb devices, but I'm unable to shell into it to attempt to fix this:
PS C:\platform-tools> .\adb.exe devices
List of devices attached
c966941e unauthorized
PS C:\platform-tools> .\adb.exe shell
adb.exe: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set
Try 'adb kill-server' if that seems wrong.
Otherwise check for a confirmation dialog on your device.
PS C:\platform-tools>
I've tried killing the adb server like it suggested but that doesn't fix it.
Any ideas how I can get in this thing without having to factory reset?

Flash the original boot.img

I was able to fix it by booting the TWRP recovery image and using the File Manager to delete the module. Oddly enough, after I rebooted, my homescreen pages/shortcuts were all hosed up but I'll gladly take that over a reimage.
In case anyone is wondering, the module that did this was updating the "Busybox for Android NDK" module. Upon installing after fixing it above, it's working fine.

jbradshw said:
I was able to fix it by booting the TWRP recovery image and using the File Manager to delete the module. Oddly enough, after I rebooted, my homescreen pages/shortcuts were all hosed up but I'll gladly take that over a reimage.
In case anyone is wondering, the module that did this was updating the "Busybox for Android NDK" module. Upon installing after fixing it above, it's working fine.
Click to expand...
Click to collapse
I had no issues with that module using Fox's magisk manager

NameIsOptional said:
I had no issues with that module using Fox's magisk manager
Click to expand...
Click to collapse
Yeah I don't know what happened.

Related

[Q] KFU 0.9.8+ not rooting new KF1 w/ 6.3.2

I have tried every version of KFU from 0.9.5 on up, and have reinstalled the KFU drivers multiple times. FFF & TWRP install fine, but when KFU gets to the part where it removes the root checker I get an error:
Attempt to remove root checker
mv: can't rename 'system/bin/check_rooted': No such file or directory
Please wait...
The Kindle then continues to boot up as normal. It then attempts to install SU:
Installing Superuser.apk
Error: Cound not access the Package Manager. Is the system running?
KFU then states that root has been installed, when in fact it has not. I know that I could simply use TWRP to flash CM 10.1 which would have root, but this Kindle is my wife's (I already have CM on mine). I need root to be able to use Titanium Backup and save all of her app data. Any help resolving this would be appreciated!
diskoman21 said:
I have tried every version of KFU from 0.9.5 on up, and have reinstalled the KFU drivers multiple times. FFF & TWRP install fine, but when KFU gets to the part where it removes the root checker I get an error:
Attempt to remove root checker
mv: can't rename 'system/bin/check_rooted': No such file or directory
Click to expand...
Click to collapse
This is normal. Nothing to really worry about.
Installing Superuser.apk
Error: Cound not access the Package Manager. Is the system running?
KFU then states that root has been installed, when in fact it has not. I know that I could simply use TWRP to flash CM 10.1 which would have root, but this Kindle is my wife's (I already have CM on mine). I need root to be able to use Titanium Backup and save all of her app data. Any help resolving this would be appreciated!
Click to expand...
Click to collapse
I've run into this problem before. This is from attempting to install the .apk before the device is booted far enough for the package manager to be available. This can be easily fixed by pausing the script for an amount of time to ensure the package manager is available before continuing with the rest of the script. You should probably contact the developer about it.
You might be able to just install Superuser.apk using the following command:
Code:
adb shell pm install -r /system/app/Superuser.apk
THANK YOU!!!
soupmagnet said:
This is normal. Nothing to really worry about.
I've run into this problem before. This is from attempting to install the .apk before the device is booted far enough for the package manager to be available. This can be easily fixed by pausing the script for an amount of time to ensure the package manager is available before continuing with the rest of the script. You should probably contact the developer about it.
You might be able to just install Superuser.apk using the following command:
Code:
adb shell pm install -r /system/app/Superuser.apk
Click to expand...
Click to collapse
Your response made all the sense in the world (duh moment for me, lol)! I took a look at the batch file for KFU, and located the line of code where it calls the sleep function to wait for the Kindle to boot up:
::Wait for Android to finish booting, and install Superuser.apk.
tools\adb wait-for-device
tools\sleep 20
echo. Installing Superuser.apk
tools\adb install -r files\Superuser.apk 2> nul
I changed the 2nd line of the section to call sleep for 60 seconds instead of just 20. Voila! That did the trick. I have sent a message to the developer as well, so that he can make this simple fix. Thanks again for taking the time to help get me on the right path! :highfive:
diskoman21 said:
Your response made all the sense in the world (duh moment for me, lol)! I took a look at the batch file for KFU, and located the line of code where it calls the sleep function to wait for the Kindle to boot up:
::Wait for Android to finish booting, and install Superuser.apk.
tools\adb wait-for-device
tools\sleep 20
echo. Installing Superuser.apk
tools\adb install -r files\Superuser.apk 2> nul
I changed the 2nd line of the section to call sleep for 60 seconds instead of just 20. Voila! That did the trick. I have sent a message to the developer as well, so that he can make this simple fix. Thanks again for taking the time to help get me on the right path! :highfive:
Click to expand...
Click to collapse
Yeah, 60 seconds may be a bit much LOL, but I'm glad it worked out for you :good:

[Q] Downgrade Issue.

Hello All,
Purchased an Amazon Fire TV from Amazon, it shipped in one day and I have been toying with it for the last few hours. Rooting was easy, as was installing SU, Busybox, Stickmount etc.. However, I am not to the point to where I want to install a custom recovery so I can update to the latest firmware without loosing root. The instructions say I need to downgrade to an earlier firmware in order to do this. My problem is that every time I reboot into recovery it says "Update was not successful" and It boots back to the same version that I started with.
The version I have now is 5.1.1.1.0 fully rooted w/ Busybox. I don't know exactly what I am doing wrong. I have both pushed the update.zip to the AFTV, and I have also put it on a thumb drive. I have tried earlier versions then the one recommended in the guide that I was following. All of this to no avail.
Please help.
Thank you.
Anybody? I was up till little after 3 AM trying to figure this out. Factory reset, re-rooted, nothing seems to work. Has anyone else had this issue?
I had the exact same problem. Try a different firmware download option. I used the "mirror' on AFTVnews.com the first time and had the same fail at the end that you did. I also re installed busybox before I performed the downgrade, so I'm not sure which of the two fixed the problem, but I suspect it was a bad download from the mirror.
roaoro said:
I had the exact same problem. Try a different firmware download option. I used the "mirror' on AFTVnews.com the first time and had the same fail at the end that you did. I also re installed busybox before I performed the downgrade, so I'm not sure which of the two fixed the problem, but I suspect it was a bad download from the mirror.
Click to expand...
Click to collapse
Just tried the mirror. That ended in the same result. I am going to try re-installing Busybox again to see if that has any change.
roaoro said:
I had the exact same problem. Try a different firmware download option. I used the "mirror' on AFTVnews.com the first time and had the same fail at the end that you did. I also re installed busybox before I performed the downgrade, so I'm not sure which of the two fixed the problem, but I suspect it was a bad download from the mirror.
Click to expand...
Click to collapse
Tried re installing busybox that didn't crack it either.
The exact error is "The System Update was not successful." Your AFTV will restart in a few minutes and should resume normal operation.
Any other ideas I can try?
brotherandyslb said:
Tried re installing busybox that didn't crack it either.
The exact error is "The System Update was not successful." Your AFTV will restart in a few minutes and should resume normal operation.
Any other ideas I can try?
Click to expand...
Click to collapse
You need to list exactly what you are doing so we can tell you what you are doing wrong.
I had to do it a couple of times because it didn't work right at first either.
nyder said:
You need to list exactly what you are doing so we can tell you what you are doing wrong.
I had to do it a couple of times because it didn't work right at first either.
Click to expand...
Click to collapse
Ok,
Lets start from the top:
Factory Reset
Watch Video
Sign into Amazon Prime
So no to parental controls
Go to developer options and turn it to on so I can use ADB
Connect with ADB
adb install towelroot
go into towelroot and root
adb install supersu
go into supersu and let it update
adb install busybox
go into busybox and install it and let it symlink
adb the command to turn off updates
Then I follow the guide over at aftvnews.com to downgrade
Download the firmware version you wish to install from the software page
Rename the downloaded file to update.zip
Connect to your Fire TV using ADB
(If you don’t know how, follow up to Step 4 Part 2 in our Windows or Mac guide)
Run the command: adb shell
Run the command: su
(If this is the first time you’ve ever run su, a pop-up will appear on the Fire TV, select Grant)
Run the command: chmod 777 /cache
Run the command: chmod 777 /cache/recovery
Note: If
you see a message saying “No such file or directory”, then run the following two commands:
mkdir /cache/recovery
chmod 777 /cache/recovery
Run the command: cd /cache/recovery
Run the command: echo --update_package=/cache/update.zip > command
Run the command: exit
Run the command (yes, again): exit
Run the command: adb push update.zip /cache
(This assumes the update.zip file you renamed in step 2 is in the same directory as adb, otherwise enter the full path to the file like adb push C:\full\path\to\update.zip /cache)
Once the update.zip file has finished transferring to the Fire TV, run the command: adb reboot recovery
At this point your fire TV should restart and begin installing whichever firmware version you selected.
Click to expand...
Click to collapse
At this point the AFTV restarts and proceeds to install the new firmware about 1/4 way thru it gives the error message and then restarts.

[Guide] Disabling Auto-Updates on Fire Phone

DISCLAIMER: THIS METHOD WORKS ON THE FIRE TV, AND MAY NOT WORK FOR THE FIRE PHONE. IT HAS WORKED FOR ME, BUT I TAKE NO RESPONSIBILITY FOR ANY DAMAGE CAUSED TO ANY DEVICES. USE AT YOUR OWN RISK.
I searched around and couldn't find a way to do this on my own. Some threads suggest deleting system files to get this to work, but I found you can disable OTA updates on the Fire Phone the same way you can with the Fire TV.
You need to have root access to the phone, which requires both:
A) Downgrading your phone to 3.5.0, and installing the ADB. Which you can read about in the first part of B1ackByte's guide HERE.
B) Using towelroot to get root access HERE (Click the symbol, download the apk and run it.)
After you have the ADB and drivers installed on your system, and your phone has been downgraded to 3.5.0, you MUST choose
"Wipe Data and Factory Reset" in the recovery menu before rebooting your phone. If you do not, you can get a couple glitches and hangs... nothing major, but you'll still have to boot into recovery to do the wipe and finish the process.
After you're downgraded, rebooted, and rooted... Install the latest version of SuperSu from HERE then REBOOT AGAIN!!! If you don't, SuperSu might not take over properly.
Open CMD or Command prompt as an administrator, and navigate to where you have the adb.exe, then issue these commands:
adb start-server
adb shell
su
Click to expand...
Click to collapse
Your phone will then ask you to grand permissions to the adb console, click "grant" or "accept" (Depending on the version of SuperSU you have.)
Then Type:
pm disable com.amazon.dcp
Click to expand...
Click to collapse
You should see an output message that says "Package com.amazon.dcp new state: disabled"
And Voila! OTA updates are turned off.
EDIT: I've also read a couple guides about how people have used the Fire HD FirstAide package to install google apps and maintain root, but that process didn't work for me. The Fire Phone (or mine, at least) doesn't come with busybox, and the FirstAide script relies on busybox. You can manually install busybox into the system files of the Fire Phone and give it system permissions, but that is outside the scope of this tutorial.
Also, even after manually installing busybox and granting root permissions to the adb shell running the commands, the script still fails to copy some files because the filesystem isn't EXACTLY the same as the Fire HD. (I may be wrong on this, but I just couldn't get the process to work due to some missing folders on my end.)
I tried this and it worked for me. Thanks!
is that possbile to downgrade 4.6.6 to 3.5 reply quick please guys

Bricked Fire Phone after unroot.

While trying to get Android Pay to work I removed root from my phone using the option in Kingroot's menu and then restarted. Now FireOS doesn't load and doing a factory restart from recovery doesn't do anything either.
I thought I'd just sideload 4.6.3 and restart from scratch, but when I connect my phone in 'sideload from adb' mode from recovery I only get a "Fire" device in device manager. After a minute it gets an error "Device Cannot Start"
Manaully scanning for hardware changes doesn't give me my "Android Composite Device ADB Interface"
Sounds like you don't have the ADB drivers installed correctly. See this post:
http://forum.xda-developers.com/showpost.php?p=62844581&postcount=14
Thank You. That's exactly what was wrong.
I didn't think was would be the problem since I had used that 15 second adb installer last night to get adb working before I messed everything up this morning.
In recovery mode I'm sure it connected to my computer as a different device!
Thanks again.
ekztal said:
Thank You. That's exactly what was wrong.
I didn't think was would be the problem since I had used that 15 second adb installer last night to get adb working before I messed everything up this morning.
In recovery mode I'm sure it connected to my computer as a different device!
Thanks again.
Click to expand...
Click to collapse
No problem. Glad it worked out.
cannot read update.bin
Hi
I have the same problem with my phone. I have downloaded 1.2 gb 4.46.3 fire os update but I am not able to push the package after detecting my fire phone in adb sideload method.
cannot update.bin error was thrown by cmd prompt.
How can I recover my phone . Pls help.
Androidhari said:
Hi
I have the same problem with my phone. I have downloaded 1.2 gb 4.46.3 fire os update but I am not able to push the package after detecting my fire phone in adb sideload method.
cannot update.bin error was thrown by cmd prompt.
How can I recover my phone . Pls help.
Click to expand...
Click to collapse
The problem could be the filename. Microsoft Edge and Internet Explorer download the 4.6.3 update as a .zip file. If your folder options are not set to display all files extensions, go to Veiw> Options> Change folder and search options> View>. Uncheck "Hide extensions for known file types" and click OK. Check the filename for update.bin, if the filename is update.bin.zip, changing it to update.bin should correct your problem.
If the fielname is correct, the file path could be the problem. Try entering the complete path to the file, use quotes around the file path if there are any spaces in the file path (for me the file path is: "C:\Program Files (x86)\Minimal ADB and Fastboot\update.bin").
If you still can't install the update, then see Problem with "cannot read update.bin" in 4.6.4 to 4.6.3 downgrade on how to use Safestrap to install update 4.6.3.
Hi
Even my phone is bricked but when I try to sideload update.bin , cmd prompt throwing error as " cannot update.bin". My fire phone is identified by windows 10 with adb drivers.
Can someone suggest how can we fix this issue?
Thanks
---------- Post added at 01:45 PM ---------- Previous post was at 01:35 PM ----------
Thanks, I will try what you had suggested on windows 10 but I can not use safestrap as except " amzon" logo I can not see anything after power on so I am getting to apply update from ADB using buttons. So how can I install safestrap and king root without turning on browser on mobile.
Thanks
Androidhari said:
Thanks, I will try what you had suggested on windows 10 but I can not use safestrap as except " amzon" logo I can not see anything after power on so I am getting to apply update from ADB using buttons. So how can I install safestrap and king root without turning on browser on mobile.
Thanks
Click to expand...
Click to collapse
You won't be able to install Safestrap or Kingroot unless you can bootup your Fire Phone, so sideloading the update is your only option. It appears that your ADB drivers are installed correctly, just to be sure, see DePingus's post.
Thanks, it worked. My fire phone is up.
Hi a little help if you will please.
I've rooted then installed safestrap. Done back up, factory reset then Flashed c11 rom. All looked great. Made up with the ROM but I've tried to use kingroot to root again but it won't work. I can get in to safestrap recovery but says it's inactive. I've tried to search for the fix but can't find anything directly for my problem just how to root with kingroot. Any help would be great. Thanks.
Can't unbrick it.... tried everything
Hi guys, I installed CyanogenMod on my fire phone and it worked for a while... then started rebooting, but before I could do anything it was just rebooting all the time, then I did a hard reset on fire phone and after that... only adb sideload, safestrap was gone... but... adb works fine, everything gets installed, but after rebooting amazon fire phone is lost in a endless rebooting cycle (just shows up the amaozn logo... if powered via USB it tries to do something else, amazon logo shows up for maybe 2-3s longer....
Boys... did I brick my phone forever? Thanks
Hannes

Kindle fire 8.9 error updating binary in zip

OK, I had my kindle running cyanogenmod 11. I was having problems with some apps running on it, root was acting weird. Root checkers said it was rooted, but some apps that required root weren't installing right.
Fast forward, I thought perhaps I needed to flash the new version. I got into recovery to run it and flash it and this is the error I have.
So all the forums said, just wipe it then it will work. Of course now I have no OS on the thing. TWRP is fine, but I can't use the tablet.
So some other forums suggested it's either a mounting to E:\ problem or a rooting problems. I can get in to ADB, I've pushed many different roms over and they all have similar errors.
All of the Root tools I can find require you to come in the front door. TWRP fails when it goes to 'fix permission' and every time I reboot says , 'root is gone, swipe to fix' but it's not seeming to stick.
Any ideas on how to make sure I can mount the new rom and get this back up and running.
As I said, I've tried many roms, directly downloaded from CM website: Download:
cm-12.1-20160129-NIGHTLY-d2tmo.zip (284.96 MB)
sha1: e461a1dc263d927de3b6748d3b877310e7b1fd39
Download: cm-12.1-20151117-SNAPSHOT-YOG7DAO1K7-d2tmo.zip (286.1 MB)
sha1: bfb989917775ff190b8b795d93c1e439ccf8a514
I'm running TWRP 2.6.0.0 and have a binary ADB driver of 1.0.31. I can ping 4.2.2.2 so I'm pretty sure since the issue is coming from the device itself, and the way it's erroring reminds me of other permission problems I've seen in other devices that it's a root issue.
Is there a simple command line ADB tool or something that I can use to validate/set root?
Thanks!
kyleyarbrough said:
OK, I had my kindle running cyanogenmod 11. I was having problems with some apps running on it, root was acting weird. Root checkers said it was rooted, but some apps that required root weren't installing right.
Fast forward, I thought perhaps I needed to flash the new version. I got into recovery to run it and flash it and this is the error I have.
So all the forums said, just wipe it then it will work. Of course now I have no OS on the thing. TWRP is fine, but I can't use the tablet.
So some other forums suggested it's either a mounting to E:\ problem or a rooting problems. I can get in to ADB, I've pushed many different roms over and they all have similar errors.
All of the Root tools I can find require you to come in the front door. TWRP fails when it goes to 'fix permission' and every time I reboot says , 'root is gone, swipe to fix' but it's not seeming to stick.
Any ideas on how to make sure I can mount the new rom and get this back up and running.
As I said, I've tried many roms, directly downloaded from CM website: Download:
cm-12.1-20160129-NIGHTLY-d2tmo.zip (284.96 MB)
sha1: e461a1dc263d927de3b6748d3b877310e7b1fd39
Download: cm-12.1-20151117-SNAPSHOT-YOG7DAO1K7-d2tmo.zip (286.1 MB)
sha1: bfb989917775ff190b8b795d93c1e439ccf8a514
I'm running TWRP 2.6.0.0 and have a binary ADB driver of 1.0.31. I can ping 4.2.2.2 so I'm pretty sure since the issue is coming from the device itself, and the way it's erroring reminds me of other permission problems I've seen in other devices that it's a root issue.
Is there a simple command line ADB tool or something that I can use to validate/set root?
Thanks!
Click to expand...
Click to collapse
Your TWRP version is out of date. Flash the 2.8.7.0 image from this thread, reboot into TWRP and make sure your TWRP version is now 2.8.7.0, and try flashing CM12.1 after that.
Sent from my Amazon Jem using XDA Labs
monster1612 said:
Your TWRP version is out of date. Flash the 2.8.7.0 image from this thread, reboot into TWRP and make sure your TWRP version is now 2.8.7.0, and try flashing CM12.1 after that.
Sent from my Amazon Jem using XDA Labs
Click to expand...
Click to collapse
HI! thanks for that advice. I wish I could. I've tried several methods, and although I can get into ADB shell, I can't access su:
besides kindle fire first aide and other batch files, I found some manual instructions:
http://forum.xda-developers.com/showthread.php?t=2277105
Here's what it tells me to do (among many other things): I realize this is just backing up stuff that doesn't exist etc, but it's indicative of the problems without having su.
adb shell su -c "dd if=/dev/block/mmcblk0boot0 of=/sdcard/boot0block.img"
adb shell su -c "dd if=/dev/block/platform/omap/omap_hsmmc.1/by-name/boot of=/sdcard/stock-boot.img"
adb shell su -c "dd if=/dev/block/platform/omap/omap_hsmmc.1/by-name/recovery of=/sdcard/stock-recovery.img"
adb shell su -c "dd if=/dev/block/platform/omap/omap_hsmmc.1/by-name/system of=/sdcard/stock-system.img"
mkdir C:\KFHD8Backup
adb pull /sdcard/stock-boot.img/ [C:\KFHD8Backup]
adb pull /sdcard/stock-recovery.img/ [C:\KFHD8Backup]
adb pull /sdcard/stock-system.img/ [C:\KFHD8Backup]
but if I go into adb shell and type any commands, like just simple su:
I get /sbin/sh: su: not found
when I do whoami: I get root
but I get a funky prompt:
~#^[[61;5R
instead of a normal # root prompt.
So I'm kind of stuck because I can't really do anything without the su, and it says I'm root. So can I adb push over the files and mount the right drives or whatever to get it to recognize su. At that point I can install twrp, but i'm sure at that point my existing twrp will work too!
I can't seem to get it into fastboot mode either. When I adb devices it says I'm in recovery, not device and in TWRP it says no OS installed. So my only functioning loader is TWRP. (or however you put that more accurately).
I feel like with adb push working, I should be able to do something to get this back, but all the tools expect you to just push a button, not do it the hard way.
So long story short, if you can point me to a thread that tells me how to update TWRP or how to push SU over with ADB or anything that would be awesome. I"m not a complete turd at this, but I think I broke it using something like kingoroot instead of just using the bin4ry while I still had the cyanogenmod working somewhat. So I'm thinking that's why i got the funky prompt, and that's why my su is gone from where it should be.

Categories

Resources