yashsingh1/xdaforums huggingface dataset:
[Nexus 4 General] WasifSal:
I'm having problems >/

I wiped the Cache Like u said. but it is NOT booting up at all. Just goes to the X logo and gets stuck there

I have access to the Recovery and the Bootloader though. Any ideas?
[Nexus 4 General] DJBhardwaj:
Read from 3-4 pages back, other had this problem and got it solved.
[Nexus 4 General] bradym239:
Thank you!

I truly appreciate somebody putting something like this together. I'm relatively technically "proficient", I was very hesitant for fear of messing up a brand new (just got it in the mail last night) ~$400 device makes jumping into this realm a bit scary.

Enter this thread! Very succinct, well written, well organized descriptions helped me to feel a lot of confidence in moving forward. Fast forward a bit and my brand new Nexus 4 is unlocked, rooted and is running CM 10.2!

Very much appreciate you taking what had to be a LOT of time to help out others!

-bradym239
[Nexus 4 General] deathw15h:
does flashing a new kernel wipe my data/ ROM?
[Nexus 4 General] Chromium:
No.
[Nexus 4 General] kr33p0:
What do you mean by "fastboot -w" as I have the same problem as you seem to have had and can't fix it.

---------- Post added at 09:47 PM ---------- Previous post was at 09:23 PM ----------

okay it got fixed finally! A friend suggested i flash CWM Advanced Edition] PhilZ Touch and that one worked as all the other recoveries I tried to flash did so successfully but still the phone couldn't boot into them.
[Nexus 4 General] chainer22:
Hi OP,

Awesome guide here!

but i have one question. Can i use CF-Auto-root with the steps mentioned in your guide? how do i install it? i was thinking of flashing it thru CWM/TWRP, but to have custom recovery, one has to be rooted with Supersu first right?

i am kinda confused between rooting nexus 4 and having supersu in it. Does rooting nexus 4 means having supersu app installed in the nexus 4 device?

is it possible to be rooted but not have supersu in the nexus 4 device?

Thank you.
[Nexus 4 General] dodgebizkit:
Legend
[Nexus 4 General] chainer22:
Hi,

i got to the step where i flashed custom recovery and rebooted. when i tried to reboot it, it prompted me that it might go back to stock recovery, i clicked no, and it prompted me that i have yet to root it (options were either: "no" or "yes (system/xbin/su)" something along that line). i selected no again and my device is now stuck at the X logo.

Any solutions?

Thanks
[Nexus 4 General] Chromium:
Go back into recovery and clear the cache, then reboot. Are you using cwm?
[Nexus 4 General] chainer22:
Yes i am using CWM.

i noticed a list of recovery errors when i entered recovery. Should i be concerned about that? Sorry for the noob questions. i only rooted my i9305 before and it was relatively simple with CF-auto-root.

In this case where wiping cache doesnt help, what can i do next?
[Nexus 4 General] Chromium:
Yea you shouldnt be seeing errors. If clearing cache doesnt work try reflashing cwm, or maybe even switch to TWRP (i would highly recommend it over cwm).
[Nexus 4 General] chainer22:
yea it didnt work. i am still stuck at the X logo.

how do i go about reflashing cwm or TWRP? my only concept of flashing is flashing through the zip packages using CWM. i will really be thankful if you can guide me on this.
[Nexus 4 General] Chromium:
Just read the OP of this thread. The part where it says "Install Custom Recovery". This time download the TWRP image instead.
[Nexus 4 General] chainer22:
in the case where even this doesnt work, what other steps can i take to return my device back to the original state?
[Nexus 4 General] Chromium:
You can flash the factory images using this guide.
[Nexus 4 General] chainer22:
alright. i flashed twrp. it seemed fine. but twrp is asking me to enter my password? what password is that?
[Nexus 4 General] Chromium:
Weird. Try rebooting, or click cancel and then go into wipe and do a factory reset. If that doesnt work reflash TWRP.
[Nexus 4 General] chainer22:
i realize both recoveries prompt me to download and install SU as they detected that device is not rooted yet. should i click yes?

i tried factory resetting. it failed.

"factory reset complete. Failed"

"formatting cache using make_ext4fs...

done.

updating partition details..."

then it stopped there.

looks like i have no choice but to return to stock.
[Nexus 4 General] Chromium:
Yea something seems odd. Go back to stock using the guide i linked before, then if you want you can redo this another time.

If you want to continue, i would recommend reflashing TWRP and saying yes to flashing root. See how that goes.
[Nexus 4 General] chainer22:
thank you very much for your help, Chromium. I will try it later on, getting late over here in Singapore.

just a quick question: how long must i be stuck at the X logo to be considered abnormal and that something is wrong?
[Nexus 4 General] Chromium:
Probably around 15 - 20 minutes.
[Nexus 4 General] chainer22:
i have a question. OP instructed us to save the recovery img to desktop, followed by cd it to desktop.

what i did was, i saved the recovery straight into the platform tool folders cos i thought thats the easier way.

could this be the cause of the problem?
[Nexus 4 General] Chromium:
No, that's not the problem. Doing what you did is fine. I would try completely reflashing stock, then going through this guide again.
[Nexus 4 General] zzxop:
Nice tutorial, thanks so much
[Nexus 4 General] chainer22:
when i used "adb devices" in CMD, "list of devices" appeared but i do not see my device. I remember seeing it earlier on while setting up.

However when i used "fastboot devices", i see my device there.

Is there any error somewhere regarding this situation?
[Nexus 4 General] Chromium:
ADB will only connect while android is booted up and usb debugging is enabled, or while the phone is booting into android (the bootanimation)

Fastboot will only connect when the phone is in the bootloader/fastboot mode.

So if you are running the commands while the phone is in the bootloader, that is completely normal.
[Nexus 4 General] chainer22:
finally flashed stock! it worked! i really appreciate your help, Chromium_. i have really learnt something from this experience. now time to try flashing custom recovery again.
[Nexus 4 General] Chromium:
Nice job. Glad you are taking the time to think everything through and learn about stuff in the process, rather than going the easy route and using a toolkit resulting in loss of brain cells :)
[Nexus 4 General] zzxop:
Great! You are a nice man!
[Nexus 4 General] Rainmaker89:
thanks

Aapka bahot shukriya. :D got stuck on the ultimate nexus 4 guide for a long time until I found this post. Nicely done
[Nexus 4 General] maverickronny:
if i use method to prevent data loss, will ALL my data, like contacts settings etc remain intact or only the media files etc?
[Nexus 4 General] spaceman860:
Everything will be safe

BLACKED OUT LTE N4
[Nexus 4 General] NeXuS_4_UsEr23:
Can u direct me to that method

Sent from NEXUS⁴ via XDA Premium app
[Nexus 4 General] spaceman860:
Its mentioned in the OP

BLACKED OUT LTE N4
[Nexus 4 General] Fire Ball:
I tried the method to keep all my data but when I went into recovery (TWRP) it was asking me for a password and kept saying my device was encrypted. Was there sometime in 4.3 that made it so the method to keep your data does not work? I had to format data in TWRP in order to be able to get my phone to boot into the OS. I lost everything but it was no big deal since I just got my phone today and hadn't put anything important on it yet.
[Nexus 4 General] dante510:
AWSOME

Awesome guide man. It was really easy to follow and will be added to one of my favorite guide. CHEERS!:victory:
[Nexus 4 General] dsjd:
If I update Cwm recovery using Rom manager.. Is there a certain file which I can not delete after the recovery is updated.. If yes.. Then when can I delete it.. I read this on the guide below... Plz explain

http://xdaforums.com/wiki/ClockworkMod_Recovery#Installation_Methods

(Installation method 1a)
[Nexus 4 General] azahid2:
I am about to flash custom kernel on my nexus 4 while maintaining its stock ROM. Ive been wondering, what if i wanted to get the next OTA update, should i flash stock kernel back and relock the bootloader?
[Nexus 4 General] noahdev:
Bootloop

So I tried this method last night using CWM, thought I should share.

I got the E:can't mount /sdcard (OWTTE) error so decided to sideload it from the command line.

Flashed Paranoid Android and rebooted but got into the bootloop which has been mentioned here. Tried to do al the clear cache etc methods to solve the problem but no luck. Eventually returned to stock and booted fine after removing EVERYTHING.

I forgot the '-w' argument when sideloading could this have affected me outcome?

Will try again using TWRP later so hopefully that will go better and actually flash straight from the internal sd.
[Nexus 4 General] azahid2:
This is exactly of what happened to me. I tried flashing franco kernel using CWM, but it said "cant mount sd etc etc" so i went for another alternative, which i flashed franco using adb fastboot. And then i cleared cache, and reboot but i got stucked at the boot animation.

So please update me if you have succeeded using TWRP
[Nexus 4 General] inkubux:
I had the same issue. I had to format the card through TRWP, and then use the stock google image to sideload it.

After this manipulation everything went fine.

It was not a big deal for me either the phone was new :).
[Nexus 4 General] noahdev:
Hopefully this evening (GMT) but might not be until tomorrow; will keep you posted.
[Nexus 4 General] failly:
Can anyone confirm this?

And if it isn't just bad luck, how can you unlock the bootloader without losing data?
[Nexus 4 General] noahdev:
Resorting back to stock and using the threads method the TWRP was seamless and quick :) No problems this time round.
[Nexus 4 General] azahid2:
Thank you so much! Will give it a try later. Btw, if i wanted to go to stock back, is there any other way to do it without losing my data? (Apps, pics)
[Nexus 4 General] autalex:
Thanks

Hey there,

I just got my Nexus 4 in the mail yesterday and wanted to thank you for your awesome guide. I come from a phone, which would probably kill you if I threw it in your general direction (mobile stone age so to say).

The Android world was quite new for me and although i used your guide, I managed to force the Nexus into a bootloop. But because of your guide (and not using a toolkit) I was able to figure out what had gone wrong and it was fixed in minutes.

So thanks again and keep up the good work :D

For the guy above me:

If you force your nexus into a bootloop, there is a very neat thread on how to revert everything back to the factory settings and flash the latest stock android:

http://xdaforums.com/showthread.php?t=2010312
[Nexus 4 General] Primokorn:
Very useful "how-to" guide.

Hope to see the same thread for Nexus 5 :)
[Nexus 4 General] kipox:
Recoveries errors

Hi everyone,

I'm new to the nexus 4 forum but I come from HTC one s forum. I've received my nexus 4 a couple of week before and it's now time for me to the whole power of my phone --> espacially LTE.

As I like to know what I do, I dislike working with toolkits so I was very happy to fing this thread. My nexus has been updated to JRW66Y version.

I' successfully installed the google drivers and my nexus 4 is well recognize in adb mode as in fastboot mode, I could easily unlock my bootloader but my problem comes with recoveries.

I tried installed successfully the latest cwm recovery but when restarting to recovery I had a list of error surch as E: can't mount /cache/... I tried almost everything that come to my mind such as factory reset, wipe both caches, fastboot erase cache, fastboot format cache but nothing resolved these errors. Then i installed latest TWRP recovery and had the same errors than with CWM one.

As I needed my phone to be fonctional, I decided to return to stock by flashing bootloader,system, recovery, radio, userdata, boot, everything went well and had my phone back to original state.

Now that I have more time, I would like to retry the process but first I would like to know if someone has any kind of idea of what went wrong?

Thanks for your help and have all a great day.

Benoit
[Nexus 4 General] failly:
Did you flash a recovery immediately after unlocking or did you restart after unlocking?
[Nexus 4 General] kipox:
Hi and thank you for the answer,

Hummmmm... Don't remember well but I think that I restarted to bootloader. What do you think is the best to do , restart or not?
[Nexus 4 General] failly:
It depends, for 4.2.2 and lower you don't need to restart bootloader and you can flash a recovery directly. For 4.3 you MUST restart after unlocking and then go back into bootloader and flash a recovery otherwise you will hang on the 'X' bootscreen.
[Nexus 4 General] kipox:
Thanks,

I think that I'm getting sorted, I reinstall CWM than I flashed Supersu, when rebooted I had only 5,5gb free on sd card so I went back to CWM wipe and format everything so I recovered my whole 13 gb. Reinstalled all my apps, contacts, sms,... and it's working fine and I'm rooted.

By the way, (I don't know if it's a proper question, so please don't charge me on this) what is the best between CWM and TWRP ? And why ?

Thanks again for everything.

In love with my nexus 4
[Nexus 4 General] failly:
Hmm to be honest I wouldn't know for sure. I am a TWRP user and I've always been am TWRP user. I have read that TWRP is more stable and better for our N4 but I don't know if that's true.:p
[Nexus 4 General] Clauu:
Hy, what about unroot and relock the bootloader? How can we restore back the n4?
[Nexus 4 General] Chromium:
http://xdaforums.com/showthread.php?t=2010312

Sent using xda-developers app
[Nexus 4 General] dito33:
After flashing a rom I lost the root, still unlock tho. I'm flashing the latest SU successfully with twrp but doesn't stick, no root when check with root-checker.
[Nexus 4 General] Chromium:
What rom did you flash? Most roms have root built in.
[Nexus 4 General] fedexist:
Hi, after unlocking the bootloader and installing the recovery (and wiping the cache) I rebooted but it got me stuck at the bootanimation (the one with "Google"). Then I rebooted to recovery to try wiping cache (that is successful) and wiping Dalvik (that is unsuccessful), but the result is still the same. Moreover I tried then to wipe the system and flashing a new Rom but it failed again. Wht do you suggest? Could the problem be the bootloader or something else?

I'm on the latest TWRP 2.6.3.0 with the stock bootloader (MakoZ20i)

Every flashing is failing. Do I need to reflash stock image? I'll try so.

edit: reflashed boot.img and now it's working again
[Nexus 4 General] barrkel:
If you have a recent Nexus 4 running 4.3, don't do this. The relevant partitions seem to be encrypted stock (TWRP asks for a passowrd), and it seems you cannot clear the cache without recreating it unencrypted. The system won't boot after wiping the cache alone. I had to recreate /data and /data/media (i.e. a full user data wipe), using CWM, in order to boot.
[Nexus 4 General] Chromium:
Yes this seems to be right. Ill edit the post to say that it only works with the 4.2 bootloader.
[Nexus 4 General] mymeatb18:
Yeah I went through the same problem when unlocking. Bottom line is no way to unlock without full wipe.
[Nexus 4 General] Chromium:
Unless you are on 4.2 with 4.2 bootloader.
[Nexus 4 General] herclis:
Very helpful, thank you.
[Nexus 4 General] trevor12:
rooted, unlock bootloader, cwm - ota update

sorry for noobie questions - If I followed this guide from page one (unlock bootloader, install cwm recovery and rooted phone), I am still on stock rom and don´ t want change to custom rom (kernel), it will be problem use OTA update from google ? Or I must wait for some special stock rom changed for my nlocked cwm rooted phone from xda developers or I will have to relock bootloader, unroot , make ota update and again unlock, rooted it ?
[Nexus 4 General] dantezinn:
Subscribed to this thread, nicely done.
[Nexus 4 General] sunnysomyani:
if i unlock my boot loader will it also wipe my pure google os or it will just unlock

unlocking bootloader will also erase my pure google os or else it will just only delete my data and ulock boot loader please help new to these things :rolleyes::confused::confused::confused:
[Nexus 4 General] Chromium:
It wont erase your OS, just all of your personal data. So basically the phone becomes just like how it was when you first got it.
[Nexus 4 General] sunnysomyani:
And for backing up this or Google os is it important to root

---------- Post added at 08:09 PM ---------- Previous post was at 07:58 PM ----------

Hey do you rooted your nexus 4 on the jwr66y build number if yes then tell me the procedure to me also i want to root it but safely do tell mw if u know
[Nexus 4 General] Chromium:
Its the same process regardless of what build number you are on. Read the op...thats the procedure to root it safely.
[Nexus 4 General] sunnysomyani:
The rooting method shown on this page is also for android 4.3 with build number jwr66y just want to confirm and will these community help me if i messed up anything please tell me
[Nexus 4 General] Chromium:
Yes, like i just said above, the process is the same for all build numbers. If you have any problems just post here and im sure you will get help.
[Nexus 4 General] sunnysomyani:
OK thanks dude

RoCkInG WiTh NeXuS 4????
[Nexus 4 General] sunnysomyani:
which twrp version to install

which twrp ver to install for nexus 4 please tell and tell me which one is the best recovery twrp or a cynagenmod
[Nexus 4 General] Chromium:
Why do you keep quoting random old posts from this thread?

Anyways, the comparison is between TWRP and CWM (not cyanogenmod...thats a rom). They both have some ups and downs, but i personally prefer twrp as it has more functionality. Install the latest version thats available.
[Nexus 4 General] sunnysomyani:
sorry for that im new to xda thats why dont know about it can you please provide me link of the best twrp version coz i have gone to the twrp site but there were version and i dont know which one is latest and and so can u plz give me the direct link for tha best twrp version your think is the best please sir help me :eek::rolleyes:
[Nexus 4 General] Chromium:
Download it here: http://techerrata.com/browse/twrp2/mako

Pick the latest version (2.6.3.3)
[Nexus 4 General] sunnysomyani:
Ok thanks

---------- Post added at 08:59 AM ---------- Previous post was at 08:27 AM ----------

hey falshed twrp but nothing happend on my nexus 4 it showing just the fastboot mode only is their any problem

cmd showing-

sending recovery <8122 kb>...

okay [ 0.268s ]

writing recovery ..

okay [ 0.492 s ]

finished. total time: 0.764s

and after this nothing happend to the device it is in fastboot mode is everything ok

---------- Post added at 09:36 AM ---------- Previous post was at 08:59 AM ----------

Please help any buddy

---------- Post added at 09:51 AM ---------- Previous post was at 09:36 AM ----------

Anybuddy here

---------- Post added at 10:23 AM ---------- Previous post was at 09:51 AM ----------

Please help what happen to xda
[Nexus 4 General] sunnysomyani:
are you there plz reply me i need help
[Nexus 4 General] DJBhardwaj:
While you're in Fastboot mode, press the volume key twice (any + or -)

You will see Recovery Mode flashing on the screen, now just press the Power Button to select it. Your device will enter the Recovery Mode now
[Nexus 4 General] sunnysomyani:
twrp will be there na
[Nexus 4 General] DJBhardwaj:
Yes
[Nexus 4 General] sunnysomyani:
And how to get it out of recovery mode in nexus 4 can u tell me
[Nexus 4 General] DJBhardwaj:
Browse and explore the recovery itself.

Rebooting can be done under Reboot tab on the recovery home menu.
[Nexus 4 General] _DavidWebb:
When trying to open the sdk manager after extracting the zip, the little black window( i think the command window?) pops up for a split second then closes. Stuck here.
[Nexus 4 General] sunnysomyani:
falshed twrp on my nexus 4 but when i go to recovery i cant see twrp recovery when i go to recovery mode it only shows sleeping androidwith a caution sign what to do flashed two times but not got any sucess plz help sir
[Nexus 4 General] Primokorn:
Did you take the version of SDK (32 or 64bits) and does it match with your PC configuration?

You normally have to double click on SDK Manager.exe and install packages.
[Nexus 4 General] sunnysomyani:
gone to recovery mode but there is no twrp recovery in recovery mode
[Nexus 4 General] Forrest80:
twrp password?

Alright. I had Android 4.3

Installed TWRP 2.6.3.3

It asked for a password. I hit cancel.

I cant do a factory reset via twrp.

I notice from reading, some of the partitions are encrypted.

I just downloaded stock 4.2.2 and have a guide you guys posted a few threads up.

I am assuming I have to flash to 4.2.2 when they didnt use encryption and then start from there?

Or has there been a work around that fixes this?

Or begone newbie flash to 4.3 and see ya! haha
[Nexus 4 General] mymeatb18:
Fastboot wipe
[Nexus 4 General] sunnysomyani:
somebody help

somebody help me also
[Nexus 4 General] arffrhn:
When you see the android..press power then vol up. See if it enters recovery. Btw..you should read more before flashing anything. Without proper knowledge and understanding, you are more likely to make mistakes and render your phone useless (brick).

Sent from whatever the thing I use using whatever the app I have.
[Nexus 4 General] sunnysomyani:
but i have done the things that was written in the 1st page the same i did so now acc to you what should i do please suggest me
[Nexus 4 General] mymeatb18:
If u try to boot into recovery and there is no twrp then it has not flashed properly. Did u unlock boot loader just after flashing recovery? What android version are u on
[Nexus 4 General] Forrest80:
Thank you a "fastboot -w" via command prompt wiped userdata/cache and booted up the phone normal.

For searching thread purposes for other users.

twrp password
[Nexus 4 General] sunnysomyani:
Firstly i have unlocked bootloader as shown in the 1st page and then i falsed twrp 1st time didnt happen then again i flashed twrp then also no sucess

Build num jwr66y

Version andriid 4.3
[Nexus 4 General] sunnysomyani:
what do i do now plz tell me
[Nexus 4 General] BLADESMAN1889:
I've not been following so I can give only suggestion. Are you rooted ? What about installing recovery via goo app ?

Sent from NEXUS⁴ via XDA Prem [SLIMKAT 4:4]​
[Nexus 4 General] mymeatb18:
When u unlock boot loader on 4.3 u have to do full wipe. I suggest using fastboot to wipe data,cache, use fastboot -w to wipe. Another thing to try is reflash all other partitions minus bootloader. 4.3 is funny with unlocking bootloader
[Nexus 4 General] arffrhn:
Or maybe you mistyped the recovery name and you need to put recovery.img in the same folder where you open cmd. Try with cwm. If you succeed then root your device and flash twrp.zip to change to twrp.

Sent from whatever the thing I use using whatever the app I have.
[Nexus 4 General] sunnysomyani:
Will it be there any problem if i falsh cwm after failing woth twrp two times plz tell me
[Nexus 4 General] RohanM:
No problem there.
[Nexus 4 General] sunnysomyani:
Ok i will try to do that
[Nexus 4 General] sunnysomyani:
Successfully flashed cwm but when i selected reboot now the message appeared the phone isn't rooted and after that there was options

1No

2No

3No

4No

5No

6To root phone

7 yes

8yes

9 default recovery

10 go back

I selected go back and after 10 sec the booted and then after booting i again gone to fastboot mode then recovery mode from there but at that time there was no cwm it was showing the default android logo with caution sign any buddy please tell me what should i do
[Nexus 4 General] sunnysomyani:
some body plz help me which should i choose plz fast
[Nexus 4 General] Chromium:
Stock recovery overwrote your custom one. Reflash cwm.
[Nexus 4 General] sunnysomyani:
hey please wait and help me im flashing it right now so any doubt i will ask u plz

---------- Post added at 07:57 PM ---------- Previous post was at 07:53 PM ----------

chromium sir are you there i need help