adb sideload connection failed: no devices/emulators found - Xiaomi Mi A2 Lite Questions & Answers

I have the Xiaomi Mi A2 Lite 1.4.3 drivers installed and keep getting the error when I try to ADB Sideload "adb sideload connection failed: no devices/emulators found" error
Phone Statistics
- Rooted with Magisk
- Boot Loader Unlocked
im trying to install TWRP following this guide the "the custom droid" install-twrp-recovery-root-xiaomi-mi-a2-a2-lite
and I can load the TWRP img via "fastboot boot" command but once I do the ADB Sideload I get the above error ive never had this issue before years ago with Samsung phones but with the Xiaomi im at a loss
is there a way to flash the kernal with TWRP while in the ROM

Did you enable ADB sideload from "Advanced" tab in TWRP?

yes I clicked advanced then adb sideload and it does its thing but when i do the command on pc in cmd prompt adb sideload xxx.zip i get the error as stated above

Related

[Q] Q - Undo Simple Root, ADB & Bootloader Issues

I have completed SimpleRoot 1.47 and want to go back to 100% stock, non-rooted, non-nand. I know there is a wealth of information here, and have tried searching for the resolution for the past two and a half hours with no luck.
Here is what I've done so far:
I have tried simply using the RUU_Supersonic_1.32.651.1_Radio_1.39.00.04.26_release_171253 but that gives me the "Error 140 Bootloader Version" issue. Trying to install from the sdcard from a .zip file returns "Main Version is older - update fail!"
I there went to Toast's Part 2 (as I found I was supposed to) but cannot follow his directions. First I get the "No such file or directory" error when trying to issue the "cat" command. I then tried "adb push" and "adb shell mount /sdcard"; both these commands return the error "adb: not found".
Trying "adb remount" lists the error "adb: not found" again. If I try "adb remount" before "adb shell" I get the error "remount failed: invalid argument"
Device Details:
Recovery RA-evo-v1.7.0.1
HBoot 0.79.0000
Radio 1.39.00.04.26

Can't seem to catch a break - adb and fastboot issues

Hey y'all,
I am rooting / rom-ing my third KF.
I could not get TWRP to install so I installed CWM that comes with the KFU
I installed Jandycane and the most current gapps
From then on, the Kindle gets stuck at the boot animation
I have tried other options in KFU, but everything involving fastboot does not work. The kindle shows up as a composite device in the device manager, and is able to be adb-ed into.
In KFU, I see the bootmode being 4000. When I tried the idme command to change it to recovery, it told me that it could not accept the idme command.
I've tried going using the adb shell to push fiels and create directories, but have failed. Su does not work, mkdir does not work, and chmod does not work.
Additionally I have tried the KF Unbrick 1.1 and none of the options seem to do anything.
I am running out of options here. I have tried these procedures on two PCs without avail.
Before I installed the current rom, I have made a backup of the stock rom. Is there any way I could adb into the device and restore it? Would this be a valid way to fix this up?
Can anyone suggest anything else that I have not tried?
Anyone?
When I try to push fbmode from here: http://forum.xda-developers.com/showthread.php?t=1414832
Code:
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>adb push fbmode /data/local/tmp
failed to copy 'fbmode' to '/data/local/tmp': No such file or directory
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>
Now lets see if I can escalate my privileges
Code:
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>adb shell
[email protected]:/ $ su
su
Segmentation fault
[email protected]:/ #
Now lets see if I can push fbmode regardless
Code:
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>adb shell
[email protected]:/ $ cd /data/local/tmp
cd /data/local/tmp
/system/bin/sh: cd: /data/local/tmp: No such file or directory
2|[email protected]:/ $ cd /data/local/
cd /data/local/
/system/bin/sh: cd: /data/local: No such file or directory
2|[email protected]:/ $ cd /data/
cd /data/
[email protected]:/data $ ls
ls
opendir failed, Permission denied
255|[email protected]:/data $
So much for adb ... how about that fastboot
Every time I do anything with fastboot it says waiting for device:
Code:
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>fastboot -i 0x1949 flash recovery twrp.img
< waiting for device >
Are there any devices showing?
Code:
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>fastboot devices
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>adb devices
List of devices attached
0123456789ABCDEF device
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>
fastboot does not see any devices whereas adb does...
I have tried sending the fastboot command while the device is off and then turning it on. The kindle just hangs at the kindle fire screen.
EDIT: I switched computers, and it got back into previous state at being stuck at the animation screen
This is what happens when I try to install TWRP in KFU:
Code:
Installing TWRP...
If we get stuck here for awhile, power the kindle on and off a few times.
You should also check device manager for "kindle" If so, rerun the driver
installer that came packaged with KFU.
***********************************************
* Activating Fastboot (4002) *
***********************************************
failed to copy 'files\fbmode' to '/data/local/fbmode': No such file or directory
Unable to chmod /data/local/fbmode: No such file or directory
/system/bin/sh: /data/local/fbmode: not found
The kindle has been told to reboot in Fastboot Mode.
< waiting for device >
Can you actually put your device into fastboot mode? You can only use fastboot commands when the bootloader has put the device into fastboot mode. If you can get output from any adb commands, you are not in fastboot mode. Look at this guide and see if you can put the KF into fastboot mode...
http://forum.xda-developers.com/showthread.php?t=1668159
What bootloader do you have installed on the device? (Describe the first bootlogo you see. Refer to the above guide.)
What error do you get when you attempt to set the bootmode with idme?
Where are you running your adb commands? When you are stuck on the boot animation or in recovery?
Can you even get to your recovery?
My guess is you've somehow corrupted the system software on your ROM installation. If you can get to recovery, you'll probably need to reflash your ROM. If you can get the device into fastboot mode, you can get to recovery. If can't do either of those, you'll need a factory cable or be willing to open up the case.
kinfauns said:
Can you actually put your device into fastboot mode? You can only use fastboot commands when the bootloader has put the device into fastboot mode. If you can get output from any adb commands, you are not in fastboot mode. Look at this guide and see if you can put the KF into fastboot mode...
http://forum.xda-developers.com/showthread.php?t=1668159
What bootloader do you have installed on the device? (Describe the first bootlogo you see. Refer to the above guide.)
What error do you get when you attempt to set the bootmode with idme?
Where are you running your adb commands? When you are stuck on the boot animation or in recovery?
Can you even get to your recovery?
My guess is you've somehow corrupted the system software on your ROM installation. If you can get to recovery, you'll probably need to reflash your ROM. If you can get the device into fastboot mode, you can get to recovery. If can't do either of those, you'll need a factory cable or be willing to open up the case.
Click to expand...
Click to collapse
That would make sense. I cannot change the bootmode from 4000, so that's why fastboot does not work. I feel dumb for not thinking this through.
It has CWM installed as I could not load TWRP initially due to a poor connection.
This is what I get when I try to change the bootmode:
Code:
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>adb shell su -c 'idme bootmode 4002'
Segmentation fault
<idme> write 4002 to offset 0x1000
C:\Users\xxx\Desktop\Kindle Fire Utility\tools>adb shell idme bootmode 4002
<idme> Invalid permission
I cannot get into recovery as I cannot get the tablet to boot into anything but the ROM istelf (or try to, as it never boots into anything but just loops the boot animation)
Tell me about this factory cable. I'm sure I have it somewhere among all of my micro USB cables...
The boot pattern is as follows: kindle fire (white orange/stock) -> jandycane boot animation that runs forever
There is no triangle or any press the power button to boot into recovery.
http://forum.xda-developers.com/showpost.php?p=30376760
soupmagnet said:
http://forum.xda-developers.com/showpost.php?p=30376760
Click to expand...
Click to collapse
I cannot get the kindle to boot into a ROM, so I cannot use the terminal app.
Can I get an adb shell and push these files?
Also, per my post above, it seems that something sketch is going on with my superuser settings...
Yes, if you have a working adb, you can absolutely push those files. The path will be slightly different though. Instead of ~/local/tmp, you will push the files to /data/local/tmp then execute:
Code:
adb shell chmod 755 /data/local/tmp/rcmode
adb shell /data/local/tmp/rcmode
Looking through your other posts I see you are trying to invoke the shell and enter the commands seperately. Try again, but only this time add "adb shell" to the command itself, as above, and see if that makes a difference.
Also, I've seen both /data/local and /data/local/tmp used but I've always used /data/local/tmp
[Edit:] if you still get a "No such file or directory" error, see if you can create it:
Code:
adb shell mkdir /data/local/tmp
Zlatty said:
I cannot get the kindle to boot into a ROM, so I cannot use the terminal app.
Can I get an adb shell and push these files?
Also, per my post above, it seems that something sketch is going on with my superuser settings...
Click to expand...
Click to collapse
KFU's included version of CWM recovery does not flash ICS (and very likely JB) ROMS correctly. This is a bug known to corrupt the flash.
It not likely you'll be able to do anything meaningful with the system currently installed on your Kindle Fire. Unfortunately for you, that probably includes using idme or pushing anything that might help you change bootmodes. Of course, I may be wrong and you might find another way out of the mess, but the easiest way for you to fix this is to use a factory cable, put the KF into fastboot mode, flash TWRP, boot into recovery so you can flash a new bootloader and ROM.
factory cable...
http://forum.xda-developers.com/showthread.php?t=1550999
fastboot mode...
http://forum.xda-developers.com/showthread.php?t=1668159
beginner's guide...
http://forum.xda-developers.com/showthread.php?t=1552547
supplement for rooting... installing a ROM... etc...
http://forum.xda-developers.com/showthread.php?t=1638452
EDIT: You can try what soupmagnet suggested while I was typing out my post, but you've already shown that you cannot access the /data partition. I think it's going to be something more than simply just an unmounted partition.
I hadn't really thought about mounting the data partition...it's worth a shot either way.
soupmagnet said:
I hadn't really thought about mounting the data partition...it's worth a shot either way.
Click to expand...
Click to collapse
Well my adventure just keeps getting worse and worse. I charged the kindle last night to ensure enough battery life for today. It is suck at the kindle fire logo now. I have the drivers loaded correctly and my computer sees the kindle. However I cannot adb or fastboot the device. It also went from composite device to adb device in the device manager.
EDIT:
Was able to install FFF and got to boot into recovery. CWM 5.2.0.7.
In adb I tried to get super user permissions
C:\android-sdk-windows\platform-tools>adb shell
~ # su
su
/sbin/sh: su: not found
~ #
Click to expand...
Click to collapse
What are my options at this point. KFU cannot download and install TWRP. I cannot manually push it since I dont have su. KFU's install super user function does not work as it tries to install TWRP.
Zlatty said:
Well my adventure just keeps getting worse and worse. I charged the kindle last night to ensure enough battery life for today. It is suck at the kindle fire logo now. I have the drivers loaded correctly and my computer sees the kindle. However I cannot adb or fastboot the device. It also went from composite device to adb device in the device manager.
EDIT:
Was able to install FFF and got to boot into recovery. CWM 5.2.0.7.
In adb I tried to get super user permissions
What are my options at this point. KFU cannot download and install TWRP. I cannot manually push it since I dont have su. KFU's install super user function does not work as it tries to install TWRP.
Click to expand...
Click to collapse
Ok, so while I was in CWM, I mounted the SD card, downloaded and transfered a flashable TWRP found here http://forum.xda-developers.com/showpost.php?p=28664718&postcount=127
I flashed the zip and now I have TWRP working.
Zlatty said:
Ok, so while I was in CWM, I mounted the SD card, downloaded and transfered a flashable TWRP found here http://forum.xda-developers.com/showpost.php?p=28664718&postcount=127
I flashed the zip and now I have TWRP working.
Click to expand...
Click to collapse
I could not get twrp to boot into normal. So I used KFU to change to 4000 mode.
Code:
***********************************************
* Activating Normal (4000) *
***********************************************
< waiting for device >
... OKAY [ 0.081s]
finished. total time: 0.082s
rebooting...
finished. total time: 0.001s
The kindle has been told to reboot in Normal Mode.
Press any key to continue . . .
Everything went better than expected.... w00t!

adb push command return permission denied error?

Hi,
I tried to load a rom.zip file on to sdcard using adb push . It returned a permission denied error.
I did not see the file in the sdcard so I know the file not loaded.
Other adb command work just fine.
What did I do wrong ?
Thanks for your help
Boot into recovery before issuing your adb commands.
soupmagnet said:
Boot into recovery before issuing your adb commands.
Click to expand...
Click to collapse
Thanks. It works.
Can I do the same using TWRP ? what function of Twrp will do the same as adb push ?
Thanks
You can "Mount" your sdcard to USB.

[HELP] How to enable adb sideload in recovery mode?

I was following this thread http://en.miui.com/thread-183258-1-1.html for resizing system partition. ADB worked fine when phone was switched on and "adb shell" command worked fine. But when I rebooted into recovery mode and typed the same command I got this "/sbin/sh: su: not found" error. I tried to mount /system in recovery mode but in vain.
Please guide!
Thanks!
make sure u have rooted
boot into twrp
umount data cache and system and also disable mtp
use twrp filemanager go to system/bin chmod to 755 and copy parted to system/bin
now u can try adb shell

ADB help

By Hashcode, Senior Recognized Developer on 1st February 2013, 10:57 AM over 5 years ago
STEP 1. Backup your stock partitions to your own HD for later if you need disaster recovery:
Code:
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" # This will take a few minutes
adb pull /sdcard/boot0block.img
adb pull /sdcard/stock-boot.img
adb pull /sdcard/stock-recovery.img
adb pull /sdcard/stock-system.img # This will take a few minutes
with that being said here is what happens, i can see adb is working
C:\adb>adb devices
List of devices attached
B0CC060324930545 device
C:\adb>adb shell su -c "dd if=/dev/block/mmcblk0boot0 of=/sdcard/boot0block.img"
/system/bin/sh: su: not found
C:\adb>
I could go on on but, that would be more gibberish.
So, what is wrong? Did the commands change? Is my path set wrong on my pc? Is there a updated thread i just have not come across yet? Anyone?
I'll thank you now for any help
Nothing changed. If you get the device to show up with the adb devices command, then everything's theoretically set up. The only reason you're getting an error with su not being found is that you aren't rooted. Here's a quick way to get root (like actually super simple, considering you already have ADB working):
1) download the attached 8.1.4 bootloader file (this is ripped straight from my Kindle before I "upgraded" to 8.5.1 to test this out). you may consider placing it in the same folder as the adb program. Also download SuperSU and the latest TWRP build for this device.
2) shut down the kindle and make sure it's plugged in.
3) run fastboot -i 0x1949 getvar product, then power the kindle on. when you see "fastboot mode" on the kindle, you should see something in the command prompt that begins with "Jem". if you do, then it's working.
4) type fastboot -i 0x1949 flash bootloader jem_8-1-4_bootloader.img to flash the 8.1.4 bootloader. this is ESSENTIAL because the kindle won't boot custom (unsigned) images otherwise. more explanation below...
5) next, type fastboot -i 0x1949 flash recovery twrp.img, where twrp.img is the file name of the TWRP image you downloaded earlier.
6) type fastboot -i 0x1949 oem recovery to kick the Kindle into recovery mode. if all goes well, you should see "TWRP" on your device after a few moments.
7) copy the SuperSU zip you downloaded to the kindle's internal storage. then on the kindle, tap Install. Next, on the side menu to the left, swipe up from the bottom and tap "sdcard" (referring to the internal storage that you see on the computer when the kindle's plugged in). Tap the SuperSU .zip, and then swipe where indicated. Feel free to reboot the system, and then voila, you're rooted. You should be able to run those backup commands. As a bonus, you won't have to download TWRP or the bootloader image from that virus-laden d-h.st site - avoid it like the plague.
8) Because TWRP's already flashed, you can type adb reboot recovery from the stock OS to begin flashing a new ROM right away.
A couple side notes...
1) Because you've flashed TWRP, a custom recovery, there is no need whatsoever to run the stock recovery backup command. It's already been overwritten, and if you really need it (which, again, is highly doubted because it only lets you run a factory reset), you can actually extract the recovery image from the system partition. Just run adb pull /system/recovery-prod.img stock-recovery.img instead of the adb shell su... stock-recovery.img one.
2) You have to flash the 8.1.4 bootloader because the one you currently have is more than likely a newer version. Custom ROMs (and even recoveries like TWRP) rely on an exploit in the 8.1.4 bootloader in order to trick the device into running the image (and newer bootloaders have this exploit patched already). So technically, because the exploit has to be run every time, the bootloader is never "unlocked" - merely tricked. Without the older bootloader in place, you get what is referred to as the "red screen of death". It's not pretty, but it's not permanent either. (Just power off the kindle, and then run the fastboot command involving "getvar product" to get it to the bootloader so you can flash the 8.1.4 bootloader and go forward.)
Hope this helps!

Categories

Resources