[Q] Can I lock back the bootloader? - Samsung Galaxy Nexus

Can I lock back the bootloader in my Galaxy Nexus to go back to stock?

locking the bootloader does not return you to stock. you need to flash the stock rom via fastboot to return it to stock.

If you want it lock up again use ''fastboot oem lock'' command.

Zepius said:
locking the bootloader does not return you to stock. you need to flash the stock rom via fastboot to return it to stock.
Click to expand...
Click to collapse
Yes, I know I need to flash the stock rom as well. Thanks
madd0g said:
If you want it lock up again use ''fastboot oem lock'' command.
Click to expand...
Click to collapse
Will this return the stock recovery?

JGeZau said:
Yes, I know I need to flash the stock rom as well. Thanks
Will this return the stock recovery?
Click to expand...
Click to collapse
no. nothing about locking the bootloader returns anything to stock.
the only thing locking the bootloader does is:
1) remove the lock symbol on the google bootup
2) no longer allows flashing of insecure images.

JGeZau said:
Will this return the stock recovery?
Click to expand...
Click to collapse
You get the stock recovery with getting the nexus image and flashing with ''fastboot flash recovery recovery.img''. So basically getting a factory device is with downloading the image, doing the flash-all and fastboot oem lock at the end.

ah ok, thank you all
Edit:
Zepius, I followed the guide in your signature. It was painless, thanks

Related

[Q] Reverting to Stock

Hello all,
So I'm attempting to revert to stock. Search has yielded some answers, but also posed some new questions for me.
I found this thread: http://forum.xda-developers.com/showthread.php?t=1704021&highlight=stock
with this info:
Yes.. you can run the RUU on top of a custom rom, no need to nandroid restore your old stock backup. Most important is the stock recovery been flashed and bootloader re-locked before you run the RUU.
And I normally also flash a stock boot.img first. (some people say no need to do this, but it is no harm doing it).
Click to expand...
Click to collapse
So now my question is, how do I revert to a stock recovery? I know locking the bootloader is:
Code:
fastboot oem lock
but I still need a little more help getting my HOX back to stock. Any help will be appreciated greatly.
bscotth said:
Hello all,
So I'm attempting to revert to stock. Search has yielded some answers, but also posed some new questions for me.
I found this thread: http://forum.xda-developers.com/showthread.php?t=1704021&highlight=stock
with this info:
So now my question is, how do I revert to a stock recovery? I know locking the bootloader is:
Code:
fastboot oem lock
but I still need a little more help getting my HOX back to stock. Any help will be appreciated greatly.
Click to expand...
Click to collapse
Hello. You have to flash stock revovery from cwm recovery thread, before you relock bootloader (command is then: fastboot flash recovery recovery.IMG (take name of stock recovery and put a .img on its end)
Good success
Sent from my HTC One X using XDA
Find the recovery relevant to your version before you flashed custom Rom (mines 1.29.401.11) download it and put it in the same folder as your fastboot files. Go into fastboot USB and type fastboot flash recovery "name of stock recovery".img
You might have to "fastboot erase cache" if you get stuck on the HTC splash screen after rebooting
EDIT: putti71 beat me to it
Sent from my HTC One X using Tapatalk 2
If you flash an RUU it replaces the recovery with stock so you don't need to do that, just lock the bootloader and flash the RUU you downloaded before unlocking the phone in the first place
EddyOS said:
If you flash an RUU it replaces the recovery with stock so you don't need to do that, just lock the bootloader and flash the RUU you downloaded before unlocking the phone in the first place
Click to expand...
Click to collapse
i thought you had to have stock recovery to flash a ruu

questions about returnig to stock - warrenty

I have to get 100% stock for warrenty.. my devices is s-off, custom recovery, bootloader unlocked and custom rom. Will i get to stock with these steps: ?
- flash the stock rom (from my nadroid backup)
- flash the stock recovery
- set the bootloader to "locked"
- go back s-on
do i need an unlocked bootloader to get s-on ("writesecureflag 3) ?
Thanks!
If you used htcdev to unlock the boot loader, this can be a problem since HTC can see it!
MICH_** said:
I have to get 100% stock for warrenty.. my devices is s-off, custom recovery, bootloader unlocked and custom rom. Will i get to stock with these steps: ?
- flash the stock rom (from my nadroid backup)
- flash the stock recovery
- set the bootloader to "locked"
- go back s-on
do i need an unlocked bootloader to get s-on ("writesecureflag 3) ?
Thanks!
Click to expand...
Click to collapse
Have you tried looking at this thread? http://forum.xda-developers.com/showthread.php?t=2735235
MrKhozam said:
Have you tried looking at this thread? http://forum.xda-developers.com/showthread.php?t=2735235
Click to expand...
Click to collapse
Yes i have Do i have to flash the whole firmware? Or is it enough to flash te stock recovery? should be okay i think..
MICH_** said:
Yes i have Do i have to flash the whole firmware? Or is it enough to flash te stock recovery? should be okay i think..
Click to expand...
Click to collapse
If you're already on stock Sense 6 before doing these steps, I would think flashing stock recovery is enough. Then you can manually boot into the OS and do a factory reset from within the settings, before sending it off for warranty repairs.
MrKhozam said:
If you're already on stock Sense 6 before doing these steps, I would think flashing stock recovery is enough. Then you can manually boot into the OS and do a factory reset from within the settings, before sending it off for warranty repairs.
Click to expand...
Click to collapse
okay, thank you! do you think i should go s-on? (i heard about may risks when going back s-on)
MICH_** said:
okay, thank you! do you think i should go s-on? (i heard about may risks when going back s-on)
Click to expand...
Click to collapse
You can try spoofing S-ON status through hboot. I have not tried this before, so proceed with caution. You can read about it here: http://forum.xda-developers.com/showthread.php?t=2708721.
MrKhozam said:
You can try spoofing S-ON status through hboot. I have not tried this before, so proceed with caution. You can read about it here: http://forum.xda-developers.com/showthread.php?t=2708721.
Click to expand...
Click to collapse
Does it work to flash files (.zip & recovery) with a locked bootloader but s-off? And is it possible to get s-on with a locked bootloader?
Okay, thanks guys! I just "stocked" my phone The only thing that´s left is s-off. Do you recommend to go back s-on?
I successfully returned my M8 back to full stock (no root, locked bootloader and S-On). I wrote about my experiences here: http://forum.xda-developers.com/showpost.php?p=55374704&postcount=7

Need help with S-On HTC One M9...

I have an international stock HTC One M9. CID is: HTC__621 and firmware version: 210.709.1 - I've already found the stock recovery for 210.709.1 - I'm looking to install a custom ROM, but I may want to go back to stock later on. I found a TWRP stock backup for 210.709.1, but because I am S-ON, will I not have to manually flash the boot.img? I used winrar to look into the TWRP backup, and I could not find a boot.img. So, my question is: if I flash the TWRP backup using TWRP, will the boot.img automatically get flashed?
You will have to flash the boot.img manually. The boot image is there it should be called boot.emmc.win .
mrbtree98 said:
You will have to flash the boot.img manually. The boot image is there it should be called boot.emmc.win .
Click to expand...
Click to collapse
Should I rename this to: "boot.img"? And then, use command: " fastboot flash boot boot.img"?
mrbtree98 said:
You will have to flash the boot.img manually. The boot image is there it should be called boot.emmc.win .
Click to expand...
Click to collapse
There's no "boot.emmc.win" within the archive? I can't find it...
arif9m9 said:
Should I rename this to: "boot.img"? And then, use command: " fastboot flash boot boot.img"?
Click to expand...
Click to collapse
Some weeks ago I was told that all newer phones than the HTC One M7 are able to flash boot images with TWRP even if they are S-ON. (I wasn't able to verify that since my phone is S-OFF.) So there should be no need to rename and manually flash the boot image if it's already inside the backup.
arif9m9 said:
There's no "boot.emmc.win" within the archive? I can't find it...
Click to expand...
Click to collapse
You can find the needed boot image in my signature.
Flippy498 said:
You can find the needed boot image in my signature.
Click to expand...
Click to collapse
Thanks. I downloaded: "boot_2.10.709.1.img" from your signature. Do I just flash it in fastboot like this: fastboot flash boot boot_2.10.709.1.img"? Is it okay if I rename it to just: boot.img?
My M9 is completely stock, right now. I'm intending to: unlock the bootloader, flash TWRP recovery, and finally, install an ASOP ROM.
When attempting to go back to stock, I'm going to: boot into TWRP, wipe everything except for SD card, flash the 2.10.709.1 TWRP stock backup, boot into fastboot and flash the command: "fastboot flash boot boot_2.10.709.1.img", flash the stock 2.10.709.1 recovery, and finally, relock the bootloader. Will all these steps be correct for an attempt to go back to stock?
arif9m9 said:
Thanks. I downloaded: "boot_2.10.709.1.img" from your signature. Do I just flash it in fastboot like this: fastboot flash boot boot_2.10.709.1.img"? Is it okay if I rename it to just: boot.img?
My M9 is completely stock, right now. I'm intending to: unlock the bootloader, flash TWRP recovery, and finally, install an ASOP ROM.
When attempting to go back to stock, I'm going to: boot into TWRP, wipe everything except for SD card, flash the 2.10.709.1 TWRP stock backup, boot into fastboot and flash the command: "fastboot flash boot boot_2.10.709.1.img", flash the stock 2.10.709.1 recovery, and finally, relock the bootloader. Will all these steps be correct for an attempt to go back to stock?
Click to expand...
Click to collapse
If you use the backup from my signature you only need to follow the instructions on the first page of my google sheet to get back to stock.
Be warned: Since Android 5.1 you should only relock the bootloader if you are completely sure that your phone is able to boot to system and that you ticked the new option that allows a bootloader unlock (can be found in the developers options). Many users already got stuck with a non-booting phone that cannot be re-unlocked because they didn't fulfill these requirements. (Sidenote: If you only want to get back to stock to install new OTAs you don't need to relock your bootloader.)
Besides I read that some people stated that the AOSP roms of the M9 messed up their LTE reception (so that LTE was even unusable on other custom roms or stock rom). I don't know whether this problem is already fixed. Some weeks passed since I read about that problem so I suggest you to read the corresponding threads before you start flashing.
arif9m9 said:
Thanks. I downloaded: "boot_2.10.709.1.img" from your signature. Do I just flash it in fastboot like this: fastboot flash boot boot_2.10.709.1.img"? Is it okay if I rename it to just: boot.img?
My M9 is completely stock, right now. I'm intending to: unlock the bootloader, flash TWRP recovery, and finally, install an ASOP ROM.
When attempting to go back to stock, I'm going to: boot into TWRP, wipe everything except for SD card, flash the 2.10.709.1 TWRP stock backup, boot into fastboot and flash the command: "fastboot flash boot boot_2.10.709.1.img", flash the stock 2.10.709.1 recovery, and finally, relock the bootloader. Will all these steps be correct for an attempt to go back to stock?
Click to expand...
Click to collapse
There is no need to flash the boot.img separately on this phone.
As noted DO NOT RELOCK unless you have ticked that "allow oem unlocking" option first. I cannot stress this enough.
Also, no AOSP rom currently has a working camera.
iElvis said:
There is no need to flash the boot.img separately on this phone.
As noted DO NOT RELOCK unless you have ticked that "allow oem unlocking" option first. I cannot stress this enough.
Also, no AOSP rom currently has a working camera.
Click to expand...
Click to collapse
My phone is S-ON, won't I have to flash the boot.img via fastboot?
arif9m9 said:
My phone is S-ON, won't I have to flash the boot.img via fastboot?
Click to expand...
Click to collapse
Flippy498 said:
Some weeks ago I was told that all newer phones than the HTC One M7 are able to flash boot images with TWRP even if they are S-ON.
Click to expand...
Click to collapse
iElvis said:
There is no need to flash the boot.img separately on this phone.
Click to expand...
Click to collapse
No, it's not needed. The only exceptions are backups that don't contain a boot image (like mine for example). That's why I created the google sheet with the instructions.
Flippy498 said:
No, it's not needed.
Click to expand...
Click to collapse
But, when installing custom ROMS, I'll definitely have to use the fastboot command to flash the boot image, right?
arif9m9 said:
But, when installing custom ROMS, I'll definitely have to use the fastboot command to flash the boot image, right?
Click to expand...
Click to collapse
No.
Flippy498 said:
No.
Click to expand...
Click to collapse
But, I'm S-ON....
arif9m9 said:
But, I'm S-ON....
Click to expand...
Click to collapse
It hasn't been an S-on restriction since the M7.
iElvis said:
It hasn't been an S-on restriction since the M7.
Click to expand...
Click to collapse
Does that mean I can flash RUUs even if I'm S-ON?
arif9m9 said:
Does that mean I can flash RUUs even if I'm S-ON?
Click to expand...
Click to collapse
For your CID/MID, yes.
iElvis said:
For your CID/MID, yes.
Click to expand...
Click to collapse
But, all the 'Returning to stock' guides
for the M9 state S-OFF is obligatory?
arif9m9 said:
But, all the 'Returning to stock' guides
for the M9 state S-OFF is obligatory?
Click to expand...
Click to collapse
It depends. If you have a current RUU for your phone (i.e., you don't need to downgrade), you can run it S-on, as that's what it's for.
But if you need to downgrade because the only RUU is an earlier version, yes you do need s-off.
S-off also allows you to go back to LOCKED instead of RELOCKED.
iElvis said:
It depends. If you have a current RUU for your phone (i.e., you don't need to downgrade), you can run it S-on, as that's what it's for.
But if you need to downgrade because the only RUU is an earlier version, yes you do need s-off.
S-off also allows you to go back to LOCKED instead of RELOCKED.
Click to expand...
Click to collapse
When going back to stock, at which stage should I relock my bootloader?
arif9m9 said:
But, all the 'Returning to stock' guides
for the M9 state S-OFF is obligatory?
Click to expand...
Click to collapse
Because if you follow these guides your phone will state "locked" instead of "relocked" at the end. And that is only possible with S-OFF. Besides with S-ON you can only use RUUs with the same firmware version as your phone (or newer RUUs)*.
*Actually downgrades seem to be possible, too, but as far as I know only if the two first numbers of the firmware versions before and after the downgrade are the same. Like from 1.32.xxx.15 to 1.32.xxx.8 but not from 1.40 versions to 1.32 versions or from 2.xx versions to lower versions.
Edit: Looks like I didn't type fast enough.

re lock the bootloader and unroot?

hello to everyone , I would like to know how to re lock the bootloader and unroot and flash to stock global rom. If anyone can help it would be much appreciated. I am currently using RR on china dev base (chiron)
thanks
I believe if you wipe and flash stock, it relocks the bootloader.
alose said:
I believe if you wipe and flash stock, it relocks the bootloader.
Click to expand...
Click to collapse
thanks will try that!
or fastboot oem lock
animaleyes76 said:
or fastboot oem lock
Click to expand...
Click to collapse
alose said:
I believe if you wipe and flash stock, it relocks the bootloader.
Click to expand...
Click to collapse
i flashed the stock rom but still unlocked bootloader
if i do the fastboot method will it work? have you tried it? do i have a chance of bricking the device?
Terole said:
i flashed the stock rom but still unlocked bootloader
if i do the fastboot method will it work? have you tried it? do i have a chance of bricking the device?
Click to expand...
Click to collapse
It was fine for me. If you are still a bit nervous use the Xiaomi flash tool to flash a fastboot stock Rom and pick the flash and relock option in the bottom right http://en.miui.com/a-234.html
Terole said:
i flashed the stock rom but still unlocked bootloader
if i do the fastboot method will it work? have you tried it? do i have a chance of bricking the device?
Click to expand...
Click to collapse
Did you ever get your bootloader relocked? I'm getting the Mi Mix 2s (China Version) on friday and wondering how to flash stock global and then relock bootloader.\

How do i go back to completely stock?

I mean how do I go completely back to stock because I unlocked my bootloader and I relock it but now I cant pass safety net and some apps don't work even with my bootloader locked and rom completely stock
Manuel Marta said:
I mean how do I go completely back to stock because I unlocked my bootloader and I relock it but now I cant pass safety net and some apps don't work even with my bootloader locked and rom completely stock
Click to expand...
Click to collapse
https://forum.xda-developers.com/z2-force/how-to/how-to-return-to-stock-sprint-t3694783
Caltinpla said:
https://forum.xda-developers.com/z2-force/how-to/how-to-return-to-stock-sprint-t3694783
Click to expand...
Click to collapse
Follow that guide and after you have to type in fastboot "fastboot oem lock" to relock the bootloader.
PD: You will see a message that you booted a modified OS and that's normal, you will boot.

Categories

Resources