Install LineageOS on Xiaomi POCO F4

Install LineageOS on Xiaomi POCO F4


Flashing additional partitions

  1. Download the following files from here .boot.img
  2. Power off the device, and boot it into bootloader mode:With the device powered off, hold Volume Down + Power. Keep holding both buttons until the word “FASTBOOT” appears on the screen, then release.
Flash the downloaded image files to your device by typing:fastboot flash boot boot.img


Installing Lineage Recovery using fastboot

  1. Download Lineage Recovery. Simply download the latest recovery file, named vendor_boot.img.warning
  2. IMPORTANT: Other recoveries may not work for installation or updates. We strongly recommend to use the one linked above!
  3. Connect your device to your PC via USB if it isn’t already.
If your device isn’t already in fastboot mode, on the computer, open a command prompt (on Windows) or terminal (on Linux or macOS) window, and type:adb -d reboot bootloader
  1. You can also boot into fastboot mode via a key combination:
  2. With the device powered off, hold Volume Down + Power. Keep holding both buttons until the word “FASTBOOT” appears on the screen, then release.
Once the device is in fastboot mode, verify your PC finds it by typing:fastboot devices
  1. If you don’t get any output or an error:
  2. on Windows: make sure the device appears in the device manager without a triangle. Try other drivers until the command above works!
  3. on Linux or macOS: If you see no permissions fastboot try running fastboot as root. When the output is empty, check your USB cable (preferably use a USB Type-A 2.0 one or a USB hub) and port!
  4. check
  5. TIP: Some devices have buggy USB support while in bootloader mode, if you see fastboot hanging with no output when using commands such as fastboot getvar ...fastboot boot ...fastboot flash ... you may want to try a different USB port (preferably a USB Type-A 2.0 one) or a USB hub.
Flash recovery onto your device:fastboot flash vendor_boot vendor_boot.img
Now reboot into recovery to verify the installation.Type the command:fastboot reboot-recovery


Installing LineageOS from recovery

  1. Download the LineageOS.zip file that you would like to install or build the package yourself.
  2. If you are not in recovery, reboot into recovery:With the device powered off, hold Volume Up + Power. Keep holding both buttons until the “MI” logo appears on the screen, then release.
  3. Now tap Factory Reset, then Format data / factory reset and continue with the formatting process. This will remove encryption and delete all files stored in the internal storage, as well as format your cache partition (if you have one).
  4. Return to the main menu.
  5. Sideload the LineageOS .zip package but do not reboot before you read/followed the rest of the instructions!On the device, select “Apply Update”, then “Apply from ADB” to begin sideload.
  6. On the host machine, sideload the package using: adb -d sideload filename.zip.check
  7. TIP: After the package is installed, recovery will inform you that reboot to recovery is required to install add-ons. In case you want to do that, please select “Yes,” otherwise “No”.
  8. check
  9. TIP: Normally, adb will report Total xfer: 1.00x, but in some cases, even if the process succeeds the output will stop at 47% and report adb: failed to read command: Success. In some cases it will report adb: failed to read command: No error or adb: failed to read command: Undefined error: 0 which is also fine.


Installing Add-Ons

WARNING: If you want to install Google Apps add-on package (use the arm64 architecture), you can download it from here. This add-on needs to be installed before booting into LineageOS for the first time!

  1. Click Apply Update, then Apply from ADB, then adb -d sideload filename.zip for all desired packages in sequence.
  2. When presented with a screen that says Signature verification failed, click Continue. It is expected as add-ons aren’t signed with LineageOS’s official key!

Once you have installed everything successfully, you can now reboot your device into the OS for the first time!

  • Click the back arrow in the top left of the screen, then “Reboot system now”.



Report Page