How to install GSI assembly Android Q on your smartphone

Google Project treble  There is not much time left until the official release Android Q, so the developers are working hard to update their applications for the new version of the most popular mobile operating system. While most devices have not yet upgraded to Android 9 Pie (API level 28), the new API Target Requirements you should have heard of will force you to upgrade to API 29 in 2020.

If you have not yet updated your application, according to API 28 requirements, we recommend that you do it as soon as possible, since Google has given time for developers to update their applications under development until August 2019. And already released applications need to be updated by November 2019.

Project Treble

If you want to start developing an application for the next version Android, you can already test your application using the emulator Android Studio, or a Google Pixel smartphone. This year, Google unveiled a new development called Project Treble, which will allow manufacturers to quickly release updates to applications on Android. You can install the official GSI build Android Q on your device if it is compatible with Project Treble.

The essence of Project Treble lies in the modularity of the operating system, when the OS base is separated from the firmware installed on top of it. This will allow manufacturers to change only the OS base when new versions are released Android, which will increase the speed of updates. In addition to the CTS tests with which applications are tested, there is a new VTS test suite, or Vendor Test Suite.

With VTS tests, manufacturers will be able to verify that their devices meet the Project Treble requirements. One of the most important details that device manufacturers need to check when a new update is released is the ability to download GSI builds to Project Treble compatible devices. The GSI build is the clean version Android that device manufacturers use to check for Project Treble support when a new smartphone is released. However, Google wants developers to use GSI assemblies to test their applications for compatibility with the current version Android.

For example, if you have a Google Pixel smartphone, the only way to test your app in a future version Android is to install the Android Studio emulator. You can also use a special cloud service for testing, or buy a Google Pixel smartphone.

Each of these methods has its advantages and disadvantages, but if you have a working device that is compatible with Project Treble and you don't want to spend money buying the full version Android Studio to remove all restrictions, why wouldn’t install a GSI assembly on your device? If your application works well on a GSI build, then it will most likely work on all devices with this version Android as well.

The open source Android Q won't be available until August 2019, so official GSI builds are the only way to test Android Q on smartphones that aren't in the Pixel lineup.

to the content


Before starting the beta installation Android Q, you need to check your device for Project Treble compatibility, and if you can install the system image from the bootloader.

What's the first thing to do?

  1. Unlock bootloader if locked. Some Samsung smartphones with Snapdragon, Huawei, Honor, Nokia (except Nokia 8) will not work.
  2. Your PC should have the latest ADB and Fastboot utilities installed. Using outdated versions of Fastboot utility can lead to various errors.
  3. Your device must meet one of these points in order to work with Project Treble:
    • The device runs on Android 9 Pie right out of the box. If you bought a device with a pre-installed Android 9 Pie, you can skip the next step.
    • At market launch, the device was running Android 8.0 or 8.1 Oreo, but was updated to Android 9 Pie. Below we will tell you how to find out.

Before we proceed to the next step, we must warn you that when installing the GSI assembly, you will have to completely format your device. Therefore, back up your data before proceeding with any action.

Another important point is that all GSI builds do not pass the CTS tests at the time of their release. Therefore, if your application uses the SafetyNet protocol to check the device for passing the CTS test, nothing will work. In addition, these assemblies are not recommended to be used permanently, as they are full of various bugs. Google has published a list with currently known GSI build bugs on its website. If you find new bugs, you can report it to Google by filling out the appropriate form (see Google Issue Tracker).

to the content

Checking Project Treble compatibility

Open a console on your computer and enter the following command:

adb shell getprop ro.treble.enabled

If the answer is false, then your device is not compatible with Project Treble. So you don't have to continue further. If the answer is true, proceed to the next step.

Then we enter these commands:

adb shell
cat /system/etc/ld.config.28.txt | grep -A 20 “\ [vendor \]”

In the received response, you need to find the [vendor] section, and inside this section, find the namespace.default.isolated line. If the opposite is true, then you can install GSI-sideways on your device over the image Android 9 Pie. If the value is false, then you can install only the GSI assembly of the version that is currently on your device.

Project Treble compatible

How it should look like on the example of OnePlus 6T

Now you need to confirm if your device is rooted. If your device has been updated to Android 9 Pie, rooting is optional, but required to support OTA updates. Enter the following commands to check if your device is rooted:

adb shell
cat / proc / mounts | grep -q /dev/root && echo “system-as-root” || echo “non-system-as-root”

Now that you've made sure your device supports Project Treble, you need to figure out which version of the GSI build to download, as there are different images for different architectures. Enter the following command to find out what architecture your device is using:

adb shell getprop ro.product.cpu.abi

Write the information you received on a piece of paper: you will need it when downloading the GSI assembly.

to the content

Downloading the gsi assembly

Links to download the official GSI-assemblies Android Q are available on the official website here. You need to download the appropriate version, depending on the architecture of the device that we learned from the previous step. The download may take a long time if you have chosen the build with Google mobile services. We recommend downloading this option, as you can test your application right away with the installed Google services.

Once the file is downloaded, unzip it. There should be 2 files inside: system.img and vbmeta.img.

to the content

Installing the GSI assembly

  1. Reboot the device bootloader using the following command: adb reboot bootloader
  2. Next, we need to disable Android Verified Boot (AVB). Enter the following command: fastboot flash vbmeta vbmeta.img
  3. We format the system: fastboot erase system
  4. Now you can start installing the GSI assembly Android Q: fastboot flash system system.img
  5. Once the installation is complete, delete the user data: fastboot -w
  6. Reboot the device: fastboot reboot

That's all, upon further launching the smartphone, it should start with the GSI assembly installed. It should be noted that Android Q beta 2 GSI cannot be installed on OnePlus 6T, but on Xiaomi Mi 9 you can. Write your thoughts on the new Android Q in the comments.

Rate article
Everything for Android and not only | Tips, instructions, root, news and app reviews.
Add a comment