OnePlus 6 currently running eOS-q. Plan for upgrading to eOS-r & how we did it

I don’t have this device but a friend does. The R release, albeit slightly delayed, may be just around the corner and some users will need to get stock android 11 onto the device before flashing the new eOS-r.

So far, the best info I’ve found is this post from XDA

There are links in the original post to fastboot roms, but only up to 10.

On the last page of the there, post#1.252, there is a link to a fastboot image for 11.1.1.1, but it appears not to have been tested for installation yet.

In another post on the thread #1.244, there is a link to a guide for unbricking that looks interesting.

Windows seems to be favoured for flashing these roms by the inclusion of a flashall.bat that will do the work of flashing all the files automatically.It would be nice if there was a flashall.sh script as well but never mind. There is a list of all the commands for linux and I suppose it might be easy to incorporate a script if one had the knowledge. Otherwise one would have to do it line by line in the terminal I guess.

Anyone got any ideas? @Grendel I know you’ve flashed stock on OP6 before, how did you do that?

1 Like

you want to upgrade to e os R when is out ,or you want to go back to stock? if you want to upgrade you just have to extract payload.bin and with fastboot flash

fastboot flash aop_a aop.img
fastboot flash aop_b aop.img
fastboot flash bluetooth_a bluetooth.img
fastboot flash bluetooth_b bluetooth.img
fastboot flash dsp_a dsp.img
fastboot flash dsp_b dsp.img
fastboot flash dtbo_a dtbo.img
fastboot flash dtbo_b dtbo.img
fastboot flash fw_4j1ed_a fw_4j1ed.img
fastboot flash fw_4j1ed_b fw_4j1ed.img
fastboot flash fw_4u1ea_a fw_4u1ea.img
fastboot flash fw_4u1ea_b fw_4u1ea.img
fastboot flash modem_a modem.img
fastboot flash modem_b modem.img
fastboot flash oem_stanvbk oem_stanvbk.img
fastboot flash qupfw_a qupfw.img
fastboot flash qupfw_b qupfw.img
fastboot flash storsec_a storsec.img
fastboot flash storsec_b storsec.img
fastboot flash vbmeta_a vbmeta.img
fastboot flash vbmeta_b vbmeta.img
fastboot flash vendor_a vendor.img
fastboot flash vendor_b vendor.img
fastboot flash LOGO_a LOGO.img
fastboot flash LOGO_b LOGO.img

if you want critical partitions boot in TWRP

adb push abl.img /sdcard/abl.img
adb shell dd if=/sdcard/abl.img of=/dev/block/bootdevice/by-name/abl_a
adb shell dd if=/sdcard/abl.img of=/dev/block/bootdevice/by-name/abl_b
adb push cmnlib.img /sdcard/cmnlib.img
adb shell dd if=/sdcard/cmnlib.img of=/dev/block/bootdevice/by-name/cmnlib_a
adb shell dd if=/sdcard/cmnlib.img of=/dev/block/bootdevice/by-name/cmnlib_b
adb push cmnlib64.img /sdcard/cmnlib64.img
adb shell dd if=/sdcard/cmnlib64.img of=/dev/block/bootdevice/by-name/cmnlib64_a
adb shell dd if=/sdcard/cmnlib64.img of=/dev/block/bootdevice/by-name/cmnlib64_b
adb push devcfg.img /sdcard/devcfg.img
adb shell dd if=/sdcard/devcfg.img of=/dev/block/bootdevice/by-name/devcfg_a
adb shell dd if=/sdcard/devcfg.img of=/dev/block/bootdevice/by-name/devcfg_b
adb push hyp.img /sdcard/hyp.img
adb shell dd if=/sdcard/hyp.img of=/dev/block/bootdevice/by-name/hyp_a
adb shell dd if=/sdcard/hyp.img of=/dev/block/bootdevice/by-name/hyp_b
adb push keymaster.img /sdcard/keymaster.img
adb shell dd if=/sdcard/keymaster.img of=/dev/block/bootdevice/by-name/keymaster_a
adb shell dd if=/sdcard/keymaster.img of=/dev/block/bootdevice/by-name/keymaster_b
adb push xbl.img /sdcard/xbl.img
adb shell dd if=/sdcard/xbl.img of=/dev/block/bootdevice/by-name/xbl_a
adb shell dd if=/sdcard/xbl.img of=/dev/block/bootdevice/by-name/xbl_b
adb push xbl_config.img /sdcard/xbl_config.img
adb shell dd if=/sdcard/xbl_config.img of=/dev/block/bootdevice/by-name/xbl_config_a
adb shell dd if=/sdcard/xbl_config.img of=/dev/block/bootdevice/by-name/xbl_config_b

i upgrade that way without the critical on my OP6T from 10 to 11 when i tried lineage os based on 11.1.1 firmware

2 Likes

Thanks for the reply. I’ve edited the title to try and make clearer. Device is on eOS-q and soon it will want to be on eOS-r. This means one has to upgrade it with stock android 11 first , no? Then flash eOS-r.

The xda thread has those commands along with various fastboot roms, including 11, where all of the image files are contained in zips. They can be unpacked easily without need for extracting a payload.bin.

What I’m wondering is do you have to flash line by line, one at a time in linux terminal?

Edit: Actually I’ve learnt that its easy to write a simple shell script; a shebang line at the top of the commands in a .txt file and then make executable. So that would automate the flashing.

Hello @chrisrg sorry for not replying sooner but am away from home at the moment and can’t give an exact reply from memory. I have the zip file of the old Oxygen OS for my OP6 on a USB stick in case I need to go back to stock ROM but it dates from last year and I think was version 9 of Android so would not be much use going to the R version.
I came across it on a link from the XDA forum and followed advice there to flash this file on both slots before flashing eOS. However I had to reflash TWRP in between each time to keep it with eOS installed. In that way I was able to root my phone with Magisk. I prefer this to able to use apps requiring root privileges.
But I was interested to see your useful link with information about OnePlus’ future policy.

Having reread @kopap list of flashing commands I think it’s the way I would go and you’re right that an executable would work under Linux to simplify the operation. Let me know if this works for you when the R version comes out. I would dearly like to keep my OP6 up to date as I am very pleased with it.

2 Likes

Install Lineage4microG and you are always up to date :wink:
Connection to /e/ can be done manually without any restriction…
BUT you will have a maintained, up to date OS and not an outdated with ancient security fixes…

LOS install instructions specify in “Basic Requirements”:

Warning: Before following these instructions please ensure that the device is on the latest Android 11 firmware.

Because custom roms work on top of the OEM android installation it is my opinion that the best base for installing eOS-r onto the phone would be from stock android 11 OOS; though I admit my beliefs are based more on intuition rather than technical know how.

Given that the bulk of the partitions on the phone are stock android (custom rom only flashes over a few partitions) it seems to make sense that to get the best out of the hardware is to keep the stock android up to date for the intended custom rom.

For that reason I’m coming round to the idea that restoring the phone to it’s previous stock android state (OOS 10) and then updating OTA to OOS 11would provide the best base for android 11 custom roms.

1 Like

Yesterday I helped my friend upgrade his OP6 from eOS-q to eOS-r. It all went smoothly except for a minor stall at the last step. The plan was to restore the phone to it’s previous stock state (OxygenOS 10) described in the XDA link at the top of this thread and then update it to OOS 11 OTA in the phone’s updater. Then install eOS by following the installation instructions, as opposed to the upgrade instructions which miss out the crucial step of sideloading the copy-partitions zip.

Restoring stock with fastboot rom

Host pc was running Fedora therefore a linux shell script was simply created with the commands copied into it; only the fastboot partitions, not persist or the critical partitions. It may be useful to add the line fastboot reboot at the end or at least make a mental note of what the last command was; just so you are certain the process has completed! :wink:

Flashing eOS-r

It can be confusing for anyone who needs installation instructions because there are two sets and both need some corrections. In addition, both sets describe twrp recovery method of wiping but not e-recovery, which is slightly different.

If you’re using e-recovery and need instructions then use the Lineage instructions as a how-to for wiping and format data.

After sideloading the os zip, we returned to recovery home screen and pressed reboot system. Phone started rebooting but went to what looked like part of the Oxygen os recovery, offering options to reset data etc. I can’t remember the exact steps but we selected equivalents to wiping and resetting after which the phone continued to successfully boot eOS-r.

If I was doing it again I would select factory reset in e-recovery after sideloading and before rebooting system.

3 Likes

The dev team wanted only one method to be shared to avoid confusing users. Will check if we can have both options -TWRP and eRecovery methods included without confusing users.

1 Like

Yes, that’s a good idea. I know it’s hard to find a balance with instructions but in this case e’s install page offers three different recoveries!

The LOS install page is clear and concise and includes the most important steps. If one was to diligently follow them, step by step, all would be well.

The /e/OS documentation pages for fajita and enchilada should be showing only the eRecovery now.

1 Like

Well, that’s good. Now the installation docs are sorted but the upgrade document (link in #9 above) is still the same. Plus it could do with corrections (link also above) , especially the addition of copy partitions step imo.

Or do you really need seperate upgrade instructions? It’s the same steps as the install but just make sure to be on Android 11 first. There is a caution about about stock android versions on both sets but from a user point of view I think the caution in the upgrade doc is the best because it is less ambiguous.

1 Like

I also could upgrade my OnePlus 6 thanks to these instructions by first installing Android 10 stock ROM, using the OnePlus upgrader to upgrade to Android 11, and then installing /e/OS R. Thank you all for the information! :grinning:
There were some small differences:

  • I wanted to be sure to reinstall an official version of the OnePlus stock ROM. An Android 10 version of the stock ROM was needed, which is fortunately still offered by OnePlus Germany [1].
  • It is possible to extract the files to be used in the batch script with the payload dumper Python script.
    • If you are a Windows 10 user, you can easily install Python from the Microsoft Store.
    • The payload dumper script had issues because the dependency bsdiff4 was missing. There is a GitHub discussion that solved my problem (as a solution, I commented the relevant line out).
  • The extracted ROM could be installed with the batch script listed above.
  • Afterwards, the OnePlus Updater performed the upgrade to the Android 11 stock ROM.
  • Finally, I followed the instructions to install /e/OS R. (I think that I had to explicitly reboot once or twice into recovery by holding the corresponding volume keys because the smartphone was stuck in fastboot mode if the keys were not pressed.)

[1] xhttps://www.oneplus.com/de/support/softwareupgrade/details?code=PM1574156173727

In reply to others in this thread and, I hope, to give some useful help to anyone planning this upgrade to Android “R” on the OP6, I thought I would give a longish description of how I managed it. Having similarly upgraded two other phones - one a OP5T - I found this upgrade the longest and most complicated. However, this may be due to my uncertainties and lack of expert knowledge as I was most concerned by the warning on both the Lineage site and here on the upgrade page for this device:
before flashing /e/R install Stock Android 11
As I don’t use Windows and wanted to avoid the hassle of using the MSMDownload Tool to completely restore my phone to a stock ROM version of “R”, I followed the instructions above from @kopap - many thanks to himfor this info.

This requires unpacking the necessary *.img files from a recent OxygenOS ROM file. To get these files at the suggestion of @Tentos I downloaded it from the German OnePlus site.

However, from my understanding the “22.J.52_OTA” version still comes with Android “Q”, which left me a bit concerned as it is the 22.J.62 version which comes with “R”.

As my PC has Arch Linux I was able to use the excellent AUR version of payload-dumper programmed with the “go” language instead of python and it extracted the files needed for the flashing listed by @kopap above. Using ADB I put my phone in fastboot mode to complete the procedure with no difficulty encountered.

Rebooting into Recovery I expected there to be an option to complete the upgrade to version “R” of OxygenOS but I was back in the e-recovery installed by previous updates. Beforehand I had copied the OTA zip file 22.J.62 to flash this if necessary to have the required firmware for the upgrade. However, I could find no way to use e-recovery to flash this from internal memory.

Crossing my fingers I decided to go ahead with sideloading the most recent e-os-r dev file for enchilada and see what happened. I did a Factory reset/ then Format data/factory reset before the sideload on the active slot_b but avoided sideloading the copy-partitions zip file in case the upgrade failed so I could switch to slot_a and be back with my previous “Q” version.

To my surprise, after the sideload installation completed without a hitch, my phone rebooted into a clean version of e-os under Android “R” even quicker than with the upgrades of my two other devices.

To be able to root my phone and use my Titanium backup to restore my previous apps & data I decided to install the latest TWRP by booting the twrp.img file first and then following the recommended procedure to have this recovery installed in the Ramdisk permanently, also in case I need to re-flash the copy-partitions file to have both slots on the same version. In my thinking the next update should do this automatically, but I may be wrong and would be grateful if some more knowledgeable person puts me right about this.

I am still left perplexed as to why the flashing of the above-listed *.img files should have worked especially as the boot.img and the system.img files extracted with the others were not included. To have a working stock OxygenOS I would have thought they at least would be necessary, but it explains I suppose why my reboot into recovery landed me in the initial e-recovery.

Thanks to all in this thread for helping me with this not-so-simple upgrade to e-os-r :+1:

2 Likes