[HOWTO] Install /e/ on OnePlus 6 running Android 10

As many have found out (I did, the hard way), the documented installation procedure for /e/ on OnePlus 6 is not very verbose and does not work if you start from a device running Android 10.

Since now I have a correctly working device and I took note of the steps, I am sharing them here.

RELEVANT SOFTWARE AND DOCUMENTATION SOURCES

  • /e/ install guide for OnePlus 6: https_://doc.e.foundation/devices/enchilada/install
  • Latest adb/fastboot: https_://dl.google.com/android/repository/platform-tools-latest-windows.zip
  • Most up-to-date TWRP for OnePlus 6 (unofficial): https_://forum.xda-developers.com/oneplus-6/development/recovery-unofficial-twrp-touch-recovery-t3860815
  • OnePlus’ MSM Download Tool, a.k.a. factory recovery tool (just in case): https_://forum.xda-developers.com/oneplus-6/how-to/tool-msmdownloadtool-v4-0-international-t3798892

DISCLAIMER
Use these instructions AT YOUR OWN RIKS: they worked for me but cannot guarantee they will work for you.
You will have to wipe the device a couple of time, so YOU WILL LOSE ALL YOUR DATA. Make your backups as necessary.
I am not responsible if you lose your precious data or if you brick your device.

PREPARATIONS
It is assumed you installed the latest adb/fastboot tools from Google (link above) and these are in the $PATH of your shell. Here below I used a CygWin shell on a Windows 10 machine, but the same commands are applicable to Linux, Mac OS etc.

You should also install the USB drivers for OnePlus 6, as described in official /e/ installation guide.

If you have any data to backup before wiping the phone, do it now because you WILL lose them.

ENABLE USB DEBUGGING
Enable USB debugging on device:

  1. Enable Developer mode: Settings -> About Phone -> Build number -> tap 7 times
  2. Settings -> System -> Developer Options -> USB debugging = on

Confirm authorization from device (“Allow USB debugging”) when asked while running ‘adb devices’ from PC

[user@cygwin:~] adb devices
List of devices attached
a92743xx        device

UNLOCK BOOTLOADER
Enable bootloader to be unlocked from Android Settings:

  1. [If not already done] Enable Developer mode: Settings -> About -> Build number -> tap 7 times
  2. Settings -> System -> Developer Options -> OEM unlocking = on

From PC:

[user@cygwin:~/OnePlus/SW] adb devices
List of devices attached
a92743xx device

Restart device into bootloader mode:

[user@cygwin:~/OnePlus6] adb reboot bootloader

Once rebooted to bootloader, ensure fastboot (not adb!) can connect:

[user@cygwin:~/OnePlus6] fastboot devices
a92743xx fastboot

Unlock bootloader:

[user@cygwin:~/OnePlus6] fastboot oem unlock
OKAY [ 0.031s]

Now, on the device, use the volume keys on device to select “UNLOCK THE BOOTLOADER” and then press Power button to confirm.

Device will be wiped at next restart (takes 15 sec).
Device will do a second, complete reboot and show a warning about bootloader being unlocked.
This second, complete boot process will take a while as the device data was completely reset (takes about 90 sec).

TEMPORARILY BOOT FROM TWRP RECOVERY
Since the device has been completely reset after bootloader was unlocked, it is necessary to re-enable USB debugging to continue:

  1. Enable Developer mode: Settings -> About Phone -> Build number -> tap 7 times
  2. Settings -> System -> Developer Options -> USB debugging = on

NOTE: this guide assumes installed Android is version 10 (Q), hence installs twrp-3.3.1-16-enchilada-Q-mauronofrio.img, which is more up-to-date than currenlty available “official” TWRP for the device (3.3.1.2 at the time of writing) and supports Android 10.

Verify you can connect to the device:

[user@cygwin:~/OnePlus6/SW] adb devices
List of devices attached
a92743xx device

Restart device to bootloader mode:

[user@cygwin:~/OnePlus6/SW] adb reboot bootloader

Once in bootloader mode, check you can connect using fastboot (not adb!):

[user@cygwin:~/OnePlus6/SW] fastboot devices
a92743xx fastboot

Check you have the correct TWRP at disposal:

[user@cygwin:~/OnePlus/SW] ll *.img | grep Q
-rwxrwxr-x+ 1 user None 29061120 Dec 27 17:22 twrp-3.3.1-16-enchilada-Q-mauronofrio.img

Send TWRP to device for temporary boot with that recovery (no writing yet):

[user@cygwin:~/OnePlus/SW] fastboot boot twrp-3.3.1-16-enchilada-Q-mauronofrio.img
Sending ‘boot.img’ (28380 KB) OKAY [ 0.844s]
Booting OKAY [ 0.078s]
Finished. Total time: 1.031s

Phone should reboot automatically into TWRP, otherwise use volume buttons to choose “Recovery mode” and press Power to confirm.

INSTALL TWRP RECOVERY SO THAT IT IS PERSISTENT ACROSS REBOOTS
As described in the install guide here: https://forum.xda-developers.com/oneplus-6/development/recovery-unofficial-twrp-touch-recovery-t3860815

  1. TWRP -> Swipe to allow modifications
  2. Using Windows Explorer on PC, upload TWRP image (*.img) for Android 10 (Q)
    • file: e.g. twrp-3.3.1-16-enchilada-Q-mauronofrio.img
    • location: e.g. “This PC\OnePlus A6000\Internal Storage\TWRP”
  3. TWRP -> Advanced -> Install Recovery Ramdisk -> (select *.img from chosen directory) -> Swipe to install

Reboot to installed TWRP: TWRP -> Reboot -> Recovery (confirm)

Now TWRP should be persistently installed in both slots, A and B.

INSTALL CHOSEN CUSTOM ANDROID OS
Reference: https://doc.e.foundation/devices/enchilada/install

Check OS package is not corrupted (check mdsum is correct as per /e/ download page):

[user@cygwin:~/OnePlus6/SW] md5sum.exe e-0.7-p-2019121434061-dev-enchilada.zip
a96d0aa78125c797f0aeb4d5c1dd66a3 *e-0.7-p-2019121434061-dev-enchilada.zip

Note: “md5sum” is part of CygWin set of commands, might not be available in default Windows 10 shell (DOS) or PowerShell.

Upload OS package to device:

  1. TWRP -> Advanced -> ADB sideload -> Swipe to start sideload
  2. From PC, send OS file (in zip format):

[user@cygwin:~/OnePlus6/SW] adb sideload e-0.7-p-2019121434061-dev-enchilada.zip
serving: ‘e-0.7-p-2019121434061-dev-enchilada.zip’ (~47%)
Total xfer: 1.00x

Note: it does not reach 100%.

Once installation has finished, return to the TWRP main menu, tap Reboot, and then System.

First boot will launch the Lineage OS recovery (that has replace TWRP) and it will say something like “Can’t load Android system (etc.). You may need factory data reset.”. Don’t panic.

This is probably because previous stock OnePlus OS was Android 10 while the newly installed OS (/e/) is Android 9.

Choose “Factory data reset” to delete user data. Phone will reboot once done.

RESTORE TWRP AFTER INSTALLING /e/ OS
Lineage (or /e/) OS will overwrite TWRP with its own recovery. If necessary, re-flash TWRP *.zip via ADB sideload.

Lineage Recovery -> Apply update -> Apply from ADB

From PC:

[user@cygwin:~/OnePlus/SW] adb sideload twrp-3.3.1-16-enchilada-installer-mauronofrio.zip
serving: ‘twrp-3.3.1-16-enchilada-installer-mauronofrio.zip’ (~0%)

Reboot and enjoy.

IF THINGS GO (VERY) WRONG AND THE PHONE DOES NOT BOOT
Your best friend is OnePlus’ factory recovery tool, a.k.a. MsmDownloadTool.

Download link at the beginning of this post.

Usage:

  1. Switch off phone
  2. Disconnect USB cable from PC
  3. Click VolumeUP button for 5 or more seconds and then connect USB cable to PC
  4. Launch MsmDownloadTool: the phone should appear as “connected” under one of the COM ports. If it does not, repeat steps from #1 to #4.
  5. Click “Start” button to restore the phone (takes approx 220 sec).

Now the device is restored to stock Android 8.1.0 image from 2018.05.17, with locked bootloader and with USB debug disabled.

Disconnect USB and close MsmDownloadTool.

4 Likes

Great instructions @OnePlus6user! One question… is it necessary or recommended to re-lock the bootloader after the flashing of /e/ is all completed? Thanks!

Hi @jsparknz, I personally have not re-locked the bootloader yet, as I am still having issues with the OTA upgrades (see this post: OnePlus 6 (enchilada): over-the-air (OTA) upgrade not working for me). By the way, does OTA work correctly for you? Would be great if you can comment in the above topic.

Locking the bootloader is something I however would like to do in the future: it would be great if you could try it out and document the necessary steps in detail.

Please keep in mind the operation will require erasing all your data, so make the necessary backups beforehand and be ready to restore.

Maybe you already knew, but here are the places I would suggest to start from for trying the operation:


Let me know how it goes!

Hey, sorry, just realized I did not answer your question:

No, it is not strictly necessary, but if you don’t do it, everytime you reboot the phone, you will receive a very verbose warning message (something like: Warning, unlocked bootloader … security issue… don’t store any sensitive data on device etc. etc.) before the boot of the OS.

I don’t know if by re-locking the bootloader the message disappears completely or if it is substituted by something else, AFAIU it depends on the device. In such case the boot image would be signed and the bootloader would be re-locked, but the signature of the boot image would not correspond to the original stock one loaded by the mainifacturer.

If you have success in re-locking the bootloader, let us know what happens to the pre-boot warning screen.

Regarding if the re-locking operation is recommended or not, the first XDA link of the previous post states the following advantages:

  1. Virtually total protection of your data, especially if encrypted
  2. Inability to flash another recovery, even stock recovery (if OEM unlock allowed is unchecked)
  3. Inability to flash another kernel, including stock kernel, (again if OEM unlock is unchecked)
  4. Inability to unlock bootloader in fastboot, see above
  5. Total inability to flash anything in fastboot. The only access to the phone is through TWRP
  6. You can still change/update roms, backup/restore data to your liking
  7. You get a different boot warning screen: ‘your phone has loaded a different operating system’ with a fingerprint (four rows of numbers). Write them down and compare once in a while: if the numbers are different, someone (and I am talking a sophisticated adversary) tempered with your phone

The disadvantages are:

  1. You would have to set up things once
  2. When changing or updating roms, one extra step is required - flashing Chainfire’s modified Verified boot signer zip to resign kernel (right after Magisk and before reboot).

Plus, I would add, the need to restore your data because the operation erases it all.

… is it necessary or recommended to re-lock the bootloader after the flashing of /e/ is all completed?

I myself haven’t tried it yet, as I’m not aware of possible negative consequences for hardware and system operation. Our /e/ experts say:

I disagree with the above, especially the “you can’t lock the bootloader after flashing any custom rom” statement.

I have not tried with my device (OnePlus 6) and /e/, but I know for sure that the bootloader could be re-locked successfully when running, for example, Lineage OS on OnePlus 5: the two XDA links above demonstrate it is actually possible.

It is quite possible that it is device-dependent.

GrapheneOS runs with locked bootloader and verified boot on Google Pixel models.

The developer of GrapheneOS writes about OnePlus::

The answer to requests for device support will always be similar, and devices like those aren’t going to be supported because they don’t offer anything compelling in terms of privacy and security.

OnePlus also doesn’t meet the minimum security requirements. They don’t keep up with monthly security updates, among other issues.

Hey there, I followed this guide yesterday. Using android aftter few years again. Thank you so much for helping those with android 10 installed alredy. Anyway - everything went fine, I followed the guide using ubuntu linux.

There are only two things I made differently. I did not restore twrp after installing /e/ os and I did lock the bootloader by “fastboot oem lock” after /e/ installing.

Everything looks good so far, heavy testing yet to come though.

1 Like

Hello @Hawk, that sounds exciting. I’m curious about the result of your " heavy tests".

@archje by heavy tests I mean daily use as an iphone replacement without any deep android knowledge, so my output would be “it is working”, “it is not working” or “it is bricked”

1 Like

Yes @Hawk , please do so. It’s and remains exciting how the device will behave now during an OTA update and more …

1 Like

I’ve made an OTA update to latest /e/ rom. Phone rebooted and got stuck in locked bootloader. It was possible to switch to recovery and use adb and fastboot. I had to flash TWRP again (I did use pie 9 version now) and I had to flash /e/ again. So locking the bootloader the way I did wasn’t good idea. At least if you wanna do OTA update.

You’re great, @Hawk. I thank you for your courage and your joy of experimentation.

Okay, a working OTA update is a fine thing, but not important for everyone. Will you continue to use the device with the bootloader locked?

Hello @Hawk, I am happy my guide has been useful for you, thanks a lot for reporting back your experience and confirming the same set of commands works fine under Linux.

It is interesting that you did not install TWRP and re-locked the bootloader and OTA still does not work, it’s a scenario to add to the OnePlus 6 (enchilada): over-the-air (OTA) upgrade not working for me topic.

I am curious to hear if with the stock recovery (Lineage OS recovery) and unlocked bootloader OTA works or not.

So far, OTA not working is the only relevant issue I have found while running /e/ on my phone. I use it daily for work and personal purposes since 2.5 months and all is smooth.

@hawk, out of curiosity: since you re-locked the bootloader, what happens to the startup message that warns that your device is at risk, you should not store any sensitive data on it etc.?

AFAIU depending on the device, the message could be substituted by another warning (about the OS being signed but not being the original OS provided by the vendor) or could disappear completely, accepting /e/ as a legit replacement of the stock OS.

Do you have a picture or a video of how the boot sequence looks like when you re-lock the bootloader?

@OnePlus6user hey, I tried to perform next OTA update with Lineage recovery and unlocked bootloader and it didn’t work too, I had to flash TWRP and do the update manualy (with zip file), then it booted correctly without loosing any data.

I’m not sure about the startup message with locket bootloader, I don’t remember to be honest :slight_smile:
I can still try to lock bootloader and check it, I could re-unlock again afterwards.

Hi @Hawk, this confirms OTA is totally broken.

That would be great to know, even if we know without a working OTA the locked bootloader is unfortunately not a long term option.

Hi @OnePlus6user,

Actually not. A user said it works for him.
I installed /e/ two days ago by following exactly the same steps as he did so I just need to wait for the next update and see if the OTA update works for me.

Hope it helps,