Every so often, after a LineageOS upgrade, the device starts to
complain on reboot about a "Vendor Image Mismatch": the underlying
Android code has become outdated. LineageOS doesn't fix this itself;
this is firmware which the operating system can't change. Less
forgivably, the LineageOS documentation doesn't appear to mention the
problem. Here's a step-by-step guide to dealing with it, using the
Linux command line.
You will need a USB cable to link computer and device, and
fastboot installed on the computer; you probably used both of these to
get LineageOS onto the device in the first place.
Check the
Google Android Factory Images page,
and find the images for your device. (These will have the same short
name as the LineageOS build, e.g. "angler" for a Nexus 6P.) Download
to the computer the file that matches the version number that
LineageOS has been asking for, probably the latest one; as I write,
having just done such an update, this is "8.1.0 (OPM6.171019.030.H1,
Aug 2018)", and "OPM6.171019.030.H1" is what the warning message on
the device specified.
Extract from that zip file three files (where "(something)" is more
version information, that will change with each update):
bootloader-(something).img
radio-(something).img
image-(something).zip
From the image-(something).zip
you just extracted, extract
vendor.img
. Those three img files are all you'll need.
Next, on your Android device, select Settings, System and Developer
Options. You've probably already enabled Developer Options to get
LineageOS onto the device, but if you don't already have it, find the
device's build number (Settings, System, About device, though this
varies between devices) and tap on it seven times.
In Developer Options, make sure Advanced Restart is turned on, then
under Debugging turn on "Android debugging".
Reboot the device to the bootloader (on mine, that's a matter of
holding down the power button then selecting "Restart" and
"Bootloader" from the menus). Wait until you see the bootloader screen
(an image of the Android logo with an open hatch).
Connect the USB cable from computer to device.
On the computer, run fastboot devices
. The device may ask you to
authorise the debugging connection if you haven't done it with this
computer before. Make sure that you see a serial number in response;
that tells you that the connection is working.
Now for the actual flashing process (in no particular order), using
the img files you extracted earlier:
fastboot flash radio radio-(something).img
fastboot flash bootloader bootloader-(something).img
fastboot flash vendor vendor.img
Disconnect the USB cable, and allow the bootloader to start the
device. No more vendor image mismatch warning.
ADB may have been disabled automatically, but check anyway: Settings,
System, Developer Options, Debugging, Android Debugging should now be
off.
Comments on this post are now closed. If you have particular grounds for adding a late comment, comment on a more recent post quoting the URL of this one.