Can't update to Android 14, even on stock firmware

So Android 14 OTA came out very recently, and I originally had my fp5 rooted with Magisk and had TWRP recovery installed. I already read up about how OTA updates always do a validation check before installing.

So my natural decision was to flash the stock partitions via adb and fastboot that I had backed up from earlier, and thought everything would work, right?

Nope! When I tried to install the update on the backed up stock images, it came up with the error:
Couldn’t update
Installation problem

I’ve really tried everything, and nothing is working. I’ve tried even flashing boot_a and boot_b partitions with the stock image, and everything with the stock images. It still isn’t working and I really need help.

What can I do? Is there anything I can do to fix this issue? Have I broken the validation checksum? Is there something in there that it detects as modified that can’t be undone?

I’ve checked to make sure the stock recovery mode is working, and yes it’s working. But the OTA update still can’t install the update.

Will I be forever stuck on Android 13 with no way to update?

Welcome to the community forum.

Just to confirm … you went through the official procedure to install from scratch? …

If all else fails, you can wait for the site given above to publish the Android 14 files to install, I guess.

Do you have developer options enabled and Automatic system updates in developer menu disabled?
Not sure it will cause this problems in your case, still worth a check.

Otherwise you did OTA updates with your set-up before? How did you proceed?

Else no you will not be forever with Android 14 you can always manually install once available.

Yep, Automatic Updates are disabled in developer settings, as seen here:

And the last time I successfully updated, was with a security update, which was with stock firmware and an unlocked bootloader. But the last time I did a major update from Android 12 to 13 (right before I unlocked the bootloader), it worked with no issues.

Can someone confirm if OTA upgrades to a new major Android version requires a locked bootloader? Because I’m having no success in being able to update.

Please confirm what you did to update so exact steps with Magisk.

That might have caused issues (failed install, had to be reapeted several times) with locked bootloader, so it might or might not have any influence…

The exact steps I took, were as followed:

  1. Using the Magisk app, clicked the Uninstall button, then clicked on Restore Image when it asked, but then an error saying “Stock image not found” came up. So then I went onto step 2:
  2. Reboot into fastboot with adb reboot bootloader.
  3. I then flashed the following partitions using fastboot flash [partitionname] [pathtoimage] with an earlier backup (the ones highlighted):
  4. Booted back into the OS.
  5. Uninstalled the Magisk app, and the app used for hiding Magisk.
  6. Attempted to install the OTA update in the settings.
  7. It failed, no matter how many times I tried over and over again.
  8. Then I rebooted into fastboot with adb reboot bootloader.
  9. Switched to slot A using fastboot --set-active=a.
  10. Booted back into the OS, tried to update again in settings with the OTA update.
  11. This time it proceeded to download the update, but once it fully downloaded the update, it failed with the same error.

Is there any other options? And is there any option to keep my data? I’m really curious.

Ok so the actual error was already at step 1

How did you root? Did you flash the boot img? Did you
flash vbmeta?

I did the procedure as shown here, and when I installed Magisk, I only patched the boot.img, then flashed the boot.img to the active boot partition. I didn’t patch vbmeta, and I also didn’t disable the verity and verification.

Does vbmeta need to have verity and verification disabled when installing OTA update through settings? Or does it need to be enabled?

Even though it is not listed on the download page there does seem to be a zip file for Android 14 on the same server: https://fairphone-android-builds.ams3.digitaloceanspaces.com/FP5/A14/FP5-UT20-factory.zip
I just replaced A13 with A14 and TT4H with UT20

Maybe you want to try directly flashing that?
(Note: I have not tried it myself)

2 Likes

Ok flashing boot.img isnt a great idea you should only boot from it.

That you didnt touch vbmeta would be good in my eyes.

Please do some reading in this topic

i update to A14 with unlocked bootloader without problem… BTW: don’t have TWRP installed

  1. in Magisk Uninstall/RestoreImage (and don’t uninstall Magisk app)

  2. run System/Update

  3. after update finished, DON’T reboot, but run “adb shell” and:
    getprop ro.boot.slot_suffix # this show me actual/booted slot A or B
    su -
    dd if=/dev/block/by-name/boot_X of=/sdcard/boot_UT20-041_stock.dd.img # where X is other A/B then booted slot

  4. in Magisk Install/Patch *.dd.img and pull patched img to computer

  5. Reboot to finish System Update

  6. adb reboot-bootloader # and wait for menu show on phone

  7. fastboot boot name_of_patched_img # only boot it, DON’T flash it

  8. run Magisk and Install direct

  9. Reboot…

2 Likes

I read through all of it, and I’m really curious about how I can fix this issue so that OTA can work again?

Unfortunately, I could not get past Step 1 in your instructions, because even when I reinstalled Magisk (the correct way by booting into the image and not flashing it) and then uninstalled it and selected restore image (which this time it was able to do so), but… I still kept getting the following error when attempting to download the update:
Couldn’t update
Installation problem

Anything else I can do to try and get System Updates working again?

What exactly have you done? Only the boot.img or anything else?

How did you install TWRP and what have you done to remove it, because I understand you are back on AOSP recovery?

When you follow my link above further to the FP4 topic, I guess what you would need(ed) is a clean vanilla status

however I’m not sure which role TWRP might add, as normally you only boot into TWRP (never flash it) and I dont know what a permanent install would change.

When you say

Which OS Version, i.e. any older Version than latest A13 (guessing you had the latest A13 installed,that should habe been FP5.TT4H.A.162.20240609?

I flashed all the backed up partitions that TWRP could back up, which was the same FPOS version as it is now (FP5.TT4H.A.162.20240609), I always back up every partition that TWRP can back up before I do any modifications to the partitions

Originally, I had TWRP as just booting directly from the image with fastboot boot [pathtotwrpimage], but then more recently, I ended up pressing on the “Install TWRP” button after I had backed up all the images, to make sure I could revert everything when needed.

Indeed, a vanilla status that would allow the OTA to download and install. Otherwise the update won’t download, so even when restoring the stock images with Magisk, it refuses to download the update. I might have missed something in there while I was reading, but from what I’ve read in there, is that flashing the stock boot.img should fix the issue, but it doesn’t do anything, and the update still fails to download. I’m really curious if I’ve missed reading something very important that would help me get the OTA download working again and the checksums to work.

When I first used TWRP and for a while, I did use fastboot boot [path/to/twrp.img], but there was something I did recently that I pressed the “Install TWRP” (which I shouldn’t have), but before I did, I backed up all the partitions, just incase I need to revert all the partitions later. And I also really don’t know what a permanent install would have changed

The latest backed up version was definitely FP5.TT4H.A.162.20240609, I’m pretty sure, same version as it was before the partitions were modified

However there is one thing I can think of that could have been the cause: When I was testing out postmarketOS. And getting it to run on the FP5 from SD card was really tricky, since there was two partitions that needed to be deleted.

I did however recreate the partitions again and restore them with a backed up partition of it, but I am concerned that it could have created an entirely new GUID as a result, and could be why it has a mismatch with the vbmeta partition

Now I’m really curious, is this irreversible? Or is there a solution to fixing this, so that the validation can work again?

I guess we are back to what @AnotherElk said at the beginning and I guess flashing manually clean and fresh FPOS

would help and then start without back-ups with this instructions to root

and maybe first till next OTA without a permanent installed TWRP…

However someone else maybe has more ideas

1 Like

4 posts were merged into an existing topic: How to root the FP5 and OTA update - at your own risk

It really seems that way, since even attempting to download the update with or without Magisk in the boot partition, regardless of if the boot partition is stock, it will still refuse to download the update.

If there was a way to bruteforce the original GUID of the dtbo partition to the GUID before it was deleted, maybe then it would see it as correct and proceed to download the update

I also don’t get why the Android OS OTAs were designed to validate the partitions, when it really should just be creating an entirely new checksum instead. Every other OS doesn’t complain about a small GUID change or a new partition of the same type, and usually is easily fixable, if it has issues, especially with Ubuntu or other distributions. But as for Android, I’d really like to learn exactly how it validates and how to fix any validation issues with the OTA update downloads

Usually starting over from scratch is the last thing I’d ever do, but if there is no other alternative, then manual install will be the only option

Thank you very much for the nice tutorial. Worked like a charm without any problems. :slight_smile:

But I’ve also never had TWRP installed

I had also troubles to install the latest OTA update (Android14 UT27.B.059) on my FP5 due to magisk.
I flashed the vanilla boot.img downloaded from the FP website and then I was able to install the OTA update.
I had then lost my root access.
I then tried as you suggested just to “fastboot boot magisk_patched_boot.img”.
I booted in the OS and from my desktop “adb shell” then “su” worked so I had the root access.
I rebooted the phone but then I had lost the root access.

root@XX:~# adb shell
FP5:/ $ su
/system/bin/sh: su: inaccessible or not found

So I finally flashed “magisk_patched_boot.img” to keep the root access even after a restart.

fastboot flash boot magisk_patched_boot.img

And now I have again permanent root access even across FP5 restarts.

Well that will bring you trouble at next OTA

Did you do this after booting the patched img?