Skip to content

Installation

Pete Fotheringham edited this page Jan 14, 2025 · 6 revisions

Follow the LineageOS installation instructions for your device, which can be accessed from the LineageOS Devices wiki pages. If the LineageOS installation instructions require or refer to any .img files, these files can be found in the same directory on teh download server as the ROM .zip file.

'Clean' and 'dirty' flashing

A 'clean' flash is when the data partition is wiped and/or formatted before the ROM is installed. This will remove all user-installed apps and data. It is sometimes referred to as a 'fresh installation'.

A 'dirty flash' is when the data partition is not wiped and/or formatted before the ROM is installed. Normally this will result in all user-installed apps and data still being present after the installation.

Newer versions of the LineageOS for MicroG ROM can usually be 'dirty flashed' over older versions with the same Android version.

Dirty flashing is sometimes possible over

  • older versions of the LineageOS for MicroG ROM with an earlier Android version**;
  • the official LineageOS ROM (without microG)

In both these cases, problems may be encountered with app permissions, both for user-installed apps and for the pre-installed apps. These problems can sometimes be fixed by manually changing the app permissions.

If you are 'dirty' flashing, it is a good idea to backup your user-installed apps and data in case the 'dirty' flash fails.

Ugrade to a higher Android / LineageOS version

Upgrading from one version of LineageOS to a higher version (e.g. LineageOS 20.0, based on Android 13, to LineageOS 21.0 , based on Android 14) cannot be done by the Updater app. The new version will hav eto be installed manually. The instructions vary between devices, so find your device in the LineageOS Devices Wiki page and follow the links to the upgrade instrcutions for that device.

For some devices, the upgrade instructions specify that a factory reset / data wipe or format is required. If that is true for your device, do not ignore the requirement (in the hope that you won't lose your user-installed apps and data): if you do not perform the factory reset, your device will probably fail to boot after the upgrade. If you want to keep your user-installed apps and data and your device requres a factory reset, then checkout the solutions in this wiki page. They won't backup 'EVERYTHING' , but they are the best I've found.

Downgrading

Downgrading from one version of LineageOS for microG to an ealier or lower version, is generally not possible, even if they are the same Android version. If you want to do that, you will have to format your data partition and perform a clean installation. If you need to go down that path, then checkout the backup options descibed in the previous section.

Failed updates and 'boot loops'

Sometimes - up to now, pretty rarely - an update, either manual or OTA, may cause the phone to 'boot loop' (i.e. the phone repeatedly restarts without successfully loading the operating system), or to keep rebooting to recovery rather than the phone OS. The usual way to fix a boot loop, is to factory reset, by wiping or formatting the phone's data partiition which, as mentioned above, will delete all your user-installed apps and data.

So there is no easy way to fix a boot loop, without losing you user-installed apps and data, because re-installing an earlier, working version also usually requires a factory reset. If you don't have a backup of your user-installed apps and data, then you can try the following:

  • wait for a new, fixed build to be made and published, and manually install it;
  • try installing an earlier working build (you may also have to flash an earlier recovery, as recovery will usually not install a ROM that it older than the recovery). This may work, but probably won't:
  • try flashing the latest LineageOS build from https://download.lineageos.org/devices/<your-device-name>/builds. You won't have a fully-working installation of LineageOS for microG, but you may be able to backup your user-installed apps and data.

Migration from LineageOS

(Note that the information in this section may be out of date or incorrect)

Clean install (wipe data and installed apps)

If you don't care about losing your current data just reboot into recovery, wipe System, Data, Cache and Dalvik and, without rebooting, install LineageOS for microG.

Dirty install (keep data and installed apps)

Our ROM and LineageOS use different signing keys, so you can't directly flash our ROM on top of the official LineageOS while keeping your data; however, the procedure needed to migrate from the official LineageOS is very simple.

Firstly, make sure the ZIP you want to install is newer than the current installed ROM, if it is not, wait for the next build.

If you have installed unofficial builds of

  • F-Droid or F-Droid Privileged Extension
  • microG's apps (GmsCore, GsfProxy, FakeStore and mapsv1 API)

you have to uninstall them before the ROM migration.

If you have installed a GApps package, you must uninstall them too.

Then, depending on your recovery type, two methods apply:

  1. Lineage recovery: Flash the LineageOS for microG ZIP and confirm flash despite signature mismatch.
  2. TWRP recovery: Download and flash the migration ZIP and, without rebooting, flash the LineageOS for microG ZIP.

After installing

  1. Open the microG settings page (Settings | System | microG Settings) and run the self-check. This should show a page entitle 'Self-Check' and all check boxes on the page should be ticked
  2. Enable the various options on the settings page
    • Cloud Messaging: Many apps rely on Google Cloud Messaging, a Google proprietary system to push notifications to your device. This feature is implemented in microG but, as not every user requires it, is disabled by default. If you need it, enable the "Google Device registration" and the "Google Cloud Messaging" features in the "microG Settings" app.
    • SafetyNet: LineageOS for microG will not pass Google's SafetyNet checks 'out of the box'. There are ways of making SafetyNet pass, using add-ons sch as Magisk, but this is outside the scope of LineageOS for microG and our documentaion
    • Location: Before using location services you need to select which online location service to use. This is not set by default, so you will be asked which service to use. We recommend the 'Positon' service. (More information about microG is available on the microG project wiki pages
  3. Enable Automatically install updates in the F-droid app settings: this will keep the microG components, and the apps you have installed from F-Droid uo-to-date without you needing to install updates manually