yashsingh1/xdaforums huggingface dataset:
[Nexus 5 General] aliquzwini:
yes I promise ,here is my laptop I finished this guide serious ,twrp ,su

---------- Post added at 10:31 PM ---------- Previous post was at 10:29 PM ----------

Here is my situation see ,the su files in the system see it please
[Nexus 5 General] jd1639:
I see the problem. You have superuser not super su. See the op of this thread and download and flash super su in your custom recovery
[Nexus 5 General] aliquzwini:
thank you again ,I flashed su zip I promise in twrp this zip

but you told me to install superuser and update the binary In last reply ,so I did it but no luck it force close :( ,is it safe to flash the su zip again ? [emoji52]
[Nexus 5 General] jd1639:
no, I told you to download super su. It's safe to flash super su again
[Nexus 5 General] aliquzwini:
wow ,worked perfectly ,can't thank you enough god bless you [emoji3] .
[Nexus 5 General] jd1639:
Glad you got it working. Stay away from those tool kits you were using before
[Nexus 5 General] aliquzwini:
first ,I'm sorry my internet connection stopped yesterday for that reason I didn't replay for your last reply .

thank you for your kindness and your tips [emoji5]

أرسلت من Nexus 5 بإستخدام تاباتلك
[Nexus 5 General] nkod:
thank is awesome:good:
[Nexus 5 General] venkatkkesavan:
android 4.4.3

does this work with the new stock build android 4.4.3 also??
[Nexus 5 General] fxdil:
Yes.
[Nexus 5 General] nycwtod:
Thanks for the guide
[Nexus 5 General] gamal001:
this is first day with Nexus 5 and my version 4.4.3

my question if the procedure mentioned in op it will be work with this version or not ?

sorry for my question because I'm first time with this device
[Nexus 5 General] Chromium:
Yes, it'll work.
[Nexus 5 General] marcyff2:
Can anyone confirm if they got 4.4.4 and tried towelroot?

Supposidely 4.4.4 fixes some security issues but don't know if it means it stops root without UB
[Nexus 5 General] jd1639:
The kernel wasn't changed so no patches to the security in it.
[Nexus 5 General] Baldilocks:
I used CF-AutoRoot for 4.4.4 and flashed my own custom recovery.
[Nexus 5 General] BEDBOI2:
I updated to 4.4.4 and, if I remember correctly, the first time I rooted (I had TWRP v2.6.3.4 and used Option A from Rooting) SuperSU (v1.80) installed itself as user app, but now I have v2.00 as sytem app!

Can I ask why and how?

What will change?

Will I receive updates from Play?

Can I delete UPDATE-SuperSU-v2.00.zip from /sdcard/ ?

Thank you.
[Nexus 5 General] vin4yak:
No worries if it's a system app. Yes, you will get updates for the app as long as it's official. Did you flash the supersu.zip via recovery?? It must have installed itself as a system app. Yes, you can delete the zip file from the sdcard if you want to.
[Nexus 5 General] BEDBOI2:
Thank you.

Yes, I did it via recovery, like the first time, therefore my wonder.

Maybe it's a prerogative of the latest version of TWRP or SuperSU?

However there must be a reason if there is an option in the app itself to let it move in system..
[Nexus 5 General] BirchBarlow:
When you flash it through recovery, it automatically installs itself as a system app. It's been that way for the past several verions.
[Nexus 5 General] donnabelmartie:
How to update twrp and supersu?
[Nexus 5 General] vin4yak:
You can update twrp using "fastboot flash recovery recovery,img" Download the latest one from their website or you can flash it via the flashify app.

You can update su binaries from within the app if I'm not mistaken? Or you can download the latest supersu zip and flash it via recovery.
[Nexus 5 General] afizat:
I updated to 4.4.4 by OTA by accident and lost my root.. when i try go to to recovery mode I'm also lost the TWRP mode and get dead android.Can anyone help me to reinstall back the twrp & super su? For your info my boatloder still unlocked . thanks
[Nexus 5 General] miguepereira77:
One post above yours???

Enviado desde mi Nexus 5 mediante Tapatalk
[Nexus 5 General] afizat:
thank you .
[Nexus 5 General] Anderson2:
Quick question.

I accepted the 4.4.4 ota on my nexus 5 and updated successfully to 4.4.4. Of course I lost root. Please remind me which "twrp recovery" I should install using Factbook and "where" do I downloaded it from.

**Is the twrp I install the same whether it is nexus 5, nexus 7 2012, or nexus 7 2013?

I assume after installing twrp I next install update supersu using twrp install. Correct?

** so I learn, since the bootloader is unlocked, to regain root all that needs to be done is :

1 install twrp

2 install update supersu

Correct?

Thank you.
[Nexus 5 General] jd1639:
The twrp is not the same for all devices. Google nexus 5 openrecovery image file

Use fastboot flash recovery recovery.img, where recovery.img is the twrp image file.

Then flash supersu in twrp.
[Nexus 5 General] Anderson2:
Thanks. Glad I asked.

Is supersu also different for each device?
[Nexus 5 General] jd1639:
No super su is the same for all devices
[Nexus 5 General] Crittias:
Latest TWRP images here: http://techerrata.com/browse/twrp2/hammerhead (latest is 2.7.1.1)

Latest SuperSU is here: http://download.chainfire.eu/450/SuperSU/UPDATE-SuperSU-v2.00.zip (v2.0)

Technically, you don't _have_ to install TWRP. I usually just have the latest recovery in the same directory on my PC as fastboot. Then I:

download SuperSU file somewhere on my phone (I usually put it in the Download folder)

turn off my phone

reboot into recovery (power + volume down until I see the Android dude)

run cmd and browse to my fastboot/TWRP folder

type fastboot boot openrecovery-twrp-2.7.1.1-hammerhead.img

Use TWRP to install the SuperSU file.

Reboot, and enjoy root!
[Nexus 5 General] Anderson2:
Thank you. I'm all done now and everything is fine.

Just so I understand better, which is the one that actually gives me root? Is it installing the twrp recovery that does it or installing supersu?
[Nexus 5 General] Chromium:
Installing the supersu zip is what actually gives you root.
[Nexus 5 General] donnabelmartie:
When updating twrp, do I have to really do it under cmd-fastboot? Or can I just flash it? I'm on v2.7.0. For SuperSU, binaries will be automatically updated by the app? Thanks. Sorry for the noob question.
[Nexus 5 General] Anderson2:
Are you sure?

The supersu description in the play store says "supersu requires root". So it must be something else that gives you root first and then supersu gives you control.

Could installing a recovery like twrp or cmw be what gives you root?

I'm asking because after losing root (from ota update) the only thing I did to regain root was use fastboot to install twrp and supersu. So one of the two must be the one that "rooted" the device.

I'm just trying to understand and learn.
[Nexus 5 General] miguepereira77:
Yeah, he is right, what requires root is the SU as an application, so if u install it in a non rooted device it's not gonna work or prompt u to install binaries via recovery.

Enviado desde mi Nexus 5 mediante Tapatalk
[Nexus 5 General] Anderson2:
I think I did not express myself clearly.

I'm trying to learn *what* actually *roots* the device and gives me access to su.

It can't be supersu, because supersu will not install if you are not already rooted.

So, is it the unlocking of the bootloader?

Or, the installation of a recovery like twrp?

Or something else?

I am already rooted, so I'm just trying to understand.
[Nexus 5 General] lack_android:
Unlocking the boot loader allows you to flash the custom recovery. Running in the custom recovery gives you full access to the SD devices, which is effectively root access, but only as long as you're in the recovery image.

Using the recovery to install SuperSU with enhanced privs then allows SuperSU to grant root to other apps who ask for it.

On older devices this granting of rights to SuperSU was done by setting up the su executable with SUID-root permissions, so every time that exec ran the kernel gave it root access. You need root to grant that permission in the first place, which is where the recovery image (or some other exploit) comes in.

But on KitKat as I understand it the SUID method doesn't work, and instead you end up injecting a long-running daemon into the boot sequence that runs as root and is contacted by the su executable to raise its permissions. Likewise, you need root to edit the boot scripts, which is what the SuperSU zip installer does from the recovery.

Hope that answers your question!
[Nexus 5 General] miguepereira77:
As I said, the SU binaries are the ones that gaves u root acces, and u get them by flashing SU wich is different from the SU aplicattion (if u install it in a non rooted device it will promt u to install SU binaries via recovery) u can get in play store...So, either u flashed SU, installed a rom which comes pre rooted or when u install TWRP it prompts u to install SU.

edit: [MENTION=3635124]lack_android[/MENTION] explained faster and much better
[Nexus 5 General] Anderson2:
Aha! Now I understand. That makes sense.

So, if I have an unlocked bootloader, and I try to install supersu or a recovery like twrp it will prompt me to install the su binaries. Can installing the su binaries be done simply from the phone or is that done only via adb or fastboot?

Thanks
[Nexus 5 General] lack_android:
Based on the question you just asked, I'm not sure you fully understand... Re-read my previous answer. The SuperSU binaries need to be granted permissions by something that already has root.

So the short answer is: you can't do it from inside the running android system of an unrooted phone, regardless of whether your boot loader is unlocked or not. When the system is running, the bootloader doesn't matter.

Unlocking the bootloader lets you use the 'fastboot' command on your PC to install (or even just run) the custom recovery. Running the custom recovery gets you root access to the SD device, so you can install SuperSU with appropriate privs. Then when you reboot into the system after that, SuperSU maintains those privs and can hand them out to other apps who ask it.
[Nexus 5 General] theganguly:
Hi all,

I tried following steps in OP but each time I installed custom recovery, phone would revert to stock recovery on rebooting.

This time around, I just see the red triangle with android robot (assuming stock recovery) but phone doesn't respond to any of the 3 physical buttons. I have done rooting before but not many times.

Because it isn't responding to any physical buttons, I am afraid that I might have bricked the phone. Can someone help me out?

EDIT: Nevermind, held power button for about 10 seconds and it just rebooted :) Issue partially resolved as I am able to use my phone normally but CWM recovery still doesn't stick to phone. What am I doing wrong?
[Nexus 5 General] lack_android:
What steps did you follow exactly? When exactly did the recovery get reverted? Did you install SuperSU?
[Nexus 5 General] jd1639:
Redownload the recovery image and try it again. Hopefully it was a bad download
[Nexus 5 General] theganguly:
I was installing custom recovery and then rebooting the phone in bootloader mode. Now when I tried to push SuperSU zip file to phone, it wouldn't work as it would revert back to stock recovery.

Thanks for the help. I was able to resolve by copying the SuperSU zip file to phone manually, and flash it on phone as soon as I installed custom recovery. This way, even if my custom recovery disappeared on reboot, the root would still stick.
[Nexus 5 General] BirchBarlow:
You are using fastboot flash recovery not fastboot boot command in the terminal, right?
[Nexus 5 General] lack_android:
I'm curious now: did the custom recovery disappear this time too? Or did it stick around?
[Nexus 5 General] garrettgu10:
lol
[Nexus 5 General] Cookies:3:
So I reached the third step and after a little struggle in copying the SuperSU binaries to the location I wanted I installed them and went to reboot, now I'm promoted with a message that states that "Root access possibly lost. Fix?"

I know its a common problem and from what I have understood its because cwm cant recognize SuperSU or because of a new version but what happens if I press yes?

Also when I tried to install CWM the first time I got a message that stated that the phone might rewrite stock recovery, I tried to go back (and also the CWM stated that it can create root access or something like that after I went back), so after trying to go back twice my phone restarted and when I tried to enter the recovery for the third step I got the stock recovery with the red triangle...

Btw: my nexus is connected to the pc through the original usb cable directly to the motherboard on a usb 2.0 port.

edit: nvm, decided to just press no and in the worst case scenerio to install twrp and root again, everything is working just fine, if the message will appear again shall I install twrp?
[Nexus 5 General] jwhyte:
OK so to confirm you have super su installed (in your app drawer) and stock recovery?
[Nexus 5 General] Cookies:3:
No no, I reflashed CWM, I'm fine im just annoyed by this message.
[Nexus 5 General] jwhyte:
Got it. Then your all set. If your looking for a better option check out philz recovery.
[Nexus 5 General] Cookies:3:
Flashing philz will delete CWM completly?

Nandroids as well?

Thanks mate.
[Nexus 5 General] jd1639:
Philz will replace cwm. Nandroids will still be compatible
[Nexus 5 General] BirchBarlow:
Stock CWM will give you that message every time you exit even after you've rooted. It's one of the many quirks with stock CWM. I recommend PhilZ Touch CWM or TWRP.
[Nexus 5 General] Maliivers:
help..

i'm currently in CWM Recovery and i want to change to TWRP, because i can't update to Stock 4.4.4 with CWM (it says Install Error: Status 7)

so what should i do? do i just have to flash the recovery file? without wiping data?

are my files gone if i change the recovery?

thanks.. :)
[Nexus 5 General] jd1639:
You can flash a twrp zip file in cwm and it'll replace it. Don't do any wipes. But cwm nandroids are not compatible with twrp and visa versa
[Nexus 5 General] Nastrodamous:
fixed my issue apologies.
[Nexus 5 General] RamDrt:
My current bootloader version is HHZ11d and the newest version is HHZ11k so my question is why update it? What are the benefits of doing so since my phone seems to be working well? Just curious.
[Nexus 5 General] Brian D:
This has to be the most comprehensive set of instructions I have ever seen. Well written and well thought-out. You are obviously one of the rare people who can actually explain how to do something. We are truly a rare breed. ;) Kudos!

I do not have my Nexus 5 yet but this thread is already saved in my favorites for when I get my device.
[Nexus 5 General] Chromium:
If your phone's working fine, there isnt really any need to update it (if it ain't broke, don't fix it). However if you're planning to flash newer CM builds (or derivatives) they might not install due to your outdated bootloader. CM implemented a check for bootloader version, and if its not up to date (HHZ11k), the installation will not start.

Thanks. Just got my Nexus 5 yesterday, and will be following my own guide to root it :)
[Nexus 5 General] jd1639:
Hope it works:D
[Nexus 5 General] Chromium:
Haha, me too! If it doesn't I'll have to delete my XDA account, buy an iPhone, and live the rest of my life in shame. :laugh:
[Nexus 5 General] :
You should be ashamed already for even joking about it! ;)
[Nexus 5 General] RamDrt:
Gotcha, thanks for the info. Haven't noticed because I've stuck with stock/ish roms
[Nexus 5 General] neo2306:
i am new to custom recoveries,

i want to know which recovery should i install TWRP or CWM ??
[Nexus 5 General] aavvaallooss:
I use TWRP but you try both and decide yourself. Don't forget about PhilZ
[Nexus 5 General] jd1639:
I prefer twrp. You might also try philz. Cwm is obsolete
[Nexus 5 General] Georgiazen:
two recoveries installed. help

i installed rom managr after i was having an issue installing recovery in fastboot. doesnt boot to either. it says bad command cn i delete these reveries and how
[Nexus 5 General] Chromium:
The bad command screen you're seeing sounds like stock recovery. You'll need to flash a custom recovery via fastboot, as ROM manager requires root which I don't believe you have yet.
[Nexus 5 General] PRoyal22:
I had the same problem. If he would done it that way, your "enter tab" solution would have worked :)
[Nexus 5 General] androidsnax:
Hi guys, just got a quick question before I go ahead and flash the unofficial CWM - what is the process when there's an official version available? I mean, I would flash over the top of this one right? But what would happen to any nandroid backups I had made with the unofficial one... still available after flashing?

Sorry to ask what might be such a noobish question, first time I've had such a brand-spanking new nexus with not much development for it (so far!)

Thanks :cool:

...sent from the Nexus 5000
[Nexus 5 General] Chromium:
Yep, when the official one is released you simply fastboot flash that on top of your current recovery, and it will overwrite it.

Any nandroid backups that you have made should remain on the phone.
[Nexus 5 General] androidsnax:
Nice one - off I go then, cheers for the guide btw, get a little rusty as it's been a year or so since doing it with my n4. ;)

...sent from the Nexus 5000
[Nexus 5 General] mevensen:
It's been a while since I played with custom recoveries. What are the current, major differences between TWRP and ClockworkMod? IIRC, TWRP had better interface, ClockworkMod allowed for flashing a couple things TWRP could not. Is this still true?
[Nexus 5 General] bikeryder007:
I thanked the OP, but I just wanted to give a big thanks here for this guide. I got my first Nexus phone this afternoon, and it is already unlocked, and rooted with twrp thanks to this guide. Great work. I rooted my first phone about 9 months ago, and was too nervous to remember the process, but this time I wanted to learn how to do things properly. Thanks again for this guide!
[Nexus 5 General] lukas_s:
Nevermind!
[Nexus 5 General] Synyster06Gates:
Awesome tutorial, this was the first time for me to do it on my own without a tool kit. Had to flash TWRP twice, but it all went smooth. Thanks for the great write up!
[Nexus 5 General] elementaldragon:
Ok... i might just be having a brain fart, but neither ADB nor FastBoot seem to be able to detect my N5. Reboot into fastboot holding volume down and the power button, plug the phone in, type in "fastboot devices" to see what's there, and nothing. have USB debugging enabled (though i don't think that's necessary for fastboot), using the slim dev pack
[Nexus 5 General] Chromium:
Twrp has a bit more functionality and feature, while cwm keeps everything barebones with only the important key features. However there shouldn't be any difference in what they are able to flash.

Did you install the drivers using the guide I linked in the op?

Sent using xda-developers app
[Nexus 5 General] elementaldragon:
Hmm.... missed that one. Installed drivers i had found, but didn't realize they didn't also include the adb bridge drivers.
[Nexus 5 General] BlackFlag79:
This is important for anyone having the same problem (I did).

It kept booting into the red triangle robot, so I repeated the following two steps (and only these steps):

"cd Desktop/Nexus"

"fastboot flash recovery recovery.img"

Then it had "Restart Bootloader" already selected, so I chose that, then I chose "Recovery Mode" after it had restarted. Now it worked perfectly fine.

I tried the other suggestions (like using a different cable or a different USB port) but this solved it.

Thanks dcsworld, and everybody else! This was my first root.
[Nexus 5 General] WMguy:
This is what I did for anyone making the same stupid error. Just rename the file to 'recovery' not 'recovery.img'

:good:
[Nexus 5 General] xBeerdroiDx:
for the record, and for any new users that are wary, i used this guide today on my device and was unlocked with twrp and rooted within 10 minutes. thanks for this guide [MENTION=4883664]Chromium_[/MENTION]. cheers
[Nexus 5 General] fansoccer57165:
ADB cannot see phone

So I was able to unlock the bootloader and root the phone. At the time TWRP was officially support and I did push the custom recovery to the phone. Google did an update and I wasn't able to stop it in time, after that the recovery went back to stock and gives me the android with the red triangle and says no commands. When I try to connect to the device in fastboot mode, the adb cannot see the device. I have tried to delete and re-install the drivers but no luck, also have tried installing the drivers on multiple computers but still no luck. Does anybody have any ideas on how I can connect to my phone through adb again and flash twrp?
[Nexus 5 General] nrvate:
Thanks all! :)

Anyone managed to get adb shell access in recovery? It can be really handy to get a shell within recovery when hacking through stuff.

I'm getting a device "AOSP On HammerHead" in device manager, with VID/PID 18D1:D001, which the driver doesn't know about. I could probably hack up the INF, but curious if anyone has a better solution? Stupid windoze, but unfortunately I had to return my Linux laptop to my employer since I said take this job and stick it. Oh well, next job will likely give me a newer, nicer one ;)

I did screw up and forget that unlocking the bootloader clears data, and got everything set up thinking "I'll root this later!". Oops. Then I F'ed up again and booted into recovery directly after installing it, answered sure to the "Install SU" then tried to boot normal. Basically ended up having to reflash the phone from factory images for being over-excited.. LOL @ me, but all is well now. Rooted with TWRP, backed up, T-mobile cheap plan activated... Getting to know the device. It's faaaaaaaaaast.
[Nexus 5 General] Printif:
Wow This is Fantastic :)
[Nexus 5 General] xnatehatex:
There isn't anything you can possibly do to harm your battery by rooting/unlocking your device is that? I'm experiencing harshly low usage out of my battery. Even when on standby.
[Nexus 5 General] nrvate:
You need to be in the bootloader to connect with fastboot. adb and fastboot are different; fastboot talks to the bootloader, adb talks to the debug bridge daemon (adbd) running as a system service.

Power the device off, hold down both volume keys, power on. Should very quickly get an android with his door open and "FASTBOOT MODE" in red followed by product versions.

In device manager, you should have a "Android Bootloader Interface" device with the phone attached to the PC in fastboot mode. If you're getting a yellow-banged device or don't see anything of the nature, your drivers are borked up.

With the device in this mode, fastboot should see the device, but not adb:

/cygdrive/e/and/sdk/platform-tools # adb devices
List of devices attached

/cygdrive/e/and/sdk/platform-tools # fastboot devices
022289e8f0a695bd fastboot

Once you get there, and fastboot is seeing the device, download the factory image and run flash-all.bat

https://developers.google.com/android/nexus/images

This will put everything back how you got the device and you can start over -- Except you won't have to unlock the bootloader this time, that stays unlocked until you relock it.

I can't imagine you managed to destroy the bootloader, so I'm thinking either you're not differentiating properly between fastboot and adb modes, or your drivers are hosed.

You do get into the bootloader and see versions including "BOOTLOADER VERSION HHZ11d", right?
[Nexus 5 General] devaughnaw:
I'll attempt this although I'm a little hesitant.

This would be my first time doing something like this, and I just got this phone today. :crying:

*EDIT*

Is this a Windows only guide?
[Nexus 5 General] Georgiazen:
problem is i am getting an error with the recovery image in cmd
[Nexus 5 General] Chromium:
What's the error?
[Nexus 5 General] Georgiazen:
it says it cant find image. i renamed it recovery.img
[Nexus 5 General] Chromium:
Is the recovery.img in the platform-tools folder (where the adb and fastboot executables are)?
[Nexus 5 General] Georgiazen:
yes
[Nexus 5 General] Chromium:
Is your command prompt pointed into the platform-tools directory? Could you upload a screenshot of the prompt and folder?
[Nexus 5 General] Georgiazen:
thanks worked!!!!!!