yashsingh1/xdaforums huggingface dataset:
[Nexus 4 General] RohanM:
It will reboot after downloading ota or we have to download it manuly from somewhere ?

---------- Post added at 12:01 PM ---------- Previous post was at 11:53 AM ----------

As per that thread if i flash that zip it also includes stock recovery so my device will be full stock. Right ?
[Nexus 4 General] TecQuality:
[MENTION=1566190]efrant[/MENTION]

about the 12) Flash the recovery partition: fastboot flash recovery recovery.img can i flash a custom recovery instead (like the CWM)? or i need to flash the stock first and then the custom using the same command?

TIA
[Nexus 4 General] efrant:
Probably LGNPST.

You don't need to flash a stock recovery first. You can flash your custom recovery right away.

(I had written this as a return to stock guide, so most if the things you don't have to do if you are not trying to get back to stock.)
[Nexus 4 General] efrant:
Should be, yes.
[Nexus 4 General] RohanM:
Is that compatible with N4?? Or its for optimis G ?
[Nexus 4 General] efrant:
Yes, it works for the N4. But i don't want to have discussions on LGNPST in this thread. Google has provided us with a tool called fastboot, which can get you back to stock, and is perfectly safe (unlike LGNPST).
[Nexus 4 General] LJGDY:
I followed the guide, step by step. I remember typing the command for the boot.img...

This wouldn't be so bad if I didn't have to return the phone to Google!! :(
[Nexus 4 General] Federico_96:
Well i think that you can still flash your boot via fastboot
[Nexus 4 General] bozzykid:
Did you try just running the flash-all.bat file from the factory image?
[Nexus 4 General] Danny.ns:
I did this for 4.2.2 and everything worked wonderful and i think i got the idea. I plan on following this guide for 4.3 again, do i need to wait for SuperSU to be updated or does this not matter? I basicly want stock 4.3 (incl stock recovery) but with Root.
[Nexus 4 General] kyokeun1234:
I believe if you flash the latest SuperSU zip file, you should be fine
[Nexus 4 General] Danny.ns:
I take it the CWM flashable zip from here (v1.41) should give me root?

Tbh, all I would need root for is custom kernel (specifically, francos). I'll probably wait with root for now, thank you anyways for the response! :o
[Nexus 4 General] kyokeun1234:
Hey, don't flash that. It won't give you root (I just found out). I tried it and SuperSU app is showing up, but it can't find the binary. I'll wait until 4.3 zip with root shows up
[Nexus 4 General] Danny.ns:
Thanks alot for the heads-up!
[Nexus 4 General] spaceman860:
You need this one for 4.3 http://download.chainfire.eu/340/SuperSU/SuperSU-JWR66N-S005-130625-1.41.zip

Sent from my Nexus 7
[Nexus 4 General] efrant:
Even that one doesn't work properly on the N4. It will give you root, but you will lose it after a while, and the daemonsu process will start to use up 70%+ of your CPU time and burn your battery. Work-around for the moment is to turn off, re-flash the zip, and reboot.
[Nexus 4 General] spaceman860:
Reflash this one or the regular 1.41 one

Sent from my Nexus 7
[Nexus 4 General] Danny.ns:
Just a heads-up, flashed 4.3 using instructions (didnt bother with root at this time). All worked fine except the device showing as a 8gb. Wiping cache alone didnt help - but wiping cache and factory reset did (instructions on how to fix this was 100% clear - thanks!).

Running fine so far! :)
[Nexus 4 General] rawdealer:
It works as it should without this "workaround"...........

Sent from my Nexus⁴
[Nexus 4 General] TassM:
I just flashed 4.3 and everything works fine...except for one thing. I cannot boot into cwm recovery, when i try the device first reboots and the google logo shows up. Then after a few seconds the screen turns black (the backlight is still on) and nothing more happens. I waited for 10-15 minutes while taking a shower but the screen was still black. I then tried different versions of cwm recovery and also redownloaded them + tested twrp, but I get a black screen everytime. Booting into stock recovery works fine thoug...

Anyone know what to do about this? :)
[Nexus 4 General] sebr:
I can confirm this :(
[Nexus 4 General] daveric:
Update 4.3 Jelly Bean

Thanks for this thread I've just updated my Nexus 4 to 4.3 Jelly Bean everything went smooth.

" :p Initially I got stuck on the nexus animation, so I've rebooted in recovery and wiped cache! Did work but only showed 8GB :silly:, Next wiping cache and factory reset sorted everything :cyclops:!

Now I'm on 4.3.

Thank you very much guys

:good:
[Nexus 4 General] efrant:
I can still boot into recovery, no issues. What version of CWM or TWRP are you using? I can verify that TWRP 2.6 works.
[Nexus 4 General] sebr:
I tried openrecovery-twrp-2.6.0.0-mako.img. Not flashing it permanently but booting it for testing.
[Nexus 4 General] hugopt:
Apply update on rooted rom

Hello,

I had a stock rom 4.2.2, and just rooted it.

Can I apply the OTA stock update 4.3 in my rooted rom?

If apply I have to root the rom again?

Will I lose all my data?

Thank you.
[Nexus 4 General] efrant:
A few questions:

1) How long has it been since you flashed SuperSU?

2) How long has it been since you rebooted your device?

3) Do you have many root apps installed? Can you list them?

4) Would you mind running your device with "Show CPU usage" on (found in developer settings) and let us know if you see the daemonsu process eating up a lot of your resources? (It only starts to use up CPU time once you lose root, and usually takes hours after a reboot.)
[Nexus 4 General] hwti:
I can't boot into recoveries with "fastboot boot" (blank screen, adb and backlight work so it's perhaps something related to the display)

I tried :

- recovery-clockwork-touch-6.0.3.3-mako.img

- recovery-clockwork-6.0.3.3-mako.img

- openrecovery-twrp-2.6.0.0-mako.img

Then I flashed TWRP, and it works when launched from the bootloader.

I checked again after, booting recoveries still ends with a blank screen.
[Nexus 4 General] TassM:
I tried cwm 6.0.2.0 and 6.0.3.3 (both "normal" and "touch"). I also tried twrp 2.6.0.0.

I didnt flash any of them, just "fastboot boot X.img".
[Nexus 4 General] hwti:
When booting a flashed recovery from the bootloader, the kernel command line is :

console=ttyHSL0,115200,n8 androidboot.hardware=mako lpj=67677 uart_console=enable lcd_maker_id=primary lge.hreset=off lge.reset=mode_reset gpt=enable lge.kcal=0|0|0|x lge.rev=rev_10 androidboot.emmc=true androidboot.serialno=00XXXXXXXXXXXXX androidboot.bootloader=MAKOZ20i androidboot.baseband=mdm bootreason=recovery

When booting with "fastboot boot recovery.img", it's different

console=ttyHSL0,115200,n8 androidboot.hardware=mako lpj=67677 androidboot.emmc=true fastboot=true androidboot.serialno=00XXXXXXXXXXXXX androidboot.bootloader=MAKOZ20i androidboot.baseband=mdm bootreason=fastboot

I don't know if the differences matter, perhaps they are the same with on 4.2, but I see at least one option related to the lcd missing.

Perhaps this could explain the blank screen.
[Nexus 4 General] sebr:
Yeah I agree to you, that seems to cause it. I flashed now and it works flawless.
[Nexus 4 General] TassM:
Oookay...

So I tried flashing instead of just booting into...and it works

Just waiting for root now :)
[Nexus 4 General] efrant:
Not sure why it doesn't work. See below. In any case, I can make a zip that, once you flash it, it will automatically re-flash the stock recovery every time you boot your ROM. That way, you can use the "fastboot flash recovery recovery.img" command and it will essentially be the same as "fastboot boot recovery.img". Let me know, and I will try to put it together for you tomorrow.

Interesting. Wonder why they changed it? It certainly wasn't like that in 4.2.
[Nexus 4 General] fkloznica:
efrant*

i flashed 4.3 image that i downloaded from google site,whit your expert guide :good: ,do i have the same android like people who are waiting for OTA ? and why people don't push 4.3 to their phones whit this simple steps in your first post.. ?
[Nexus 4 General] efrant:
Yes, you have exactly the same thing as those people will have once the update via OTA. Not sure why people are waiting.
[Nexus 4 General] hwti:
Even the stock 4.3 recovery doesn't work if booted with fastboot !

Trying different kernel command lines with the "-c" fastboot option, I found the needed parameter, which is only given when booting a flashed recovery : lge.kcal=0|0|0|x

Without it, the screen is blank.
[Nexus 4 General] rawdealer:
1. 6h

2. I've rebooted phone few times. From last reboot it's about 2h

3. 5 /No

4.

Edit: I'm running more than 14h ;) and still have root :D

Sent from my Nexus⁴
[Nexus 4 General] RohanM:
I am waiting because I never experienced an OTA update.. My privious device GS3 was 4.1.2 out of the box.. & even before that having LG P690 tha tnot even got updated to ICS.... So waiting for OTA. :D
[Nexus 4 General] el_charlie:
It's the bootloader.

It happens since the 4.3 leak and the z20i bootloader.

You can try flashing the old z10o bootloader (it boots 4.3 just fine) and then fastboot boot command will work.

It's very annoying because I use to keep the stock recovery and only use CWM or TWRP to root. Now I have to flash a custom recovery, do my thing and reflash the stock one again.

Cheers!
[Nexus 4 General] faddyie:
Thanks [MENTION=1566190]efrant[/MENTION] once again for helping in 4.3. just a question that CWM recovery 6.3.3 i got, whenever i go into recovery the message below comes as

warning: no file_contexts

what does that mean?

How do i rectify it?

great work efrant!
[Nexus 4 General] efrant:
No idea. I haven't seen that before.
[Nexus 4 General] CMNein:
That's regarding provisions in CWM for SELinux, normal to see it, and don't worry about it for now.
[Nexus 4 General] RohanM:
Issue in recovery (flash process)

"Warning: No file_contexts" you can safely ignore this warning displayed in Recovery while flashing the rom. It is a part of SE_Linux and nothing to worry about.
[Nexus 4 General] hwti:
You can still boot a recovery without flashing it, but you have to specify the kernel command line

Solution 1 (works on my N4, not sure it will work for all hardware revisions) :

fastboot boot customrecovery.img

you see a blank screen

get the default fastboot kernel command line : adb shell cat /proc/cmdline

adb reboot-bootloader

Append lge.kcal=0|0|0|x to the default fastboot kernel command line :

fastboot -c "your_default_command_line lge.kcal=0|0|0|x" boot customrecovery.img

Solution 2:

fastboot flash recovery customrecovery.img

launch the recovery from the bootloader

wait until it's loaded

get the bootloader kernel command line : adb shell cat /proc/cmdline

adb reboot-bootloader

fastboot flash recovery stockrecovery.img

Use the bootloader command line to launch the recovery from fastboot :

fastboot -c "your_bootloader_command_line" boot customrecovery.img
[Nexus 4 General] faddyie:
Thanks again. You make ppl learn adb and fastboot. Great job!

Thanks. Is there any way to get rid of it besides goto other recoveries. lolx

Furthermore, after first boot in to CWM recovery when i select reboot system. It asked "do you want to flash su to root (narration may vary)". I selected yes. But not showing root rights? This might not contain the SU.zip... However, is SU.zip 100% working available for 4.3 as i read there is no finally working one avlble yet. Thanks.
[Nexus 4 General] CMNein:
Not a TWRP user so I don't know if they've implemented similar provisions yet.
[Nexus 4 General] yahoowizard:
Do I skip steps 1-3 in part D if I already have an unlocked bootloader?
[Nexus 4 General] LTavaress:
edit
[Nexus 4 General] simorangkir_dcs:
after i update to 4.3 my device only shows 8GB, I tried to enter recovery but ended up with died android image with red exclamation mark.

anyone can help me?

Edit1: nevermind, I got it right
[Nexus 4 General] Ivan Fuentes Hagar:
worked flawlessly, thanks!
[Nexus 4 General] quendil:
Hey everyone!

A new cwm recovery was released version 6.0.3.4.

http://download2.clockworkmod.com/recoveries/recovery-clockwork-6.0.3.4-mako.img

Maybe it's released to work better with the 4.3 firmware?

Edit for a silly question:

If i use the fastboot command fastboot flash recovery-clockwork-6.0.3.4-mako.img to flash the recovery, will the supersu update zip work normally?

:fingers-crossed:
[Nexus 4 General] spicediablo:
None of the root works with 4.3 right now according to OP? That means those on 4.3 now are not rooted?
[Nexus 4 General] beren:
same problem, how to solve?
[Nexus 4 General] simorangkir_dcs:
Try this solution http://xdaforums.com/showthread.php?t=2033692
[Nexus 4 General] hughfollett:
Guys I followed this guide as it was the first time flashing stock roms with this, but I used the flash-all.bat and I had no problems with memory..

Inviato dal mio Nexus⁴ |

Rom: 4.3 stock | Kernel: stock
[Nexus 4 General] chrone:
i managed to gain root by using this following article from Chainfire here. my friends are also successful getting root in maguro gsm device. :)

the trick is we have to choose "NO" when prompted to disable flash recovery after flashing the custom supersu made by Chainfire himself as posted in CWM 6.0.3.3/4 recovery.
[Nexus 4 General] spicediablo:
How's the performance? some users reported it isn't working properly and experienced high CPU load and battery drain.
[Nexus 4 General] VoiD_Dweller:
I read that this method causes massive battery leaks with some daemonsu or something?
[Nexus 4 General] chrone:
I got 3% drain per hour when on WiFi with auto sync, 3rd party app push notification, and location reporting enabled.

While on 3G same setup and a bit of active usage, I got around 10% drain per hour.

All was reported by better battery stats app though.

The supersu app was set with no toast notification for already permission granted app, and also without any logging.

In summary I might say it is the same as it was on 4.2.2. Hehe
[Nexus 4 General] spicediablo:
This is tempting me to flash mine!!:D. I really need root to work as I use TB to restore my apps+data
[Nexus 4 General] chrone:
I guess the battery drain caused by daemon su is with app which requests constant or frequent su access. Hehe
[Nexus 4 General] TecQuality:
i fixed this issue wiping cache and factory reset :)
[Nexus 4 General] spicediablo:
I'm using greenify which requires root but not sure how often it ask for su access....
[Nexus 4 General] Federico_96:
In the first part of the guide efrant says to don't install pdanet drivers if you're not sure that they're working, how can i know if they are working? i unlocked my bootloader and flashed manually twrp, so i guess drivers are working?
[Nexus 4 General] TecQuality:
can you see your device if you type fastboot devices? if yes everythings is alright.
[Nexus 4 General] efrant:
Root is not yet stable on the N4.
[Nexus 4 General] mils69:
While most apps behave like root is working properly.. TB in particular does not appear to be working whatsoever. Any attempt to restore an app / data is failing for me (it just never finishes).

mils
[Nexus 4 General] chiweed:
Having similar issue but when attempting a backup I get insufficient free storage space using TB.
[Nexus 4 General] el_charlie:
Well,

My command was this:

fastboot -c "lge.kcal=0|0|0|x" boot customrecovery.img

And it worked!!!!

I didn't need a kernel command line.

Cheers!
[Nexus 4 General] cobyman7035:
which steps do i follow if im on franco kernel and i want to get that new 4.3 update OTA? thanks
[Nexus 4 General] efrant:
Flash the system.img and boot.img images from the JDQ39 factory image. (But, it's kinda pointless -- since you are going to flash the 4.2.2 images, why not just flash the 4.3 images, no?)
[Nexus 4 General] spicediablo:
You need to set the backup path on order for tb to work. Refer to this

http://xdaforums.com/showthread.php?p=43929922

Sent from Mako⁴
[Nexus 4 General] chiweed:
Thanks! Got a backup to work.
[Nexus 4 General] hwti:
The help for "-c" option is "override kernel commandline", but it actually replaces the first part of the commandline only :confused:

So you removed "console=ttyHSL0,115200,n8 androidboot.hardware=mako lpj=67677", which doesn't seem important.
[Nexus 4 General] el_charlie:
Yeah... it's very weird.

That's the command I executed and worked just fine to boot CWM 6.0.2.3 (that's the one I have, haven't download the newer)

So, what does that mean???

Cheers!
[Nexus 4 General] hwti:
The console=ttyHSL0,115200,n8 parameter configures a kernel console on a serial port (probably the one in the headphone jack).

Not important, except for someone trying to debug a kernel which doesn't boot.

lpj : "Sets loops_per_jiffy to given constant, thus avoiding time-consuming boot-time autodetection (up to 250 ms per CPU).0 enables autodetection (default)"

Probably not important, unless the autodetection is broken on this hardware.

The androidboot.hardware=mako tells the android init to load /ueventd.mako.rc on boot.

It's used to set permissions/ownership on /dev nodes.

I don't know if it's important for a recovery. If the permissions are needed, some features may fail.
[Nexus 4 General] el_charlie:
And what does lge.kcal=0|0|0|x mean???

To be honest, I didn't knew how to copy all the kernel command line, so I only used lge.kcal=0|0|0|x and it worked just fine xD

Although I didn't flash any zip or anything else, just rebooted the phone.

Cheers!
[Nexus 4 General] hwti:
It's the display color calibration.

https://android.googlesource.com/ke...7ff8a36ed/arch/arm/mach-msm/lge/devices_lge.c

https://android.googlesource.com/ke...ch/arm/mach-msm/lge/mako/board-mako-display.c

"0|0|0|x" is in fact an invalid value (since last part isn't K).

With an invalid lge.kcal parameter, the r, g and b values are set to 255.

The default values, without the parameter, are 0 (kcal_value struct not initialized in board-mako-display.c).

It's strange, especially since 0 gives a black screen.

Perhaps LG didn't try to boot the kernel without any parameter...
[Nexus 4 General] undercover:
Maybe that's the whole point, to not have any settings ie have an invalid parameter which will default it to 255 all? Ie they didn't bother with calibration?
[Nexus 4 General] hwti:
The 255 when the parameter is invalid is fine.

But the default value, when there is no parameter, should be 255 too, not 0.

It's not logic to have two different defaults here.
[Nexus 4 General] undercover:
Heh, not all things they do are logical. Display is still not calibrated, which is poor show IMHO. They are aware of that issue. 4.1.2 had better colours.
[Nexus 4 General] el_charlie:
Well,

The weird part is why is this needed to boot a recovery?? I get it could affect booting the system, but the recovery??

Cheers!
[Nexus 4 General] efrant:
Added link to the first post for superuser package that is compatible with 4.3.

https://plus.google.com/+Chainfire/posts/Jkuu84odnx6
[Nexus 4 General] el_charlie:
Just a heads up with the "fastboot boot command":

Like I said before fastboot -c "lge.kcal=0|0|0|x" boot recovery-clockwork-touch-6.0.3.4-mako.img works just fine, but in the case of CWM, the up and down keys are reversed (the volume keys). The Vol+ key actually moves down and the Vol- moves up. Power key still works as select.

Besides that, I could successfully flash SuperSU 1.43 xD

Cheers!
[Nexus 4 General] spicediablo:
Just to confirm, I can follow section D irregardless of whether i have modified system apps, have custom recovery or have custom kernel right?

Also, I've seen in the forum that we need to update the adb to the latest version? As long as my device is recognised by fastboot devices, I am ok right?
[Nexus 4 General] fkloznica:
is it safe to flash via cwm recovery ?
[Nexus 4 General] CoreyVidal:
Hey everyone,

I've been a lurker of XDA and /r/android for a few years now. Never had the guts to root my Nexus 4 until today.

After manually upgrading to 4.3 and Unlocking (both of which I was comfortable with), I decided to root.

I followed the instructions on the first post: E. Optional -- Root

I got to step 5, and executed:

fastboot boot customrecovery.img

My phone flashed, went black, and has been sitting on a black screen for about 15 minutes. I don't want to touch it or unplug it from my computer. The first post says "wait for it to boot" but this seems to be an awfully long time. Can someone help me out?
[Nexus 4 General] el_charlie:
Press and hold power to turn it off.

The new bootloader changed something.

Look a page before to see the new working fastboot boot command. It involves a -c parameter in the sintax.

Or you could flash cwm to apply the supersu zip and then flash the stock recovery.
[Nexus 4 General] CoreyVidal:
Thank you very much, I just read up and worked it out.

Thanks!
[Nexus 4 General] johns678:
Weird problem with n4

Hi everyone

I have been trying to get my n4 out of bootloop for the last two days, tried every method none of them seems to be working .:rolleyes:

After flashing stock it boots up if it is connected via usb . but right after i disconnect the usb the phone just freezes. What could be the problem guys.:crying:
[Nexus 4 General] snak3ater:
Can we flash the 4.2.2 Factory image over 4.3?

Currently on 4.3 but i need to go back to check something in 4.2.2

---------- Post added at 12:36 PM ---------- Previous post was at 12:35 PM ----------

Try factory reset
[Nexus 4 General] Spiralzz:
Yes. Same process.
[Nexus 4 General] d1xt1r:
Yes. I just did it using the OP.

Thank you efrant, very much appreciate the efforts you've put to create this guide.
[Nexus 4 General] johns678:
Tried everything given here including factory reset. :crying:
[Nexus 4 General] theprodigy85:
I don't quite understand step 5 in this...can someone clarify it?

I typed in the output I got from step 3 and apended the lge.kcal line, but I get an error with the command not being recognized.

edit: NVM...didn't realize I needed the quotes.

Thanks
[Nexus 4 General] spicediablo:
Followed Efrant's guide to the teeth and managed to flash mine successfully. But now it's showing 5G free space.Factory reset fixed it. Now I have 13G space free.

Ok I'm pretty sure someone asked this before but I couldnt' find it. How do I flash the custom recovery? I have did the rooting steps and now when i boot into recovery, i get an android with an exclamation mark with a no command written below...

How do I make sure the custom recovery is permanent?
[Nexus 4 General] spicediablo:
Do your custom recovery stays? How do you flash the custom recovery?
[Nexus 4 General] nithin1992:
Download twrp custom recovery or cwm. Rename the recovery image file to customrecovery.img and place it in the adb fastboot folder. Get into fastboot mode, then run fastboot flash recovery customrecovery.img in the command prompt, opened from the adb fastboot folder
[Nexus 4 General] spicediablo:
That is what I did and i have rooted it successfully. But now I cant get into my cwm recovery, instead i get an android with a red exclamation mark(stock recovery) and when i push power+vol up, nothing happens... This is driving me crazy...:silly:
[Nexus 4 General] defffizz:
delete
[Nexus 4 General] nithin1992:
Sorry, thought you wanted this to just install root. If you want it permanently then run fastboot flash recovery customrecovery.img
[Nexus 4 General] spicediablo:
Will this command work for the new bootloader?

---------- Post added at 09:35 PM ---------- Previous post was at 09:32 PM ----------

What if I wanna flash the custom recovery under the new bootloader? What would be the command? Currently I am rooted but I can't get into my CWM upon reboot...
[Nexus 4 General] el_charlie:
fastboot flash recovery nameofcustomrecovery.img is the command you need.

The other one is to boot without flashing a custom recovery in order to flash SuperSU. This command with the new parameter is needed for the z20i bootloader that comes with Android 4.3.

Cheers!
[Nexus 4 General] spicediablo:
Thanks!! I feel dumb. I thought new commands needed for new bootloader....:silly:

Update: It works now. But there is a warning: no file_contexts below. Cause for concern?

Also there is a ROM may flash stock recovery on boot prompt. Do I fix it or not?