Unable to Lock Moto E (condor) Bootloader the second time. - Moto E Q&A, Help & Troubleshooting

I am not a developer, but would like to consider myself an advanced user.
After unlocking the bootloader, I have installed custom ROMs on three different devices at different times. I have also installed the stock ROM. But have never locked the bootloader back.
However, on the current device (that was looping through the bootloader), I installed the stock ROM (RETAILDSDSALL_XT1022_4.4.4_KXC21.5-40_cid7_CFC.xml) and locked the bootloader. Successfully updated it to the official OTA Lollipop 5.1.
After that, I just tried my luck to install Ubuntu Touch (ported actually for Moto G [falcon] by h2o64, based on this thread). I unlocked the bootloader again for this. The install was 'successful' (there were no errors surprisingly), but the device obviously did not boot.
Now, I wanted to reinstall the stock firmware on the device. This time however, it fails at this command:
sudo fastboot flash partition gpt.bin
Here's the result >
target reported max download size of 299892736 bytes
sending 'partition' (32 KB)...
OKAY [ 0.087s]
writing 'partition'...
(bootloader) Preflash validation failed
FAILED (remote failure)
finished. total time: 0.667s
I have used fastboot in Linux all the other times I said I installed custom and stock ROMs.
However, I tested with mfastboot on Windows 10 as well, with no luck.
I am also able to successfully install TWRP recovery on the device and erase "system", "cache" and "userdata" using fastboot. However, cache and dalvik cache removal fails on TWRP.
Finally, although the partition flash command (which I personally understand as creating the partition table - correct me here please) and the motoboot.img flash command failed, I ran the rest of the commands and successfully installed the stock ROM mentioned above. However, this time, the "fastboot oem lock" command fails.
Any suggestions would be of great help... (it's not my phone)

Related

Tried to flash Marshmallow factory image, but failing

So I tried the flash-all to update to new version, and it failed with the system.img error everyone talks about.
I saw that that was common, so I went ahead with flashing each image separately. However, when I try to flash the bootloader, I get the following error:
E:\adb\adt-bundle-windows-x86_64-20131030\adt-bundle-windows-x86_64-20131030\sdk
\platform-tools>fastboot flash bootloader boot.img
target reported max download size of 518205818 bytes
sending 'bootloader' (8278 KB)...
OKAY [ 0.555s]
writing 'bootloader'...
(bootloader) Device State : Unlocked
(bootloader) zip header checking...
(bootloader) shift signature_size for header checking...
FAILED (remote: header error)
finished. total time: 1.143s
Any idea how to fix this? Googling it didn't come up with anything. I just downloaded the newest version of fastboot by updating the android SDK today, so I don't think it's that.
I got the exact same error when I tried flashing my Nexus 5, before attempt my Nexus 9. I actually uninstalled the SDK and dowloaded and installed a whole fresh version and the Flash All script worked fine after that for both the N5 and N9. Both have been running great! The animations, volume slider for exampt, are so much smoother in M. Lots of little tweaks.
If it's working properly on the N9, fastboot will sparse the System image and send it to the device in multiple uploads and flashes.
Of course you would have failed. You have done it the wrong way. The bootloader command should be like:
fastboot flash bootloader bootloader.img
but you flashed bootloader with kernel boot.img

Mistake in fastboot

I made a bootlogo with Moto Boot Logo Maker (http://forum.xda-developers.com/moto-g/themes-apps/app-motorola-boot-logo-maker-source-t2848667).
But when I tried to install the bootlogo via fastboot, I did the mistake of try to flash 'boot' instead of 'logo'.
I tried to flash bootlogo in 'boot' partition 3 times, and now I don't know what to do.
Please help, what to do now?
I don't know if I can turn off my phone or try to restart, I don't know if it'll start again or if it'll hard brick because I tried to flash 'boot' partition.
What can I do? Will I need to download original firmware and flash boot with its correct image?
Computer Logs
Code:
fastboot flash boot bootlogotest.bin
target reported max download size of 299892736
sending 'boot' (597 KB)...
OKAY [0.047s]
writing 'boot'...
(bootloader) Invalid boot image
FAILED (remote failure)
finished. total time: 0.094s
fastboot flash boot bootlogotest.bin
target reported max download size of 299892736
sending 'boot' (597 KB)...
OKAY [0.062s]
writing 'boot'...
(bootloader) Invalid boot image
FAILED (remote failure)
finished. total time: 0.094s
fastboot flash boot logo.bin
target reported max download size of 299892736
sending 'boot' (421 KB)...
OKAY [0.078s]
writing 'boot'...
(bootloader) Invalid boot image
FAILED (remote failure)
finished. total time: 0.094s
Phone Logs
Code:
Fastboot Reason: Reboot mode set to fastboot
USB connected
cmd: getvar:partition-type:boot
cmd: getvar: max-download-size
cmd: download:000954e8
cmd: flash:boot
Mismatched partition size (boot)
cmd: getvar:partition-type:boot
cmd: getvar: max-download-size
cmd: download:000954e8
cmd: flash:boot
Mismatched partition size (boot)
cmd: getvar:partition-type:boot
cmd: getvar: max-download-size
cmd: download:000696e8
cmd: flash:boot
Mismatched partition size (boot)
Phone Info
Code:
Model: XT1025 Dual Sim w/ TV - Brazillian Retail
Updated to first 5.1 Official OTA on July 23rd
Then installed Resurrection Remix
So is your phone booting now?
It wouldn't have done any harm imo.
I haven't came across it before so nothing can be said for sure.
Chances are, fastboot formatted your boot partition and when tried to flash the IMG, throws that error. In that case, your boot partition is empty and system is without a kernel. You will need to flash stock IMG in that case.
However, it might be the case that fastboot performed the check before formatting partition and your kernel might be residing there safely.. But no way of knowing that without booting.
So if you want to be on safe side, flash the stock img.
If you want to try and check , try rebooting once. You might be able to boot into bootlaoder mode after.
Tapped from my Moto X
neo.ank said:
I haven't came across it before so nothing can be said for sure.
Chances are, fastboot formatted your boot partition and when tried to flash the IMG, throws that error. In that case, your boot partition is empty and system is without a kernel. You will need to flash stock IMG in that case.
However, it might be the case that fastboot performed the check before formatting partition and your kernel might be residing there safely.. But no way of knowing that without booting.
So if you want to be on safe side, flash the stock img.
If you want to try and check , try rebooting once. You might be able to boot into bootlaoder mode after.
Tapped from my Moto X
Click to expand...
Click to collapse
I thought boot partition was important as motoboot's bootloader partition or gpt, forgot 'boot' is kernel.
fastboot formatted my boot partition, phone was stuck at bootlogo.
Downloaded official XT1025 firmware and flashed only boot partition.
Went to TWRP, installed my old custom kernel and now the phone is fine.
Thanks
Glad u solved it..
Tapped from my Moto X
The custom logo's doesn't flash on the boot partition, flash on the logo partition
Example: mfastboot flash logo nameoflogo.bin

Can't use TWRP on Huawei Y6 (2018)

Before:
I just unlocked the bootloader and installed a custom ROM (LineageOS 15.1: https://forum.xda-developers.com/huawei-y6/development/lineageos-15-1-huawei-y6-2018-t3832278) on my Huawei but it won't let me flash the TWRP from adb. I tried before flashing the custom ROM and also after but no progress. I tried with 'fastboot flash recovery recovery.img' as well as 'fastboot flash boot recovery.img' because I knew some smartphones include the recovery in the boot.img but I am always getting the same error:
Code:
fastboot flash recovery recovery.img
target reported max download size of 535822336 bytes
sending 'recovery' (16544 KB)...
OKAY [ 0.522s]
writing 'recovery'...
FAILED (remote: partition table doesn't exist)
finished. total time: 0.553s
I am not an expert but I understood that 'recovery' partition doesn't exist. I found some possible solutions online such as writing 'fastboot flash RECOVERY recovery.img' or 'fastboot flash erecovery recovery.img' (because Huawei calls the stock one 'erecovery') but they both gave me another error:
Code:
fastboot flash RECOVERY recovery.img
target reported max download size of 535822336 bytes
sending 'RECOVERY' (16544 KB)...
OKAY [ 0.522s]
writing 'RECOVERY'...
FAILED (remote: Command not allowed)
finished. total time: 0.528s
UPDATE: I found, maybe, the correct name of the recovery partition and it seems to work:
Code:
fastboot flash recovery_ramdisk twrp.img
< waiting for device >
target reported max download size of 535822336 bytes
sending 'recovery_ramdisk' (14026 KB)...
OKAY [ 0.443s]
writing 'recovery_ramdisk'...
OKAY [ 0.323s]
finished. total time: 0.767s
BUT it actually doesn't work properly because when I boot into recovery it boots the stock one. I tried other solutions found on the net like instantly unplug the phone after the flash and reboot it into recovery immediately but again it boots into stock one...
OTHER UPDATE: I managed to find and flash a TWRP that can boot up but it shows the internal storage 0MB not allowing me to install any .zip file. Because of that, I cannot install SuperSU to get root access.
I tried installing TWRP also with stock ROM but still showing 0MB because the phone is encrypted. To disable encryption I need to install the bluspark TWRP (As I found online), the problem is that bluspark won't boot and gets immediately overwritten by the stock ROM as it happened with the one I mentioned in the first update of the post.
Now I will try buying a microSD card and see if it shows right so that I can still flash .zip from the microSD card.
Now:
LATEST UPDATE: The SD card is working properly and I see it as around 60 GB instead of 64 but that's not the problem. I can see the .zip files I'd want to flash but when I try to do it it says me that it failed to mount every single partition and after some research I discovered that my Huawei has all the data encrypted. After other research I found that there are some TWRPs like blu_spark that could decrypt the data but every version I tried doesn't work and gets immediately overwritten by the stock recovery.
Does anyone know other methods to decrypt all the data on Huawei? Otherwise it's impossible to flash any .zip. Actually it flashes it but it fails to update the partitions state so the system doesn't recognize the changes.
Rooting Huawei is so difficult.. I will buy an OP5t as soon as I have the money XD.
Y6 2018 twrp
Any progress? I'm also looking for a version of TWRP that works with the Y6 2018.

My son killed xiaomi mi a3

So I bought a son new phone.
As he told he installed magisk first, flashing "magisk_patched.img" through windows shell, everything was fine. Then He flashed twrp and magisk, everything was almost fine, he noticed that he cant play audio. He was trying to fix it first through installing magisk audio mods like viper and sauron. It didn't fixed anything, he unistalled it, everything was still in the same state, so he decided to flash stock frimware. He flashed through mi flashing tool, unfortunetaly It was image for "global xiaomi version" I mean "PFQMIXM" when as far as I know It should be "PFQEUXM". It didn't work and he was stuck in a bootloop. He found "MiUi 11 " image and for still unknown to me reason thought that it is going to fix everything. He flashed It again through mi flashing tool. It didn't work. He did that second time but at last he just closed the flashing tool while it was doing its thing.
At last he found eu firmware but now after all of that when i try to flash it or single files like crc list i get this:
flash crclist "E:\ModCR\adb\images\crclist.txt"
Sending 'crclist' (0 KB) FAILED (Write to device failed (Unknown error))
fastboot: error: Command failed
Device only boots to fastboot (no recovery/twrp either).
I tried erasing cache:
./fastboot erase cache
Erasing 'cache' FAILED (Write to device failed (Unknown error))
fastboot: error: Command failed
I tried to check slots:
./fastboot getvar active-slot
getvar:active-slot FAILED (Write to device failed (Unknown error))
Finished. Total time: 5.003s
I tried to change slot:
./fastboot set_active b
fastboot: error: Device does not support slots
When i typed "fastboot devices" It appeared as "??????"
./fastboot devices
???????????? fastboot
I don't know how to fix it, If anyone knows or has any kind of even small idea please write it down. I would be very greatfull.
Install custom recovery twrp
Install custom rom
Reboot
Download firmware EU
Install a firmware witch miflash
Restore Factory
Walaaaaa
xt610 said:
Install custom recovery twrp
Install custom rom
Reboot
Download firmware EU
Install a firmware witch miflash
Restore Factory
Walaaaaa
Click to expand...
Click to collapse
What i understand from op post is that fastboot commands are not working. So how will he flash twrp?
The firmware version doesn't matter at all you can flash EU on global and vice versa it doesn't matter.
What I think happened was your son never switched to slot 'a' before using mi flash.
Xiaomi's install script for miflash requires you to be on slot 'a' before flashing.
The only way to recover from this is edl mode which requires a xiaomi verified account to fix.
MOD EDIT: Part removed
Please do not advertise/recommend remote unlock services on XDA. Please read the FORUM RULES especially those:

Installed CallX Call Recorder - Now Phone Borked

Help! Installed CallX, which has very good reviews, but instantly I could no longer hear anyone who called nor who I call. If I turn on the speaker we can converse but not clearly in a noisy environment.
I immediately deinstalled CallX... but, the problem remained.
In desperation I completely installed new firmware on the phone (Havoc 4.12, previously Havoc 4.8) and lost all my config which takes me a day to rebuild, and guess what? NO CHANGE. I can't hear anyone as a normal phone.
The developer of CallX is unresponsive. Isn't that dynamite? I think he must have been packing the reviews.
Does anyone know where the problem could be? I can't believe installing new firmware did not fix it.
Quantumstate said:
Help! Installed CallX, which has very good reviews, but instantly I could no longer hear anyone who called nor who I call. If I turn on the speaker we can converse but not clearly in a noisy environment.
I immediately deinstalled CallX... but, the problem remained.
In desperation I completely installed new firmware on the phone (Havoc 4.12, previously Havoc 4.8) and lost all my config which takes me a day to rebuild, and guess what? NO CHANGE. I can't hear anyone as a normal phone.
The developer of CallX is unresponsive. Isn't that dynamite? I think he must have been packing the reviews.
Does anyone know where the problem could be? I can't believe installing new firmware did not fix it.
Click to expand...
Click to collapse
Sounds like you need to flash stock Motorola firmware.
I never thought an app could do such damage to a phone even after reinstalling firmware.
I've now also lost all of my Signal SMS history (Havoc 4.12) because in Permissions the only ones available for Signal are Media Only or None. It needs Files permission to restore the backups, but it is just not an option.
It's worse now. I installed Stock using my instructions over here, but I installed Android 11, not having seen Beetle's post below. In TWRP I got all kinds of permission denied errors on /data/. So I then downloaded Android 10 from here, and
# fastboot flash partition gpt.bin
...which went fine. But then
# fastboot flash bootloader bootloader.img
Sending 'bootloader' (14204 KB) OKAY [ 0.414s]
Writing 'bootloader' (bootloader) Validating 'bootloader.default.xml'
(bootloader) Preflash validation failed
(bootloader) Preflash validation failed
(bootloader) Cancelling 'bootloader.default.xml'
FAILED (remote: '')
fastboot: error: Command failed
No idea what is wrong. The partitions should have been written. My phone's down hard now. Booting into fastboot I do not get the normal way it looks, but a mostly blank screen with Start in the center, and text at bottom acknowleging it's connected. And it does answer up to # fastboot devices. I've downloaded the stock image twice and same issue.
I can't find an older Android 10, in the hope that it will fix this. I believe that Android 10 is required for all versions of Havoc, but I can't even get to Stock at this point. Feel like drinking but won't,
# fastboot flash bootloader bootloader.img
Sending 'bootloader' (14204 KB) OKAY [ 0.385s]
Writing 'bootloader' (bootloader) Validating 'bootloader.default.xml'
(bootloader) Preflash validation failed
(bootloader) Preflash validation failed
(bootloader) Cancelling 'bootloader.default.xml'
FAILED (remote: '')
fastboot: error: Command failed
In TWRP I get "failed to mount /metadata" "invalid argument". There is no way to recover from this. I suspect this happened because I tried to roll back from stock Android 11 to 10. I've tried going back to 11 and every which way.
Looks like this phone is ruined. I've tried everything I can think of. out of ideas.
Yep, did a complete fastboot flash reinstall of Stock 11, and still the earpiece does not work. Phone is the default calling app.
This phone is unusable except in speakerphone. I've ordered another Moto G Power 2020 as it's so good otherwise, even without call recording. But AVOID CallX!
Beetle84 once said to not install Stock 11 then Havoc, that it must be Stock 10, but it is unclear whether that applies to the current Havoc 4.12 which is based on Android 11?
What I know for sure is that when you install Stock Android 11, you can NOT go back to Android 10 as G**gle has thoughtfully put in anti-rollback measures. And Android 12 makes things much more difficult for us modders.
Quantumstate said:
What I know for sure is that when you install Stock Android 11, you can NOT go back to Android 10 as G**gle has thoughtfully put in anti-rollback measures. And Android 12 makes things much more difficult for us modders.
Click to expand...
Click to collapse
That's not good. May I suggest supporting the efforts of the Pine64 folks?
Quantumstate said:
In TWRP I get "failed to mount /metadata" "invalid argument". There is no way to recover from this.
Click to expand...
Click to collapse
Did you try wiping metadata entirely?
I had the same problem with the bootloader refusing to allow downgrading the bootloader after installing Motorola's Android 11 firmware. Even so LineageOS is running fine on the device's Slot A right now. Read my post over here.
I did something like: (Exact steps weren't noted. Sorry, no desire to retest on a now working device used by a family member.)
Booted into the bootloader and flashed Motorola's Android 11 stock firmware from XT2041-4_SOFIA_RETUS_11_RPMS31.Q1-54-13-7_subsidy-DEFAULT_regulatory-DEFAULT_CFC.xml.zip on Slot A, minus vbmeta and super
fastboot set_active a
fastboot oem fb_mode_set
fastboot flash partition gpt.bin
fastboot flash bootloader bootloader.img
fastboot flash radio radio.img
fastboot flash bluetooth BTFM.bin
fastboot flash dsp dspso.bin
fastboot flash logo logo.bin
fastboot flash boot boot.img
fastboot flash dtbo dtbo.img
fastboot flash recovery recovery.img
fastboot oem fb_mode_clear
Rebooted into fastbootd (fastboot reboot fastboot) and flashed LineageOS fastbootd images from lineage-18.1-20211219-UNOFFICIAL-FASTBOOTD-sofiar.zip
fastboot flash boot boot.img
fastboot flash system system.img
fastboot flash vbmeta vbmeta.img
fastboot flash product product.img
Returned to the bootloader (fastboot reboot bootloader) and wiped data
fastboot erase carrier
fastboot erase userdata
fastboot erase metadata
fastboot erase ddr
Rebooted (fastboot reboot) into LineageOS, it booted successfully and runs fine. Rooting wasn't tested. Before trying LineageOS fastbootd images I installed crDroid through TWRP and booted it with success. It had some weird bugs unfortunately, most importantly being unable to serve as a working phone. My family member was very happy with an older version of crDroid from around June on the Android 10 firmware.
I fixed the /medadata error by (in TWRP)
- Unmount /metadata
- Disable MBR
- Format /metadata.
Problem is metadata was encrypted and 11 couldn't tell from 10.
Now all the /loop's on inactive slot b are inaccessible. I could keep jacking with it but ran out of time. And running Stock in slot a I find I still have the earphone problem so gave up and ordered another phone. It should never be possible for an app to do this kind of damage.
Yes I've noticed the Pine64 project, although one thing I require is a water-resistant phone. There will come a point, in view of the awful changes in Android 12, where I may move to a Pine phone. As it is, for years I've run no gapps, do not use the Play store, nor anything else G**gle except the OS. And I choke the OS off with AFWall+ in F-Droid.

Categories

Resources