Fixing the "boot" partition instead of recovery - Xperia SP Q&A, Help & Troubleshooting

Hey there!
I am trying to flash TWRP 3.1.1-0 into my Xperia SP using ADB and apparently it cannot find the "recovery" partition. I've found out I can flash into "boot" instead but my question is, is there a way ( or should I even try) to fix this? I've tried Emma but my device is not supported. It's bootloader is unlocked and I am using Lineage OS 7.1
As far as I've searched in the forums ( https://forum.xda-developers.com/xperia-z-ultra/help/recovery-partition-xz-ultra-flashing-t3453568 ), at least for Xperia Z, it means the bootloader I originaly flashed used a "boot" partition instead of "recovery", right?
The final goal of this quest is to relock my bootloader so Sony Companion can reinstall the original firmware and get it as original as possible.
I am new here and, I hope I am posting this in the right section and I did my research right. This forum is so big it is a little overwhelming.
Thanks in advance!

flash recovery into boot
Hi,
I have a similar question: I want to flash LineageOS 14.1 to my Xperia SP Android 4.3 Build 12.1.A.1.205. I have unlock the Bootloader with the Code from developer.sonymobile.com/unlockbootloader
When I want to flash "fastboot flash recovery twrp-3.1.1-0-huashan.img" , it can not find the recovery partition.
Is it really possible to "fastboot flash boot twrp-3.1.1-0-huashan.img"??? After I have done this, I can reboot normally and TWRP will start? Then I will be able to install LineageOS?
Thanks!

FuchsXSP said:
Hi,
I have a similar question: I want to flash LineageOS 14.1 to my Xperia SP Android 4.3 Build 12.1.A.1.205. I have unlock the Bootloader with the Code from developer.sonymobile.com/unlockbootloader
When I want to flash "fastboot flash recovery twrp-3.1.1-0-huashan.img" , it can not find the recovery partition.
Is it really possible to "fastboot flash boot twrp-3.1.1-0-huashan.img"??? After I have done this, I can reboot normally and TWRP will start? Then I will be able to install LineageOS?
Thanks!
Click to expand...
Click to collapse
Yeah that's pretty much where I'm at right now. Whenever I flash TWRP into my Xperia SP using " fastboot flash boot twrp****.img" it works but when the phone boots the TWRP is all that is on the phone. It will not boot into the system. But then, when I install the OS using TWRP, the OS overwrites TWRP and I am back to the old cyanogenmod bootloader.
So answering your questions:
FuchsXSP said:
Is it really possible to "fastboot flash boot twrp-3.1.1-0-huashan.img"???
Click to expand...
Click to collapse
Yeah that's pretty much how it is done. At least on my Xperia SP. ( I love this phone btw XD)
FuchsXSP said:
After I have done this, I can reboot normally and TWRP will start?
Click to expand...
Click to collapse
Yeah it will only boot into TWRP. You probably wont have access to to your system anymore.
FuchsXSP said:
Then I will be able to install LineageOS?
Click to expand...
Click to collapse
Yeah, just press Install, select the file, and swipe that cool looking safety slider and it should be fine. Beware though older versions of LineageOS had some problems with zip signatures, just make sure to have the newest nightly version (07/12/2017 I guess) and you should be fine.
I have to say though, as anything with android modding, do at your own risk =p.

Here is the solution (at least, the one that worked for me)
I had similar problem - my phone was booting either into Lineage or TWRP, but I had to switch these using ADB commands.
Then I found an application in the Google Play store which can repair this. Look for "TWRP Manager (Requires ROOT)" - from Jmz Software. Free version is good enough.
I installed it and then when I tried to select the option to install TWRP, it tried to install, then complained that there is some problem with my configuration and it looks that it has been repaired. (I'm sorry for not repeating exact messages here, I was doing this about month ago, but when you install this application, the rest is quite self - explanatory).
Anyway, try this. Now my Xperia SP is booting flawlessly - Lineage or TWRP, of course "Reboot to Recovery" option in Lineage also is working correctly !

Xperia SP does not have a dedicated recovery partition like most of other Android phones and a newer Xperia variant. To workaround, the developers of this device have been using different ways of implementing recoveries, the latest and working one is by loading the recovery into our FOTAKernel partition, which is a partition that plays an important role during Stock OTA updates.
Since such a partition serve absolute no purpose when you ventured into custom ROMing, the idea of making use of it for recovery is quite neat. This "feature" is Adrian DC's implementation.
To answer to your question, no, you cannot flash a recovery using fastboot (or any other tools that makes use of fastboot). The options provided by the tool is only limited to partition names, not addresses. You can though, download the FOTA zip from the TWRP thread, and then flash them in the recovery (the one that you booted into because it was installed in /boot). Then re-flash the ROM zip so that the boot image of the ROM gets flashed properly.

It works
Hi,
I have success. On my Xperia SP is now LineageOS 14.1
1. Unlock Bootloader via Sony
2. fastboot flash boot twrp-3.1.1-0-huashan.img
3. reboot SP into twrp
4. wipe and install lineagesOS and opengapps
5. reboot
Now, i can access twrp with second recovery mode (FOTA)
Thanks for your help!! :good:

solved !
sorry to need to bump this thread, but i am having similar issues - i have successfully flashed twrp-huashan as shown in the post above, but on rebooting into twrp, wiping and installing adrian's oreo build, i lose access to twrp
attempting to boot to recovery shows a very brief droid on its back, and then tells me to choose to boot to system or recovery, neitherof which get me back to twrp
any suggestions, as i do not understand why this is so
edit : all is revealed !!
[Recovery][OFFICIAL][UBL] TWRP 3.2.1 Touch Recovery for Xperia SP
https://forum.xda-developers.com/xperia-sp/orig-development/recovery-twrp-3-0-0-touch-recovery-t3309938

Xperia z wont go into recoverymode. blue light with black screen
Hi im having a problem with my xperia z. i have rooted it fisrt then unlocked the bootloader but it wont show a recovery screen when i try and go into recovery mode to flash abd install lingeage. it just shows a blue light with black screen every time i try and go into recovery mode. cant seem to install twrp either. what do i do?

Blue light indicating fastboot mode on Sony Xperia Z5
Karimano24 said:
Hi im having a problem with my xperia z. i have rooted it fisrt then unlocked the bootloader but it wont show a recovery screen when i try and go into recovery mode to flash abd install lingeage. it just shows a blue light with black screen every time i try and go into recovery mode. cant seem to install twrp either. what do i do?
Click to expand...
Click to collapse
Well, that's it. The blue light indicates fastboot/recovery mode on the Xperia Z. You can now connect the Xperia to a computer via USB, then run e.g. 'fastboot devices' and it should list your Xperia. Or run 'fastboot flash recovery <image filename>' to flash TWRP onto the Xperia.

Related

Unfixable bootloop?

I'm what you'd call a super noob at this stuff and I've got my poor little SP in a crazy bootloop... I've tried LITERALLY EVERYTHING the internet has told me to try; wiping every cache out there, flashing custom roms, stock roms, you name it. It began when I just got CWM (don't ask me why it happened then, I have no clue why) and this is even BEFORE I put a ROM on! (I was all ready to put a ROM after getting CWM but bootloop happened).
Note: I have CWM recovery, I think I have lost my stock recovery, if I try some ROMS (ex. CM 12) they give me this error 7, once I found certain ROMS (PACMAN ROM, unofficial stock ROM) that would flash and install, they did but still left me with a bootloop, I have tried wiping so many caches it's not even funny, I've tried flashing the original firmware, nothing works... so I'm here for help.
I have looked at every google link and every method possible in trying to fix this thing! I really can't afford a new phone and I just love this one too much... please help!
farahtasnim said:
I'm what you'd call a super noob at this stuff and I've got my poor little SP in a crazy bootloop... I've tried LITERALLY EVERYTHING the internet has told me to try; wiping every cache out there, flashing custom roms, stock roms, you name it. It began when I just got CWM (don't ask me why it happened then, I have no clue why) and this is even BEFORE I put a ROM on! (I was all ready to put a ROM after getting CWM but bootloop happened).
Note: I have CWM recovery, I think I have lost my stock recovery, if I try some ROMS (ex. CM 12) they give me this error 7, once I found certain ROMS (PACMAN ROM, unofficial stock ROM) that would flash and install, they did but still left me with a bootloop, I have tried wiping so many caches it's not even funny, I've tried flashing the original firmware, nothing works... so I'm here for help.
I have looked at every google link and every method possible in trying to fix this thing! I really can't afford a new phone and I just love this one too much... please help!
Click to expand...
Click to collapse
please state your current bootloader status. Is it unlocked or still locked?
TechnoSparks said:
please state your current bootloader status. Is it unlocked or still locked?
Click to expand...
Click to collapse
I have unlocked my bootloader. Thank you for replying!
farahtasnim said:
I have unlocked my bootloader. Thank you for replying!
Click to expand...
Click to collapse
Splendid! Knowing that your BL state is unlocked, this will make the whole process A LOT easier!
http://forum.xda-developers.com/xperia-sp/development/ubl-twrp-f2fs-support-xperia-sp-huashan-t3150230
Please go to the above link to get TWRP. Also, please keep in mind that TWRP is now the only still supported recovery around. CWM and PhilZ are both really outdated and no longer maintained due to the introduction of Cyanogen Recovery which is very minimal in features.
Once you get yourself the download, extract the files from the zip and get the twrp.img file. We will need this to flash into the boot partition of Xperia SP, granting you a direct boot into recovery once it is flashed. Please then copy the original zip to your sd card, as we will be flashing the original zip via TWRP later to give you access to TWRP in the future.
Using your preferred tool, flash the twrp.img file into the boot partition.
Connect your Xperia SP via fastboot. Make sure SP is shut down, hold volume up key and connect the SP with your computer.
If you're using a fastboot tool via command prompt, the command would be
fastboot flash boot twrp.img
If you're using flashtool, hit the lightning icon in the toolbar, select fastboot mode. Then select "Select kernel to flash". Make sure the file type is "img" else you won't able to find your TWRP img file. Navigate to mentioned img file and select it.
Afterwards, when flashing complete, you may insert sdcard and start the device. It will boot directly into TWRP as we flashed a recovery to the boot partition.
Clean wipe data, cache, dalvik cache, system. You may leave internal storage.
Flash the ROM zip you acquired (make sure file integrity is checked beforehand!) then the TWRP zip earlier. Flashing the TWRP zip grants you a persisting recovery, as explained in the linked thread.
You may now reboot and enjoy

Do I have to flash TWRP everytime using Flashtool if I need to access it?

Newbie to the 'Dark Side of the Android World' and just curious.
well, after rooting your phone you only need to flash custom recovery once then you can access it as many times as you want
Your question is a little bit weird. Can you link me to a place of reference? Or at least explain what you are actually wanting to do?
Flashing TWRP is a one-time action, once flashed it remain on your Xperia SP. However, FlashTool doesn't offer flashing TWRP to other partitions via fastboot other than the "boot" partition. So far, the only way to correctly flash TWRP is via a recovery.
If you indeed flashed TWRP image via FlashTool, then you are actually putting TWRP into your boot partition, and this makes your device to only boot into TWRP infinitely until you flash a ROM (which will of course again override the boot partition).
The reason why I asked is because this method of accessing recovery is posted in my custom ROM guide, so I want to know if you get this kind of idea from my guide.
Thanks

Stuck with cm recovery and no bootloader Xperia Z1

Hello everybody,
I rooted my Xperia Z1 about 8 months ago in order to install the 5.1.1 update which didn't roll out for my device probably because it was a global version (5.0.1 was the last OTA). I did a clean install with no problems, flashed DualRecovery, SuperSu, and BusyBox was working just fine. Everything was working perfectly.
About 3 months ago, I tried updating BusyBox, only to tell that the update failed (couldn't install in the path it used to be try changing the path), I read and read, and found that the solution was to delete a certain file from root that prevented me from modifying certain folders and their content(even with root access), and then do a clean install in a different path than the former one. However, I couldn't gain root access to my files, no root explorer worked! It bugged me, but I was busy at that time, so I couldn't resolve it.
Few weeks later I tried rebooting into recovery, but no method worked, no apps, no key combination, no adb, nothing at all worked! After 2 hard days I managed to install TWRP recovery using NUTS recovery project. I rebooted several times, and it was still working. I then installed BusyBox with no problems, and everything was back to perfect. Later I decided to install CM 12.1 because I always used on my Samsung Galaxy Nexus and I always loved it. So using my now working recovery, I backed everything up on a USB and then flashed CM 12.1 WITHOUT its recovery along with a GAPPS package.
CM was installed, which then rebooted into its recovery and tried to install the GAPPS package. The GAPPS installation was a fail. CM recovery asked me to try using TWRP to do such installation ( go figure! ); in fact, CM recovery couldn't flash anything besides another CM 12.1 update. After this point I wasn't able in any possible way to enter TWRP nor install it. Even if I want to flash using fastboot I couln't! adb reads my device just fine, and can use it to reboot into flashmode, which doesn't seem to be functioning properly. The blue light turns on but there isn't a thing on the screen, fastboot can't recognize is it and hence I can't flash anything using fastboot.
Should I reflash partitions if this could be done on Z1? ( I did it before on my Nexus ) Can I use Odin? I even doubt I can enter download mode on my phone
Any help would be much appreciated.
Thanks in advance!
Anyone?
No?
Ok! :sad:
Is your bootloader unlocked? To run cm on our z1 you need an unlocked bootloader because cm needs a custom kernel.
You can try Sony companion app or androxydes flashtool in combination with a pre-rooted ftf to reach stock again.
The thing is even Sony flashtool (Emma) is not reading my phone, it detects a device in the USB port, but not the device!
I managed to install TWRP using TWRP Manager app that I downloaded from APKmirror website. I installed GApps and it is working fine right now.
TWRP Manager said that I should have a FOTA recovery or something like that, and if I don't have one then I am installing the recovery on my responsibility.
Still no bootloader or flash mode. Neither Emma nor Odin are identifying the phone. Although my phone lights blue, but the screen shows nothing!
Mohdhamm said:
The thing is even Sony flashtool (Emma) is not reading my phone, it detects a device in the USB port, but not the device!
Still no bootloader or flash mode. Neither Emma nor Odin are identifying the phone. Although my phone lights blue, but the screen shows nothing!
Click to expand...
Click to collapse
AFAIK, Emma hasn't been updated for a LONG time. It will remain defunct with no updates and no support. Use flashtool from androxyde if you want to continue using Sony's stock ROM.
No bootloader or flash mode detection: That usually means the drivers that interfaces with your phone is missing. Search around XDA for the correct fastboot and adb drivers for your PC's OS.
My approach for fixing your issue: Find the right drivers and put a stable Lollipop ROM on your sdcard. If you have fastboot working (make sure you have unlocked bootloader), flash boot image from the Lollipop zip and flash the recovery image found in some Lollipop threads. If everything goes well, your phone will bootloop, but you'll have working recovery. Press Vol Down when the Sony Logo appears on screen to enter TWRP. Since you saved a backup of your phone elsewhere, erase all the partitions (minus sdcard), format them to ext4, and flash the Lollipop ROM from your sdcard.

Xperia TX flashing TWRP

Hi, I just switched to android(nexus 6p) few weeks ago. I was interested in trying custom rom, and got xperia tx from my friend for some experiments. Im planning to run RR rom . So, first of all, I unlocked the bootloader.
After that, I tried to install twrp. I got an error regarding "remoteartition not found". I used adb and fastboot commands to flash. After some googling, got to know that xperia devices doesnt have separate recovery partition ( https://forum.xda-developers.com/showthread.php?t=2224896). So I tried using fastboot flash boot twrp.img instead of fastboot flash recovery twrp.img. Things went well and I could access TWRP.
Im not sure if I did this in a proper way (installed in the correct partition) or just created some issues. I even tried copying the RR zip file and installing from TWRP. All went good and I could use the device. Again im not sure if i just overwrite RR over the TWRP or everything is alright. I couldnt access the TWRP anymore.I hope someone could explain about how the partitions work and they way i could tackle this situation. BTW, i could access TWRP using traditional volume down + power lock button if i installed everything properly right?
Thank you very much in advance.

Problems with flashing custom recovery or rooting.

Hi,
Few days ago I bought used Nexus 6, which was come with locked bootloader and stock Android 7.1.
I wanted to flash some custom ROM. First I tried to unlock a bootloader.
I was using an XDA Video Tutorial showing how to unlock and root the Nexus 6 and a tutorial on LineageOS site. I could unlock the bootloader quite easily but unfortunately I forgot to reboot the device (eg. with command "fastboot reboot") and I strightly tried flash a custom recovery.
It flashed well (as described in command line window) but couldn't get into TWRP recovery. Device showed dead green android with description.
System is booting normal and the bootloader is unlocked. But unfortunately I can't flash the custom recovery. I reinstalled all android drivers (I installed full Android Studio with packages suggested by the tutorial). After flash there is no custom recovery - still dead android and possibility to launch stock recovery. Once I could launch TWRP, when I do not reboot phone after flashing recovery and strightly go to recovery (from bootloader). But when I reboot to system and try launch TWRP again - again no custom recovery...
There is also a problem when I try to root the device using CF-Root - it shows some error and device is still not rooted, also without a SU icon in system.
Is there any solution for that? Are these problems a reason of my mistake with not rebooting the phone after unlocking the bootloader?
Thanks a lot for any suggestions and help. If it necessary I can update my post with more details.
Wysłane z mojego Transformer TF101 przy użyciu Tapatalka
Well, the first thing that stands out is you using CF-Autoroot. Kind of putting the cart before the horse there. Also unnecessary, for once TWRP is installed you can simply flash a root solution through it.
Anyway, when you have the N6 in bootloader mode, what happens when you type "fastboot flash recovery recovery.img"? Any error messages? The output of the command will be useful here.
The fact you didn't reboot between commands does not mean you did any damage. Simply start over again.
I am adding photos of bootloader and command line windows after flashing the recovery. It looks that there aren't any errors.
Maybe this is happening because of encrypted device? I saw that my phone is encrypted but i don't doing this before, I restored it to factory settings.
Your images are unreadable. Perhaps it's my data connection.
Encryption has nothing to do with this. Regardless, if you didn't see any errors, what happens now when you enter the bootloader, scroll down to recovery mode, and press power?
OK, I add this images again and I hope it would be readable now.
When I entered the recovery from bootloader a dead android appears with description "No command" below. Then I could press and hold the power button to reboot the device or press and hold for a second VOL+ and POWER to enter the stock recovery...
Maybe your twrp is installed correctly, and you just use the wrong method to start it?
The best way to start it is to reboot with all buttons pressed, and then select recovery.
Edit: didn't see you new post
Hmm, maybe something is wrong with the drivers and maybe with Windows. Maybe I will try flashing recovery on Linux.
I'll tell you right now, nothing is wrong with the drivers. Apparently you typed everything correctly, but humor me on this one please? Rename your TWRP image from its current name to "twrp.img", then flash it via fastboot. What I'm trying to see is if a potential keypunch error is causing your problem. "fastboot flash recovery twrp.img" is a lot easier to type than the default.
Also, what happens when you execute the command, "fastboot boot twrp.img"?
Your bootloader screen looks like mine, except that your serial number has a different structure.
Mine is dd123456 (real numbers replaced). Notice the small letters at the beginning, whereas yours has capitals mixed with numbers, and is longer.
I don't know if we can conclude anything from that.
@runekock: You can't. Mine is ZY222***** and installing TWRP here has never been a problem. I'm almost certain this is a simple userspace issue.
After flashing TWRP are you going directly into recovery mode before rebooting? I seem to recall that some ROMS will replace a custom recovery with the stock recovery unless you boot in to TWRP before booting into the OS.
I have already tried many combinations like flashing older versions, renaming (twrp.img and recovery.img) and rebooting device after flashing or going strightly to recovery after flashing. Only the last option could launch TWRP recovery, but even if I swipe to allow modifications the recovery is missing after reboot. It looks exactly like the original stock ROM is still replacing this custom recovery.
I also tried flashing on Linux and without any changes. I also tried updating recovery on my old Moto G and it was succesful operation - so it is probably not a problem with a computer or with drivers.
Maybe I should do something like that - flash TWRP, go to it directly after flashing, copy custom ROM or SuperSU file to the memory, wipe and flash ROM or SuperSU. Maybe that could help? What do you think, is it safe to try?
Wysłane z mojego Transformer TF101 przy użyciu Tapatalka
fastboot boot recovery.img doesn't install the recovery, but does let you conduct recovery operations on the device. In this case it also verifies that the TWRP image isn't somehow corrupt.
Unfortunately, after confirming that there's nothing at fault with the PC, nothing at fault with ADB and Fastboot, and nothing at fault with the device itself, the only thing that is left is...you.
If you haven't taken a look at the Nexus 6 All-in-one Flashing Guide in Nexus 6 General, I suggest you do so. It's a very good thread and has a lot of advice that might be useful to you.
In this guide there's the note about how important is rebooting the device after unlocking bootloader...
But I see on the Internet similar problems as mine.
0sA said:
I have already tried many combinations like flashing older versions, renaming (twrp.img and recovery.img) and rebooting device after flashing or going strightly to recovery after flashing. Only the last option could launch TWRP recovery, but even if I swipe to allow modifications the recovery is missing after reboot. It looks exactly like the original stock ROM is still replacing this custom recovery.
I also tried flashing on Linux and without any changes. I also tried updating recovery on my old Moto G and it was succesful operation - so it is probably not a problem with a computer or with drivers.
Maybe I should do something like that - flash TWRP, go to it directly after flashing, copy custom ROM or SuperSU file to the memory, wipe and flash ROM or SuperSU. Maybe that could help? What do you think, is it safe to try?
Wysłane z mojego Transformer TF101 przy użyciu Tapatalka
Click to expand...
Click to collapse
Occasionally I have had the same issue of the ROM replacing TWRP with the stock recovery. At that point I just do:
adb reboot bootloader
fastboot flash recovery recovery.img (twrp renamed to recovery.img)
adb reboot bootloader
press the down arrow twice to reboot into recovery
I DO NOT allow modifications
select reboot and reboot into recovery again
select reboot and boot into the OS (reboot system)
Some of those steps may not be necessary but that is what has worked for me.
It looks like I found a solution. I flashed TWRP, reboot bootloader and entered recovery directly from bootloader. I copied Chainfire's SuperSU to the phone, unplugged it from PC and flashed this SuperSU (and also wipe cache after flash). Reboot the phone and system is rooted! I updated TWRP Official App from Play Store and permited root privileges, downloaded latest TWRP recovery and flashed it from this app. When I entered the recvery (from bootloader) it was TWRP! Even if I reboot the device, the TWRP recovery seems not missing.
Wysłane z mojego Transformer TF101 przy użyciu Tapatalka

Categories

Resources