welcome to gammerson,in this tutorial,we will guide you to Unlock Bootloader, Flash TWRP, Root, Nandroid Backup and more.without wasting anymore time,Lets started.
Disclaimer:
Gammerson.com is not responsible for any damage happened to your device(s) while following this guide, Proceed at your own risk
The OnePlus 5 is quite easy to run and a relatively simple process.
Before you start, you should at least have tried to understand what part of the process will do.
Although each step is detailed and detailed in this guide, the process can be divided into three main steps – the precondition for each step is the execution of the step in front of it.
- Unlocking the bootloader
Opens the door to write the internal memory – this allows, among other things, the flashing of images to the main partition of the device. - Installing a custom recovery
A custom recovery is flashed to the recovery partition of the device and overwrites the existing recovery. Custom Recoverys often provide more features, such as installing flashable zips, creating backups (Nandroid Backup), and more. - Rooting
root rights can be obtained by flashed a pre-rooted custom rom or flashed a Zip containing the SuperSU binaries.
After completing the three steps, the device is rooted, has a custom recovery and an unlocked bootloader. Of course, there are tools that take over all of this, but when you are dealing with the topic, you will also learn some basic things about adb / fastboot and get a basic understanding of what is going on.
This method works by the way, regardless of the Android version installed on the device.
Before you go, you should have read and understood every step – if you have any questions, it is always better to clarify this before. Ask your questions here in the thread – together we will find an answer.
Some important things in advance
- View the file extensions
To prevent confusion when renaming files, file extensions should be displayed. - Pay
attention that the battery of your phone is at least 60% charged.
Also your PC / laptop should be connected to the power so that this does not spontaneously go down. The individual steps do not last long, but there is little more frightening and more harmful than if they break off. - (Optional)
When unlocking the boot loader, all data from the device is deleted. This includes apps, settings and even the contents of the internal SD card (pictures, music, etc.). Copy all important files from the phone to a PC or to the cloud.
Installing ADB and Fastboot on the PC
- Charging you ADB for Windows from the original xda thread down
- Start the exe file as an administrator
- Answer each installer’s question with “Y”
- Continue with the driver installation
Open the bootloader
Please perform the following steps before opening the boot loader:
- Turn on USB debugging
Go to the settings of your phone, click once on “About the phone” and click on Build number 7 times. This clears the developer options. - Enable OEM Unlock
In your phone, go to Settings for the developer options and activate the “OEM Unlock” option.
Ensure that the OEM unlock is activated before restarting the device. I’ve never seen this happen before, but there have already been cases in which it has deactivated itself. - Enabling Advanced Reboot
Go to Settings under Developer Options and select “Advanced Reboot”
Open the bootloader
- Turn off your phone and boot into Fastboot mode (Volume up + Power) or use the corresponding function of the extended boot menu (“Boot”)
- Connect your phone to the PC, open the input prompt on the desktop (Shift + Right click -> Open the prompt here)
- Enter the following and confirm with Enter
fastboot devices
This command lists all connected devices. If your phone is listed here, then you can proceed – if not, this means either that the device is not properly connected or that the ADB / Fastboot is not installed correctly. - Enter the following code to unlock the bootloader and confirm with Enter
fastboot oem unlock.
Please note that the data will be deleted from your device as described above. - Confirm unlocking the boot loader on your device (Volume Up gefolt by Power)
- After restarting the device, restart your device with the following command:
fastboot reboot
Your device is now restarted
Now you have unlocked your bootloader successfully.
Flashing a custom recovery
Please perform the following steps before you flash the recovery:
- Turn on USB debugging
Go to the settings of your phone, click once on “About the phone” and click on Build number 7 times. This clears the developer options. - Enable OEM Unlock
In your phone, go to Settings for the developer options and activate the “OEM Unlock” option.
Ensure that the OEM unlock is activated before restarting the device. I’ve never seen this happen before, but there have already been cases in which it has deactivated itself. - Enabling Advanced Reboot
Go to Settings under Developer Options and select “Advanced Reboot”
Flashing the Custom Recovery TWRP
- Download Custom Recovery from the original xda thread and place it on the desktop.
- Rename the just downloaded file to recovery.img
(make sure you rename the file to recovery.img and not in recovery.img.img) - Unplug your phone
- Boats in the Fastboot mode (Volume up + Power)
- Connect your phone to the PC, open the input prompt on the desktop (Shift + Right click -> Open the prompt here)
- Enter the following and confirm with Enter
fastboot devices
This command lists all connected devices. If your phone is listed here, then you can proceed – if not, this means either that the device is not properly connected or that the ADB / Fastboot is not installed correctly. - Enter the following code and confirm with Enter to flash the newly downloaded recovery
fastboot flash recovery recovery.img - Reboot your device after completing the process. Do not use the Fastboot command above. Instead, remove the USB cable from your phone and manually start the device in Recovery (Power + Volume Down)
- Click Reboot in the now opened recovery (TWRP) and select System. This completes the installation of TWRP and restarts your phone.
After that,you are now in twrp of your device.
Create a Nandroid Backup
Before you go, you should create a Nandroid Backup. So you can – if something goes wrong during some flashing – the current state again. By the way, the backup can be easily restored with the Restore option in TWRP.
But beware: before you install the Nandroid Backup, you must remove all Lockscreen locks in the settings of your Phones. Otherwise, you will not be able to unlock the device with a back-up system.
- Boot your phone into Recovery (Power + Volume Down)
- Click on “Backup”, mark all listed partitions (also EFS see below)
- Wipe (swipe) to make the backup
- Boats the phone after completion new.
Since the phone memory is too small for frequent backups, I recommend to back up the backups to a PC and keep only the most recently created backup on the phone. To keep the backups small, I always before the backup Cache and Dalvik. The first boot process takes after the playback but then something, but that does not really interfere.
Rooting
Now that the boot loader is unlocked and you have flashed a custom recovery with TWRP, you can root your device.
There are two options for this.
A) Flashing the SuperSU binaries, which gives you root rights with the Stock-Rom
- Download SuperSU.zip from the original xda thread .
- Connect your phone to the PC.
- Move the SuperSU.zip to your phone’s memory
- Unplug your phone
- Boot your phone into Recovery (Power + Volume Down)
- Click on Install and search the SuperSU.zip, which has just been moved to the phone
- Swipe to confirm the flash
- Restart your phone after completing the process
B) Flashing an already pre-rooted Custom Rom
Note: not all custom roms are pre-routed. Read from the respective source the thread / contribution to Custom Rome to learn more. Possibly there are also other requirements to be fulfilled!
- Download a Custom Rom. You can find them among other things in the xda forum under OnePlus 5 ROMs, Kernels, Recoveries, & Other Development or in the development area of the OnePlus 5 forum. In some cases the GApps have to be flashed, you can find them in the corresponding thread / post
- Connect your phone to the PC.
- Move the downloaded ROM (zip file) and the GApps (zip file) to your phone’s memory
- Unplug your phone
- Boot your phone into Recovery (Power + Volume Down)
- Wipe the system, Dalvik, Data and Cache
Wipe> Advanced Wipe> Select Dalvik, System, Data and Cache> Swipe to Wipe (Attention: all settings and data are lost, think about your backups!) - Click on Install and search the ROM (zip file), which has just been moved to the phone,
- Swipe to confirm the flash
- If necessary, install the GApps (zip file) also moved to the phone in the same way
- Reboot your phone
The first boot process after flashing a new ROM takes a bit longer, since the Dalvik Cache is created here and other things are set up.
No matter what option you chose. If you have come to this point, you have opened the boot loader of your device, installed a custom recovery, created a Nandroid backup and rooted your device.
If still any queries left in your mind,feel free to ask via comment section