• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[Guide] How to Root & install a custom recovery by disabling Encryption!

Search This thread

gbalerdi

Senior Member
Oct 17, 2011
69
14
Buenos Aires
Modified boot.img can be found here:

http://forum.xda-developers.com/showthread.php?t=3306684

Sent from my Nexus 5X using Tapatalk

These are on a Nexus 6P forum, so they are for the N6p. Anywhere we can get the current modified boot.img for N5x?
Or are they the same?

Thanks

---------- Post added at 02:50 PM ---------- Previous post was at 02:40 PM ----------

Oh I found them. Here

http://forum.xda-developers.com/nexus-5x/general/4-17-16-t3360574
 

sfhub

Senior Member
Oct 23, 2008
5,342
7,220
Hi if I disable the encryption with the next ota it's will come again?
If you boot with a stock boot.img it will encrypt your userdata.

If you can avoid booting with a stock boot.img, for example if, prior to booting with stock boot.img, you installed SuperSU, or you installed a custom boot.img, then your encryption will be preserved.

If you run the OTA, it doesn't really give you an opportunity to easily bypass booting the stock boot.img because it reboots right away when done.

So if you want to preserve an unencrypted userdata, I would suggest you flash relevant portions of the factory image view fastboot and bootloader.

(ie boot.img, system.img, vendor.img and possibly bootloader and radio if they changed)

Then prior to first boot. immediately boot into TWRP and install SuperSU.

Alternatively find a modified boot.img and flash that instead of the one from the factory image.
 
  • Like
Reactions: nokiagye

Top Liked Posts

  • There are no posts matching your filters.
  • 23
    This method successfully worked for me & @lysm bre (Thanks to him for the guiding)!

    Your phone will be unencrypted after folllowing this guide and successfully rooted too if I didn't mention that :D
    To flash ROMs in future you have to disable encryption so this method will make you ready for that too :)

    Here is my video in which I explained in detailed and I've done all the steps from beginning! So you can follow this guide too here- https://youtu.be/mUq1xdJ-7-E


    To Boot into Bootloader mode use command adb reboot bootloader or hold power and volume down button once its switched off!

    I'll modify & beutify the guide in future so stay tuned for that! :confused:

    1] Unlock bootloader- fastboot oem unlock [select yes by pressing volume up and then power button to confirm] :cowboy:
    2] Reboot & skip everything in setup as we data will be wiped again!
    3] Reboot into bootloader & flash the modified boot image- fastboot flash boot boot.img
    4] Reboot into system to make sure it's booting properly! [May not be necessary!]
    5] Reboot into bootloader again & flash twrp- fastboot flash recovery "recovery name".img
    6] Boot into TWRP & select allow modifications ! :cool:
    7] Goto Wipe & select format data !
    8] After that is done, reboot into system without rooting& skip through setup again!
    9] Now if you check the encryption status of your phone (Settings -> Security - Encrypt phone), it won't be encrypted anymore as it'll give you the option of encrypting it, which means it currently isn't encrypted.
    10] Now transfer the SuperSU zip file in the internal storage of the phone, reboot into TWRP, and flash SuperSU! :cool:

    BOOM! You have successfully rooted with encryption disabled.! Congratulations! ;)
    Just a reminder that for video explanation watch this- https://youtu.be/mUq1xdJ-7-E :D
    Downloads-
    Modified boot.img- http://bit.ly/1MVtrNr Thanks to @Chainfire ONLY FOR build no mdb08i as of now! Do not flash on any other build!
    TWRP recovery image- https://dl.twrp.me/bullhead Thanks to @Dees_Troy
    SuperSU zip- https://download.chainfire.eu/743/SuperSU Thanks to @Chainfire

    Modified boot images for all nexus devices- http://bit.ly/modifiedbootimages Thanks to @Chainfire
    7
    Ok guys,

    I unlocked and decrypted my 5X.

    Speed increase is very noticeable. Apps open instantly on the first launch from a reboot. Once they are in memory it's just blistering. It wasn't this noticeable when I decrypted my Nexus 6.

    I did not root so Android pay still works. I just wanted decrypted without root.

    Update: Interestingly though, benchmarks are scoring lower now than what I am seeing on a bunch of benchmark videos on the 5X. Google may have optimizations for encryption?
    Real world use seems quicker but if you are about to do this to your own 5X run a few benchmarks before and after for the hell of it. Might be interesting.

    Update 2: My bad. The benchmark decrease was caused by Google syncing 40 metric ass-tons of my data in the background. I only mentioned Benchmarks at all because it was such a drastic difference. Everything looks ok now.
    2
    guys, i just got a Android System Update for November's security patches, i have modified boot and custom kernel, also Selinux permissible and encription disable, since its security patches its ok to restart/install? thanks in advanced.

    You probably shouldn't attempt to install OTAs if you are running a custom kernel and modified boot.img. If you have TWRP recovery installed, it simply won't install. If you have stock recovery, there is the possibility that it will install and render the device unbootable.

    The process for me for updating to build MDB08M was to download the zip file, and then flash:
    radio-bullhead-xxxxxxx.img
    bootloader-bullhead-xxxxx.img
    boot.img (might be unnecessary, since we will flash a modified version later on.)
    cache.img
    system.img
    vendor.img

    While ignoring these:
    recovery.img (would overwrite TWRP)
    userdata.img (would erase your data)

    I used this guide for the syntax and order for flashing, especially part 8. "How To Flash The Factory Images (And Return To Stock)". We're not going back to stock 100% but the process for flashing is very similar.

    Before you reboot, flash the modified boot.img for your build (this allows your data to remain unencrypted and allows you to install SuperSU afterwards):
    http://forum.xda-developers.com/nex...-beginners-t3206930/post63781454#post63781454

    At this point I would do a regular boot just to make sure everything is working correctly.

    Then you would flash your custom kernel again if you wanted to (I believe flashing system.img will bring you back to the stock kernel). Also this is the point where you would install the SuperSU zip in TWRP if you wanted to root.
    2
    hello, what about current 6.0.1 ? if i do understand everything correctly, we need a new boot.img, right?

    Here is the modified boot.img for the first 6.0.1 release