Hi,
my original intention was just to move as much as possible from my old phone to my new FP2 with Android 6, but Helium Backup always complains that USB debugging is not in PTP mode. True, and I can switch this to PTP, but once I go back to Helium, it bounces back to MTP
So I felt I should root the phone to circumvent this, and I tried to follow this Howto. I used the latest Minimal ADB & Fastboot, version 1.4.3, and got a message that the ADB server verions (31) does not match the client version (36). Googling this message did not reveal anythin that helped me really.
The only other ADB I could locate on my computer was from Helium, so I deinstalled Helium, and the message disappeared. Flashing TWRP showed
> fastboot flash recovery c:\boot-fairphone-FP2-gms-17.10.2-su-eng-r318.img
target reported max download size of 536870912 bytes
sending 'recovery' (14655 KB)...
OKAY [ 0.463s]
writing 'recovery'...
OKAY [ 0.181s]
finished. total time: 0.648s
but the recovery is now destroyed, i.e. I can boot to recovery but just a small Android figure with a German message like āInvalid operationā appears. The same with Minimal ADB & Fastboot, version 1.4.1 and/or the original recovery images that comes with TWRP - a too short flash duration and the same error when booting to recovery. Lucky enough, I can boot the normal FP OS yet.
Any idea how I can circumvent this and still install TWRP? What file versions should I use today, and what do I need to clean from my computer to make sure I work with a correct setup? Or am I completely on the wrong track here? Thank you all in advanceā¦
You flashed a (rooted) boot image to the recovery partition. That aināt gonna workā¦
The correct command is: fastboot flash recovery twrp-3.1.1-1-fp2.img
Btw, I always recommend to use the official SDK Platform Tools. Itās a small download, doesnāt require installation and has the latest ADB and fastboot.
Thank you guys, that shed some light on the issueā¦ Yes I mixed up boot and recovery It is some years a go that I tried this on a Samsung the last time, and with Samsung tools, so everything felt new to me againā¦
Nevertheless, flashing still did not work (and feels too quick);
C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot flash recovery c:\twrp-3.1.1-1-fp2.img
target reported max download size of 536870912 bytes
sending 'recovery' (12296 KB)...
OKAY [ 0.390s]
writing 'recovery'...
OKAY [ 0.148s]
finished. total time: 0.541s
As for an alternative to Minimal ADB, I installed the SDK platform tools as suggested, started sdkmanager, looked at the list of modules and figured it would be the build-tools;27.0.0.0 that might contain adb, but no success here either:
F:\AndroidSdk\tools\bin>sdkmanager build-tools;27.0.0.0
Warning: File C:\Users\myname\.android\repositories.cfg could not be loaded.
Warning: Failed to find package build-tools;27.0.0.0
I really feel stupid today and appreciate your helpā¦
According to your fastboot output flashing TWRP worked fine. What happens when you boot into recovery?
It seems you installed the full SDK Manager. You only need the SDK Platform Tools which donāt require installation. Please read the linked page again, especially the section saying:
Thank you @ChuckMorris. I also thought flashing looks good, but booting into recovery showed the little green android with a warning sign and āKein Befehlā = āno commandā. I know a (textual) recovery from my Samsung, but nothing like this.
I now took the platform tools and get the following message:
F:\platform-tools>adb reboot bootloader
adb server version (36) doesn't match this client (39); killing...
* daemon started successfully *
error: no devices/emulators found
(Trying to make every possible error I guess.) Do I need an older version? There seem to be no links to older versions, and the version history shows that the latest is 26.0.2, so I canāt find a reference to 36 or 39 anywhere.
F:\platform-tools>adb shell
error: no devices/emulators found
F:\platform-tools>fastboot devices
f8ef69f fastboot
So I think there might be an ADB version mismatch (see the post before) and/or a mssing driver on Windows (although the other SDB seems to work), but my phone is correctly connected. I have still no clue what is going wrong here.
The dead No command Android is the stock recovery, so obviously something went wrong when flashing TWRP.
You donāt need adb for flashing TWRP. Letās do this step by step:
Turn off the phone.
Hold Vol- and push the power button. Keep holding Vol- for a few more seconds. Phone boots into bootloader / fastboot mode (shows only Fairphone logo).
Connect phone to PC and run fastboot flash recovery twrp-3.1.1-1-fp2.img. It is completely normal that this takes less than a second.
Disconnect phone from PC.
Hold Vol+. Hold power button until phone vibrates. Keep holding Vol+. Phone should boot into TWRP.
Here is what I think has happened: I read in some other place that the OS might replace TWRP with the stock recovery, but did not understand that āno commandā is the stock recovery (an no error). I relied on this TWRP thread which recommends booting the phone normally first, which might have overridden TWRP again.
I managed to start TWRP now and swiped along the bottom to allow TWRP modifications (which, as I understand it, modifies the OS to not override recovery). Rebooting into the system and then into TWRP again shows it is now installed permanently.
I think this is worth editing the TWRP wiki thread cited above, but this seems to be locked. Or it is worth adding to your own Howto on Magisk, which I will now follow further. Thank you again!
Glad that it finally worked. The TWRP wiki post actually says that you have to boot right into recovery after flashing TWRP (in section 6.b) so no need to edit it.
Also, you should not allow TWRP to modify the system partition. This could / will prevent future OTA updates.
Re-reading the TWRP wiki entry, I still understand it as booting into the normal OS first:
Next we will flash the image to the FP2 by typing:
fastboot flash recovery c:\recovery.img
The flashing only takes some seconds and should not produce any errors.
At last we will restart our FP2 by typing:
fastboot reboot
Your phone should start normally and flashing is complete.
6.b Verify that TWRP was permanently installed:
The reboot in step 6 (the second 1 above - citation messes this up) runs the normal OS, and I think this is what might have reinstalled the original recovery for me. But it may of course be just my way of reading it.
Oh well, and I misundertood the TWRP instructions in the other place that I canāt find anymore (not the FP community) in the way that I allowed TWRP to modify the system partition so that it could actually avoid the reinstallation of the original recovery. Not my day obviously. Is there any way to reverse the changes or revoke this decision otherwise?
Thank you again for your help - this is a great experience and for sure a big plus for the Fairphone!
First things first ā¦ make sure your phone is being recognized at all.
When your phone is in fastboot mode, then the command āfastboot devicesā (Linux: perhaps better as root or using sudo) should output something. Hereās a generic screenshot.
If the phone isnāt recognized, there will only be an empty line and youāll be back on the command line.
If you donāt give an additional path to the file, then it has to be in the path where you execute the command from, but that doesnāt seem to be the issue here (would be āfile not foundā or something similar then).