Is it possible to upgrade the bootloader and radio on a RELOCKED device with TWRP? - Nexus 5X Q&A, Help & Troubleshooting

Yeah, it's locked with a TWRP on it.
Now the data partition is unencrypted. I want to upgrade the bootloader, but it says it should be first unlocked.
Will unlocking cause destruction to all my data? If so, can I upgrade the bootloader?
P.S. My data is 20GB. I don't want to make a backup at the moment, if not necessary.

First of all: Yes, unlocking your bootloader will erase your data. Make a backup before you do.
Second of all: Is there a reason you want to do this? Your phone should continue to work fine if you're not on the newest bootloader or radio. Over the course of a year, I had updated mine from 6.0.1 to 7.0 to 7.1 without ever updating the bootloader and radio. It will work fine with an older version.
Third of all: As a curiosity, you have TWRP installed to the /recovery, but will it actually boot TWRP with the locked bootloader? I didn't think it would...

It's booting. I don't know why. I'll post a video if you want. BTW, if I bricked my device with the bootloader locked, is there any chance to re-flash it to stock?

I believe so. Instead of Pwr+VolDown to get into the bootloader, you can do Pwr+VolUp to get into recovery, and I think you can sideload the stock firmware. Don't quote me on that, tho, as I could be mistaken. Never had to do it myself, as I've always been unlocked and used Fastboot.

You may run into problems if you need to flash the factory images as you'd have to unlock the bootloader first so if there were any problems and you were unable to unlock it, you would not be able to flash them. My advice would be to unlock it and leave it that way as long as your device is modified.

Related

Android pay has stopped working

I had a Nexus 5X with stock Android 6 software. Android Pay was working fine.
I was having a few lag issues and noticed the final Nexus factory image was available for Android 7 so I decided to unlock my bootloader and install the factory image. After I installed it, Android Pay was still working fine.
Then I received an OTA update for the monthly security hotfixes which I installed. Since doing this, Android Pay doesn't work. It says something about my phone being rooted/unlocked and that Android Pay does not support this.
Can anyone tell me why this is happening? I don't need to keep my bootloader unlocked so if locking will allow me to resolve the issue without losing data then I can do this. Can anyone guide me please?
Try flashing a kernel from The Flash or Franco.
Both have a line of code that should stop the bootloader error in safetynet
Thank you but I don't want to put on any custom stuff. I just want to go back to a stock Android 7.0 ROM that works with Android Pay. I don't need root, or an unlocked bootloader. How can I go back to stock?
You can use something like wugs nexus tool.
Although some have mentioned you can brick your device trying to lock the bootloader.
Personally I have never done it. Others might have more experience.
It may or may not be easier to lock than to use a custom kernel. YMMV.
One benefit of the kernel is increased performance on your phone.
Oh and if you lock your bootloader it will completely wipe your phone. E.g. You will lose your data.
Edit.. Root isn't needed for a kernel either
Start the device in fastboot mode again, as described above.
Execute:
fastboot flashing lock
or, for older devices, run:
fastboot oem lock
Locking bootloader will wipe the data on some devices. After locking the bootloader, if you want to flash the device again, you must run fastboot oem unlock again, which will wipe the data.
Source: https://developers.google.com/android/nexus/images
Ah okay, thanks for the info. What I should have done originally was re-lock the bootloader straight after I flashed the ROM. Unfortunately, I setup the device after flashing the ROM and kept the bootloader unlocked which is why I'm stuck right now. Okay, time to backup my stuff up and re-lock the bootloader. Thanks everyone.

is unlocking bootloader a must?

I purchase a 1+3 a week ago. I have everything setup has i wanne but my concern if the phone goes into bootloop or something goes wrong. Would u think im ok woth a locm bootloader or unlock bootloader is a must
Unlocking bootloader is only necessary if you want/need root and other modifications. If you're satisfied with the phone in its current state and only plan to use official ROMs, you don't need to unlock it.
Bootloops an similar issues are very rare on unmodified devices, no need to worry about this.
Besides, you can always factory reset or sideload stock ROM even with locked bootloader and stock recovery.
Sent from my OnePlus 3 using Tapatalk

Hard bricked?

So long story short, my rom (nitrogenOS, great rom BTW) got corrupt (or so I thought) and I had to wipe all data to re-install it clean.
But now I'm in a position where my phone has no rom, no recovery (neither TWRP nor stock) and both my bootloader and bootloader critical are locked (Last time I had to lock and unlock them to prevent bootloop before flashing stock OS, I don't know why)
Now I can't boot into twrp or absolutely anything, and cannot unlock the bootloader either because it says "Flashing unlock is not allowed".
Is my device 100% unrecoverable?
Going to have to go back to JBHifi (Australia) and have them send it to google
Any thing I can still do to recover the device?!
railpressureflip said:
So long story short, my rom (nitrogenOS, great rom BTW) got corrupt (or so I thought) and I had to wipe all data to re-install it clean.
But now I'm in a position where my phone has no rom, no recovery (neither TWRP nor stock) and both my bootloader and bootloader critical are locked (Last time I had to lock and unlock them to prevent bootloop before flashing stock OS, I don't know why)
Now I can't boot into twrp or absolutely anything, and cannot unlock the bootloader either because it says "Flashing unlock is not allowed".
Is my device 100% unrecoverable?
Going to have to go back to JBHifi (Australia) and have them send it to google
Any thing I can still do to recover the device?!
Click to expand...
Click to collapse
you might be able to fastboot boot path/to/recovey.img like when you were flashing twrp but im not sure if that works on locked devices try it with a factory image with the recovery extracted and if that works you can sideload the full ota in recovery.
and possibly lgs flashtool can rewrite the phone with it locked but idk if there are imgs out there or if it works with pixel 2 xl
for next time never lock your phone on a custom rom really never relock once unlocked there is no need to and it only takes away your recovery options
railpressureflip said:
So long story short, my rom (nitrogenOS, great rom BTW) got corrupt (or so I thought) and I had to wipe all data to re-install it clean.
But now I'm in a position where my phone has no rom, no recovery (neither TWRP nor stock) and both my bootloader and bootloader critical are locked (Last time I had to lock and unlock them to prevent bootloop before flashing stock OS, I don't know why)
Now I can't boot into twrp or absolutely anything, and cannot unlock the bootloader either because it says "Flashing unlock is not allowed".
Is my device 100% unrecoverable?
Going to have to go back to JBHifi (Australia) and have them send it to google
Any thing I can still do to recover the device?!
Click to expand...
Click to collapse
How the heck did your bootloader get locked if you didn't do it yourself?? Do you get your phone ID displayed when you type in "fastboot devices" in bootloader mode???
You probably ended up switching slots when you reflashed. You need to use Deuces flashing script. Say yes to unlocking.
Try downloading and installing skipsoft tools. It might not see your device but try. If it doesn't see it, manually select your device. Have it install USB drivers. Restart skipsoft and see if it sees your device then. I got into a situation once where in fastboot it showed something like a corrupt bootloader and my computer could not see my device. After messing with the phone with skipsoft running, skipsoft could see it when my computer couldn't.

How to Lock Bootloader

Hello, I purchased a Pixel 3 XL off craigslist and it is working fine, but the bootloader is unlocked therefore I am receiving a warning when restarting the phone and Google Pay does not work. How can I re-lock the bootloader? Do I need to flash the latest standard google image? The build number is: "crosshatch-userdebug 9 PQ1A.181105.013 5027108 dev-keys". When in bootloader the bootloader version is: b1c1-0.1-5004167. Obviously a n00b here, please be gentle. Thank you for any help.
Do you have a computer? If so what OS do you use?
Sent from my Pixel 3 XL using Tapatalk
superchilpil said:
Do you have a computer? If so what OS do you use?
Sent from my Pixel 3 XL using Tapatalk
Click to expand...
Click to collapse
I do have a computer, a Windows 10 Pro
Are you planning on rooting? If so, you can use Magisk Hide (after using Magisk to root of course) to get Google Pay to work. I would be hesitant to re-lock the BL unless you are certain that it is completely stock otherwise. Re-locking a modified phone can brick the device. Better to just learn how to root, etc and keep it unlocked. You have come to the right place to learn.
sliding_billy said:
Are you planning on rooting? If so, you can use Magisk Hide (after using Magisk to root of course) to get Google Pay to work. I would be hesitant to re-lock the BL unless you are certain that it is completely stock otherwise. Re-locking a modified phone can brick the device. Better to just learn how to root, etc and keep it unlocked. You have come to the right place to learn.
Click to expand...
Click to collapse
No, I don't plan on rooting. But I am afraid of bricking the phone since I don't know what has been done to it. Is there a way to determine what was done to unlock the bootloader? Otherwise I will follow your recommendation of using Magisk Hide. I would prefer to keep the phone stock. Thanks.
eec007 said:
No, I don't plan on rooting. But I am afraid of bricking the phone since I don't know what has been done to it. Is there a way to determine what was done to unlock the bootloader? Otherwise I will follow your recommendation of using Magisk Hide. I would prefer to keep the phone stock. Thanks.
Click to expand...
Click to collapse
If you live in Denver I'll trade you my Verizon one for yours. It has a locked bootloader.
eec007 said:
No, I don't plan on rooting. But I am afraid of bricking the phone since I don't know what has been done to it. Is there a way to determine what was done to unlock the bootloader? Otherwise I will follow your recommendation of using Magisk Hide. I would prefer to keep the phone stock. Thanks.
Click to expand...
Click to collapse
The two obvious things you can check are that you have stock recovery and that the phone is not rooted. Manually power on to bootloader (hold volume down and press power then use the volume keys to select recovery and press power. you should get a no command android screen if in stock recovery. assuming you don't have a Magisk icon, you are probably not rooted but you can confirm by installing and running a root app like root checker. likely, the previous owner did nothing but unlock the BL given how recently it came out, but if someone where really creative they could have done work in the other partition. there are no exploites, so doing it normally (running fastboot flashing unlock from a prompt) is pretty much all that would have been done other than enabling developer options and OEM unlocking in settings.
Personally, I think you have a good chance to learn your device, root (you need to be rooted for Magisk hide) and keep the bootloader unlocked. Besides rooting, being able to install a full factory image instead of an OTA is so much better in my opinion. The amount of work it would take to be 100% confident that the only thing done was the BL unlock would take as much work as at least getting a working knowledge of rooting and reinstalling the OS.
P.S. Keeping a phone "stock and rooted" has advantages. That is how I run my 3 XL and how I ran my OG XL. No custom OS. Not even a kernel.
coolhandz said:
If you live in Denver I'll trade you my Verizon one for yours. It has a locked bootloader.
Click to expand...
Click to collapse
lol, what I don't get is that I thought the google edition could have the bootloader unlocked in the developer options. So why go to this hassle of unlocking the bootloader from fastboot? FYI, in the Developer options the OEM unlocking is greyed out and says "Bootloader is already unlocked".
sliding_billy said:
The two obvious things you can check are that you have stock recovery and that the phone is not rooted. Manually power on to bootloader (hold volume down and press power then use the volume keys to select recovery and press power. you should get a no command android screen if in stock recovery. assuming you don't have a Magisk icon, you are probably not rooted but you can confirm by installing and running a root app like root checker. likely, the previous owner did nothing but unlock the BL given how recently it came out, but if someone where really creative they could have done work in the other partition. there are no exploites, so doing it normally (running fastboot flashing unlock from a prompt) is pretty much all that would have been done other than enabling developer options and OEM unlocking in settings.
Personally, I think you have a good chance to learn your device, root (you need to be rooted for Magisk hide) and keep the bootloader unlocked. Besides rooting, being able to install a full factory image instead of an OTA is so much better in my opinion. The amount of work it would take to be 100% confident that the only thing done was the BL unlock would take as much work as at least getting a working knowledge of rooting and reinstalling the OS.
P.S. Keeping a phone "stock and rooted" has advantages. That is how I run my 3 XL and how I ran my OG XL. No custom OS. Not even a kernel.
Click to expand...
Click to collapse
Thank you! Root Checker says that "root access is not properly installed on this device". The recovery mode screen just has a warning about the bootloader is unlocked and a link to a google help page. I figure that I can always unlock the bootloader again if I need to later, but for now I just want everything to work (bank and pay app) and not worry about updating anything myself. I think I may try fastboot to lock the bootloader for now. Thanks for all the help.
Hope it all works out for you. I assume you did a factory reset on the device since you got it used. Re-locking will do another factory reset.
sliding_billy said:
Hope it all works out for you. I assume you did a factory reset on the device since you got it used. Re-locking will do another factory reset.
Click to expand...
Click to collapse
Yeah, so I locked using "fastboot flashing lock" but then it doesn't start, saying that there is no operating system or something like that. I freaked out and was able to unlock again using "fastboot flashing unlock". Now all is wiped. I guess I need to flash the oem rom first, then lock. I'll have to do this all later tonight. Just glad that I didn't brick it yet.
eec007 said:
Thank you! Root Checker says that "root access is not properly installed on this device". The recovery mode screen just has a warning about the bootloader is unlocked and a link to a google help page. I figure that I can always unlock the bootloader again if I need to later, but for now I just want everything to work (bank and pay app) and not worry about updating anything myself. I think I may try fastboot to lock the bootloader for now. Thanks for all the help.
Click to expand...
Click to collapse
I haven't rooted or bl unlocked in some time now so if I make a mistake someone please correct me. After buying it from a 3rd party I'd wipe the device entirely. Download the correct image and install the latest platform tools for Windows (here) https://developer.android.com/studio/releases/platform-tools and make sure you can connect with adb devices and fastboot devices commands. Then extract the latest full image from here https://developers.google.com/android/images to your platform-tools directory and run the flashall.bat command if you wish to wipe the entire device and get rid of anything the previous owner might have "inadvertently" installed. (this is what I would do but not necessarily what you should do if you want to keep the current apps and system intact) This will reset your device and then you can lock the bootloader with no worry and you'll have a stock system.
I agree that since you can unlock it at any time and you don't need it now then relock it. But there are those here that disagree with me and fight with Magisk and OTAs constantly. But they are not noobs and know what they're doing. If you want to learn there is a wealth of information here so it's your call. Just my 2 cents. But please check my steps before you do anything that might cause issues.
edit: darn, sorry I just saw above that you already tried to lock it. I hope what I said to do will get you out of the predicament.
bobby janow said:
I haven't rooted or bl unlocked in some time now so if I make a mistake someone please correct me. After buying it from a 3rd party I'd wipe the device entirely. Download the correct image and install the latest platform tools for Windows (here) https://developer.android.com/studio/releases/platform-tools and make sure you can connect with adb devices and fastboot devices commands. Then extract the latest full image from here https://developers.google.com/android/images to your platform-tools directory and run the flashall.bat command if you wish to wipe the entire device and get rid of anything the previous owner might have "inadvertently" installed. (this is what I would do but not necessarily what you should do if you want to keep the current apps and system intact) This will reset your device and then you can lock the bootloader with no worry and you'll have a stock system.
I agree that since you can unlock it at any time and you don't need it now then relock it. But there are those here that disagree with me and fight with Magisk and OTAs constantly. But they are not noobs and know what they're doing. If you want to learn there is a wealth of information here so it's your call. Just my 2 cents. But please check my steps before you do anything that might cause issues.
edit: darn, sorry I just saw above that you already tried to lock it. I hope what I said to do will get you out of the predicament.
Click to expand...
Click to collapse
Your steps are basically what I will try tonight. Currently the phone is working again, so there was no harm done yet (just the restore of all apps and such). But I'm going to flash the oem image tonight and start all over again.
eec007 said:
Your steps are basically what I will try tonight. Currently the phone is working again, so there was no harm done yet (just the restore of all apps and such). But I'm going to flash the oem image tonight and start all over again.
Click to expand...
Click to collapse
One thing I would do before I relocked the bl would be to do the full login procedure, email everything other than apps. Then make sure you're on the Nov update in about phone, I'm sure you will be, and then fastboot relock the bl with the proper command. It will wipe the device again but it's a small price to pay for about 10 minutes of work. Then once it reboots and there is no more error message you'll be fully stock. Enable dev options again and make sure the oem switch is active allowing bl unlock. Then you're done. I've gotten to the point on my 5X where I even flip the oem switch so it can't be bl unlocked until I go in and flip it back. Dangerous if you're flashing stuff but not so much if you're just taking OTAs. That's of course your call entirely. Good luck.
eec007 said:
lol, what I don't get is that I thought the google edition could have the bootloader unlocked in the developer options. So why go to this hassle of unlocking the bootloader from fastboot? FYI, in the Developer options the OEM unlocking is greyed out and says "Bootloader is already unlocked".
Click to expand...
Click to collapse
That will stay grayed out until you relock the bootloader. That slider "allows" unlocking. Then you boot into fastboot and unlock it.
So you would reverse the process, hit fastboot and relock the bootloader. Then you can toggle the slider back to not allow unlocking.
Relocking the bootloader will wipe your phone.
You should not do this until you first flash the full factory image to make sure the phone is 100 percent stock. And if it were my phone I would wait for the next OTA update after flashing it back to stock to make sure it goes ok. Then lock it.
And then I would wait awhile before hitting the slider.
You are playing with fire here, if you mess it up and lock it and hit the slider you will not be able to fix it. And no offense, but since you have not done this all before on this phone chances are good you will mess it up.
So, flash to stock and leave it unlocked.
Then wait for the next OTA.
Then lock it.
Then wait a bit more before you hit the slider.
And remember, since you are not the original buyer you will not be able to warranty it.
eec007 said:
Hello, I purchased a Pixel 3 XL off craigslist and it is working fine, but the bootloader is unlocked therefore I am receiving a warning when restarting the phone and Google Pay does not work. How can I re-lock the bootloader? Do I need to flash the latest standard google image? The build number is: "crosshatch-userdebug 9 PQ1A.181105.013 5027108 dev-keys". When in bootloader the bootloader version is: b1c1-0.1-5004167. Obviously a n00b here, please be gentle. Thank you for any help.
Click to expand...
Click to collapse
They're right to mention that relocking a modified device can result in a brick.
Your best bet is to go to https://developers.google.com/android/images#taimen
Follow the directions to the "T", then relock it if you are really really sure that the unlock screen bothers you.
Would suggest to do this anyway, no matter future unlock status.
TonikJDK said:
That will stay grayed out until you relock the bootloader. That slider "allows" unlocking. Then you boot into fastboot and unlock it.
So you would reverse the process, hit fastboot and relock the bootloader. Then you can toggle the slider back to not allow unlocking.
Relocking the bootloader will wipe your phone.
You should not do this until you first flash the full factory image to make sure the phone is 100 percent stock. And if it were my phone I would wait for the next OTA update after flashing it back to stock to make sure it goes ok. Then lock it.
And then I would wait awhile before hitting the slider.
You are playing with fire here, if you mess it up and lock it and hit the slider you will not be able to fix it. And no offense, but since you have not done this all before on this phone chances are good you will mess it up.
So, flash to stock and leave it unlocked.
Then wait for the next OTA.
Then lock it.
Then wait a bit more before you hit the slider.
And remember, since you are not the original buyer you will not be able to warranty it.
Click to expand...
Click to collapse
I agree with most of your post other than waiting for the next OTA before you lock the bootloader. Why would he need to do that? If he's stock, and he'll see that immediately, then relock it. He doesn't want root or Magisk but only wants banking and Pay. With the slider allowing bl unlock he's in no danger whatsoever. Lock and relock whenever he wants. OTA will not disallow the slider once it's set.
TonikJDK said:
That will stay grayed out until you relock the bootloader. That slider "allows" unlocking. Then you boot into fastboot and unlock it.
So you would reverse the process, hit fastboot and relock the bootloader. Then you can toggle the slider back to not allow unlocking.
Relocking the bootloader will wipe your phone.
You should not do this until you first flash the full factory image to make sure the phone is 100 percent stock. And if it were my phone I would wait for the next OTA update after flashing it back to stock to make sure it goes ok. Then lock it.
And then I would wait awhile before hitting the slider.
You are playing with fire here, if you mess it up and lock it and hit the slider you will not be able to fix it. And no offense, but since you have not done this all before on this phone chances are good you will mess it up.
So, flash to stock and leave it unlocked.
Then wait for the next OTA.
Then lock it.
Then wait a bit more before you hit the slider.
And remember, since you are not the original buyer you will not be able to warranty it.
Click to expand...
Click to collapse
Thank you for explaining this. I had thought that the Developer Option slider was to unlock the bootloader, but your explanation clarifies it, the slider is to allow the bootloader to be unlocked...
Ok, so I tried to flash the factory image using adb flash-all and it keeps getting the error:
Sending sparse 'vendor_a' 2/2 (193888 KB) FAILED (Error reading sparse file)
Now the phone is not working at all and says that "device is corrupt" and will not boot past the white google screen. I can try again using adb, but it is the same error each time. I tried to download the image again and same sparse error. I can also fastboot in TWRP, but not sure what to do in there. What am I doing wrong? I guess I should've rooted and used Magisk like others have said.
turns out changing to a different cable resolved my sparse error and I was then successfully able to apply the factory image and lock the device. Thanks everyone for the help.

Questions about carrier unlock and re-lock the bootloader

Deear All,
I just bought my z2 force (t-mobile) from internet. It is an unlocked version and i can use it with my own sim card. However, i found that it cannot update via OTA as the bootloader is unlocked. I have heard that after i re-flash the firmware, the bootloader will be relocked. I am wondering, will the flashing re-activate the carrier lock?
Also, is it correct that after I flash via Lenovo Moto Smart Assistant. the bootloader will be locked again?
Is there other method to allow the phone to get OTA again?
Thanks a lot for your help.
hkguy80 said:
Deear All,
I just bought my z2 force (t-mobile) from internet. It is an unlocked version and i can use it with my own sim card. However, i found that it cannot update via OTA as the bootloader is unlocked. I have heard that after i re-flash the firmware, the bootloader will be relocked. I am wondering, will the flashing re-activate the carrier lock?
Also, is it correct that after I flash via Lenovo Moto Smart Assistant. the bootloader will be locked again?
Is there other method to allow the phone to get OTA again?
Thanks a lot for your help.
Click to expand...
Click to collapse
Unlocked bootloder won't stop an ota, but a custom logo.bin will. Chances are that the seller has also flashed a logo. When you boot you should see a warning about your bootloader being unlocked, if you don't and you just see a moto logo (or any stationary image really) then you have a custom logo which will fail otas. The easiest way to remedy this is to follow Uzephi's "How to Return to Stock' thread. Then you should get otas again. It is advised never to relock your bootloader. A good example of why would be that you have a custom logo, you relock, your phone fails to boot and you can't flash anything because you locked it. There is no real valid reason to relock your phone. As for losing carrier unlock, you shouldn't, those are usually permanent. Unless it was some hack which I doubt since I believe that is only for Spring variants. Just follow Uzephi's guide and you should be back to good.
41rw4lk said:
Unlocked bootloder won't stop an ota, but a custom logo.bin will. Chances are that the seller has also flashed a logo. When you boot you should see a warning about your bootloader being unlocked, if you don't and you just see a moto logo (or any stationary image really) then you have a custom logo which will fail otas. The easiest way to remedy this is to follow Uzephi's "How to Return to Stock' thread. Then you should get otas again. It is advised never to relock your bootloader. A good example of why would be that you have a custom logo, you relock, your phone fails to boot and you can't flash anything because you locked it. There is no real valid reason to relock your phone. As for losing carrier unlock, you shouldn't, those are usually permanent. Unless it was some hack which I doubt since I believe that is only for Spring variants. Just follow Uzephi's guide and you should be back to good.
Click to expand...
Click to collapse
Thanks a lot for your help. I will follow Uzephi's to reflash my phone. :good::good::good:

Categories

Resources