[Q] Prevent CWM start from Bootloader? - Nexus S Q&A, Help & Troubleshooting

With CM7 installed I am able to start CWM from bootloader by selecting "RECOVERY". Clockworkmod recovery itself has full adb support, so everyone who has stolen / found my Nexus S can gain full root access via USB simply by rebooting into CWM.
Is there a way to prevent this? Or a CWM version without adb support?
I'm worried about my google/dropbox/mail account - is adb root access for everyone with a simple USB cable a security issue?

I don't it's a good idea, but if the recovery partition contains only recovery, then you can format the recovery partition to prevent from booting it. Then keep your bootloader locked, so the only way to get access to the phone is to unlock the bootloader, which will wipe the phone clean.
Don't try it unless you are 100% sure though, I've read another guy whose brother formatted every partition in the phone, and the phone became bricked with no fastboot mode as well. I don't know which partition contains fastboot mode.

Related

[Q] HELP NS bricked

Hello Friends
My friend has had his Nexus S for a few months now and just this week it decided to brick itself.
Strange part was that he was not rooted or had bootloader unlocked, which is a pain because he cannot access download mode without it (bootloader) unlocked.
The only prior symptoms were that earlier in the week he had to factory reset a few times due to non-responsiveness and freezing.
Now I know the correct steps would be abd->unlock bootloader->Download mode->Odin but I am stuck at the first step.
Without being able to boot, I am unable to check USB debugging.
So I ask you, brilliant XDA community, how can I get into adb given this scenario?
I thank you in advance for your help
Oh and by the way I have done factory resets, wiped cache etc.
and I can access (locked) bootloader, the volume up and power menu, and recovery.
C
If you can get into bootloader and recovery, you're not bricked.
ADB is used when Android is booted up.
Fastboot is used in bootloader.
Get Fastboot working (proper drivers etc)
Go into bootloader on your phone.
run 'fastboot devices' if your phone and serial number shows up, fastboot is working.
run 'Fastboot oem unlock'
then flash clockworkmod recovery 'fastboot flash recovery filenameofrecovery.img'
boot into recovery.
mount the internal sd. search for a stock nandroid backup in the forums, copy it over to the internal sd.
umount, go back to main menu of cwm recovery and restore that nandroid backup.
reboot. if it boots up and stuff, shut down phone, go back to bootloader and 'fastboot oem lock' to relock bootloader and you should be at stock.
Thanks so much for your help!
I'll try it out tonight!
okay so I am able to get to the point where it asks if I want to unlock the bootloader and I choose yes on the phone, but it just hangs.
Any ideas?
I offer my apologies good XDA-ers, shameless self bump!1

[Q] Water Damage - Please Help Recover Data!

I had a unfortunate incident where my waterproof jacket failed. My phone was inside the waterproof pocket and ended up being soaked.
The phone turned it self off and when I had turned it on the screen turned yellow.
Immediately pulled out the battery and let it sit in rice for 3 days.
Now when I turn it on it gets stuck at the google logo screen and never shuts off. I have to pull the batter to turn it off.
I can go into fastboot mode and my options are:
reboot bootloader
reboot
recovery
power off
If I choose recovery it simply goes back to the google logo again and sits.
Some additional info about the phone:
product name - hearing
hw versoin - rev 11
bootloader version - 19020xxka3
lock state - locked
I can access the unlock bootloader screen however it says if I unlock it it will erase all of my data which I do not want to do.
My main goal is recovering the data on the phone. I have a few files that I absolutely need to recover.
If my phone never works again, that is fine so long as I can access the data off of this phone.
Any help troubleshooting would be greatly appreciated.
sj_martin said:
I had a unfortunate incident where my waterproof jacket failed. My phone was inside the waterproof pocket and ended up being soaked.
The phone turned it self off and when I had turned it on the screen turned yellow.
Immediately pulled out the battery and let it sit in rice for 3 days.
Now when I turn it on it gets stuck at the google logo screen and never shuts off. I have to pull the batter to turn it off.
I can go into fastboot mode and my options are:
reboot bootloader
reboot
recovery
power off
If I choose recovery it simply goes back to the google logo again and sits.
Some additional info about the phone:
product name - hearing
hw versoin - rev 11
bootloader version - 19020xxka3
lock state - locked
I can access the unlock bootloader screen however it says if I unlock it it will erase all of my data which I do not want to do.
My main goal is recovering the data on the phone. I have a few files that I absolutely need to recover.
If my phone never works again, that is fine so long as I can access the data off of this phone.
Any help troubleshooting would be greatly appreciated.
Click to expand...
Click to collapse
HMMMMMMMMMMM. If you were rooted already I might have been able to sugest something more from here. Maybe someone else can elaborate based on my suggestion as far as how to get it done not
In fastboot: when you connect to the PC does it give you an option to connect USB Storage? Or, better: Go into recovery. Then, from there hit power and volume up at the same time. See what options are there. (I don't remember if there is one to mount US storage Try this before that and after your fully in recovery: connect and see if the usb storage will mount to your computer.
Wait, instead of erasing that: you said you couldn't get into recovery. But if you happen to: try that.
Otherwise first see if it mounts usb storage when in fastboot. I'm not sure if it would. I know if fastboot you can run fastboot program on your computer and pull the imgs if you needed system files and what not; but, you wouldn't be able to get them if you can't read the usb storage from your computer in the first place.
Edit again: Sorry, just tried mounting in fastboot. Doesn't work. Hmmmmmmm.
---------- Post added at 10:40 PM ---------- Previous post was at 10:27 PM ----------
BlackHawkA4 said:
HMMMMMMMMMMM. If you were rooted already I might have been able to sugest something more from here. Maybe someone else can elaborate based on my suggestion as far as how to get it done not
In fastboot: when you connect to the PC does it give you an option to connect USB Storage? Or, better: Go into recovery. Then, from there hit power and volume up at the same time. See what options are there. (I don't remember if there is one to mount US storage Try this before that and after your fully in recovery: connect and see if the usb storage will mount to your computer.
Wait, instead of erasing that: you said you couldn't get into recovery. But if you happen to: try that.
Otherwise first see if it mounts usb storage when in fastboot. I'm not sure if it would. I know if fastboot you can run fastboot program on your computer and pull the imgs if you needed system files and what not; but, you wouldn't be able to get them if you can't read the usb storage from your computer in the first place.
Edit again: Sorry, just tried mounting in fastboot. Doesn't work. Hmmmmmmm.
Click to expand...
Click to collapse
Ok, again. I don't know if this would work: I can't test this out. If anyone else knows or could confirm.
IF, you can use ADB while in fastboot (Anyone know if you can or can't? Never tried it; can't test it right now) check this post out about how to mount the storage using ADB: http://groups.google.com/group/android-developers/browse_thread/thread/485d7b04bc61d7be
I'm not sure if you can use ADB in fastboot though as you usually do it while the OS is on and debugging mode is enabled. Not sure how it would work from fastboot.
I feel like I have a chance at salvaging the data. Here are some additional notes after poking around a little bit.
This phone is completely stock, never unlocked, never rooted. Never even had a chance to turn on debugging mode before it was water logged.
With that said, here is what I have done and am able to do so far.
I've installed the Android SDK + ADB drivers. I am using both XP and Win 7 to test. I can see the phone in the device manager in windows and adb is working correctly in command prompt.
However when I do "adb devices" it does not show the phone as a device. I think it might be because it needs to be in debugging mode however I cannot turn on the phone to get to that stage.
With that said, it looks like once someone can help me get ADB to recognize my device there are commands where I can extract the data out of the phone via adb.
So, can anyone help troubleshoot getting windows to recognize my phone in command prompt? Again, I can see the phone in the device manager and have installed the correct drivers.
Thanks
sj_martin said:
I feel like I have a chance at salvaging the data. Here are some additional notes after poking around a little bit.
This phone is completely stock, never unlocked, never rooted. Never even had a chance to turn on debugging mode before it was water logged.
With that said, here is what I have done and am able to do so far.
I've installed the Android SDK + ADB drivers. I am using both XP and Win 7 to test. I can see the phone in the device manager in windows and adb is working correctly in command prompt.
However when I do "adb devices" it does not show the phone as a device. I think it might be because it needs to be in debugging mode however I cannot turn on the phone to get to that stage.
With that said, it looks like once someone can help me get ADB to recognize my device there are commands where I can extract the data out of the phone via adb.
So, can anyone help troubleshoot getting windows to recognize my phone in command prompt? Again, I can see the phone in the device manager and have installed the correct drivers.
Thanks
Click to expand...
Click to collapse
heres what you can do, unlock boot loader, install clockwork mod make a backup of the current rom installed, and try to work with that somehow heres the link for unlocking the bootloader and installing the recovery!
btw if you get clockwork installed you'll be able to access the sd card storage!
http://forum.xda-developers.com/showthread.php?t=895545
I'm not exactly sure that you can install a recovery without unlocking the bootloader but I'm sure one of the devs can use their tools to pull the /system & /data off of your device. if that's not what you need I'm pretty sure your sd card isn't wiped when you unlock the bootloader, I'm assuming only the phone is reset. Just read all the similar posts here about recovering data using recovery or ADB
anishs said:
heres what you can do, unlock boot loader, install clockwork mod make a backup of the current rom installed, and try to work with that somehow heres the link for unlocking the bootloader and installing the recovery!
btw if you get clockwork installed you'll be able to access the sd card storage!
http://forum.xda-developers.com/showthread.php?t=895545
I'm not exactly sure that you can install a recovery without unlocking the bootloader but I'm sure one of the devs can use their tools to pull the /system & /data off of your device. if that's not what you need I'm pretty sure your sd card isn't wiped when you unlock the bootloader, I'm assuming only the phone is reset. Just read all the similar posts here about recovering data using recovery or ADB
Click to expand...
Click to collapse
The issue here is that if I unlock the bootloader it will wipe EVERYTHING. There seems to be a way to side load clockwork via ADB if I could actually connect via ADB if I had debugging mode on which I cannot turn on.
Everything I read says unlocking bootloader will wipe all data. I haven't seen anything that states the data is maintained, have you?
Thanks.
download the SDK, or just the necessary files to use adb and fastboot.
then download a CWR recovery.img
the do a fastboot boot recovery CWR_filename.img. that will boot the CWR image without flashing it, from there you can try a backup. then mount the SD card from CWR, and then copy the backup to your pc.
if it won't backup your files, or won't mount your sd card partition, then most likely your data is corrupted.
sj_martin said:
The issue here is that if I unlock the bootloader it will wipe EVERYTHING. There seems to be a way to side load clockwork via ADB if I could actually connect via ADB if I had debugging mode on which I cannot turn on.
Everything I read says unlocking bootloader will wipe all data. I haven't seen anything that states the data is maintained, have you?
Thanks.
Click to expand...
Click to collapse
as i said just try to load the recovery following that guide, try it without unlocking the bootloader if it doesn't work you have to unlock the bootloader, and maybe your sd won't be wiped but you phone data will
Luxferro said:
download the SDK, or just the necessary files to use adb and fastboot.
then download a CWR recovery.img
the do a fastboot boot recovery CWR_filename.img. that will boot the CWR image without flashing it, from there you can try a backup. then mount the SD card from CWR, and then copy the backup to your pc.
if it won't backup your files, or won't mount your sd card partition, then most likely your data is corrupted.
Click to expand...
Click to collapse
I understand how to use cwr however i need to get that loaded onto the phone first, and for me to load it to the phone i need adb i need the computer to be able to recognize it first which it wont. it shows it in the device manger, and all the drivers are installed correctly however in command prompt when i type "adb devices" it does not list it.
Luxferro said:
download the SDK, or just the necessary files to use adb and fastboot.
then download a CWR recovery.img
the do a fastboot boot recovery CWR_filename.img. that will boot the CWR image without flashing it, from there you can try a backup. then mount the SD card from CWR, and then copy the backup to your pc.
if it won't backup your files, or won't mount your sd card partition, then most likely your data is corrupted.
Click to expand...
Click to collapse
When your phone is plugged into your PC and in fastboot mode, does the command
fastboot devices
show any results? If so, follow Luxferro's advice.
If you've got no warranty, you could take your phone apart to see the motherboard, and spray it with isopropyl alcohol which will properly dry it.
Sent from the future to put right what once went wrong.
For those telling him to try fastboot boot it doesn't work without an unlocked bootloader.
Sent from my Nexus S MV from the XDA Premium app.
If the bootloader is locked it might prevent u from flashing recovery (I dunno mine always been unlocked). But I'm not telling him to flash a new recovery. U can just boot a recovery without flashing it (again not sure if locked bootloader prevents this... but its not writing to the phone just booting a external recovery.img).
Fastboot boot recovery filename.img
Worth a try
Sent from my Nexus S using xda premium
my understanding is that i need the have the device visible in command prompt via adb to do any of this which is the issue i'm trying to solve. once i can get my computer to see the phone via adb i think i'm home free to extract all the data i need.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Also it looks like I have 2 threads in the same section now, it looks like mods moved my posts so sorry for double replying.
bedalus said:
When your phone is plugged into your PC and in fastboot mode, does the command
fastboot devices
show any results? If so, follow Luxferro's advice.
Click to expand...
Click to collapse
Yes, it sees it now. It looks like I kept trying "adb devices" as shown on the screen shot. So now when I do fastboot devices I see my device and try to boot clockwork 5.0.2.0 but run into a boot fail:
It says i need to unlock the bootloader which I cannot do if i want to preserve data =/
10 character delete
Ive seen some uncertainty here, so I'll offer my advice (the limited I feel qualified to give).
Unlocking the boot loader will erase everything. Considering your goal is data retrieval, I would definitely NOT ever do that.
Unfortunately, having a locked bootloader severely limits your options.
My opinion on the matter is your best bet is ADB, but if the data is not time sensitive, I would let this topic get a bit more exposure. (perhaps mirror post on some other forums like xda too)
Hopefully someone more knowledgeable can post and help you out.
sj_martin said:
Yes, it sees it now. It looks like I kept trying "adb devices" as shown on the screen shot. So now when I do fastboot devices I see my device and try to boot clockwork 5.0.2.0 but run into a boot fail:
It says i need to unlock the bootloader which I cannot do if i want to preserve data =/
Click to expand...
Click to collapse
I just tried cw 3.0.0.5 per this thread:
http://forum.xda-developers.com/showthread.php?t=931865
and still get the same failure stating i need to do fastboot oem unlock
Is your bootloader even unlocked?
mathkid95 said:
Is your bootloader even unlocked?
Click to expand...
Click to collapse
No it is not. That's the point of this thread. It was a completely stock phone trying to recover data.
There is a method to root + recovery with locked bootloaders
"WITHOUT oem unlock & wipe" http://forum.xda-developers.com/showthread.php?t=931865
The advantage here is that those who chose not to root when they first got the phone won't lose any app data or sdcard data like the methods that have you unlock the bootloader do. The disadvantage is your bootloader remains locked, which may prevent you flashing certain things in the future.
edit: see ravidavi's posts below; he's shown you can even flash custom roms that are clockwork compatible while having a locked bootloader with this method.
Click to expand...
Click to collapse
kenvan19 said:
For those telling him to try fastboot boot it doesn't work without an unlocked bootloader.
Sent from my Nexus S MV from the XDA Premium app.
Click to expand...
Click to collapse
Just want to restate this. If his bootloader is locked he is pretty much SOL. He needs data off if it but to get the data he has to wipe the phone.
To the poster above me, that method no linger works. You cannot root without unlocking the bootloader. You cannot flash or boot a custom recovery without unlocking the bootloader. The links in that thread are dead.
One more time just to be sure Ira clear: you CANNOT get into a custom recovery without unlocking the bootloader.
Sent from my Nexus S MV from the XDA Premium app.
I've been looking everywhere on how to get ADB to work without debugging on; however, the only shred of hope I saw was the ability to get into your stock recovery. I didn't read on as you said you can't so it wouldn't help you anyways.
BUT!, if somehow do get into it (Or want to try to get into it over and over again and hope it works) you might be able to use ADB there. Then, that link I posted in the beginning should work to mount the storage.
Edit: Just looking at the pictures and you said you don't see the device in ADB. Have you tried actually going into ADB Shell and seeing if it connects to the phone? Mine device didn't "Show" in the list when I was using ADB but it worked.

[Q] Error mounting /sdcard

I cannot mount /sdcard.
Phone history: AT&T One X
Rooted--forget which method
Followed "everything you need to know" how to pdf by PerterHTC to upgrade to 1.85 from 1.73 then change cid and unlock bootloader. Loaded CWMR. then loaded cleanrom 2.0.
security policy for work wanted encryption enabled so after a few tries I also got that to work. everything fine for a couple of weeks. then after a restart the phone could not access /sdcard (yes I put in the proper decrypt code after each bootup)
Tried a factory wipe to remove the encryption and start over. during the wipe it could not mount the sdcard so it failed.
current state:
locks after boot amimation
I can get into fastboot and cwmr
cannot mount /sdcard which means I cannot format, partitioin or anything.
adb cannot connect to device.
most of the solution I have seen either need adb or remove sdcard and put in computer---can't do that here
I have tried various adb and fastboot commands none work because it cannot find phone. same with RUU.
I have tried wiping from cwm and fasboot
In the device manager I can see the phone on the device list in device manager on PC.
I have hope it is not bricked because I can get into cwm and fastboot but I have hit the edge of my knowledge.
Any help would be great...Thanks.
I was able to get it to respond to fastboot and re-lock the boot loader. Then I was able to run the 1.85 installer from my pc.
Woot, all good now.
Sent from my HTC One X using XDA

By what steps can I recover text and image files from Sony Xperia in bootloop?

I am working with a Sony Xperia L, with Android 4.1 or 4.2. A different model but I believe you will know the issues involved. The phone was stuck in bootloop. I have now put it into fastboot mode. I am trying to recover text and image data (jpegs).
I want to use something like adb, testdisk, or photoRec. But neither adb (or testdisk) recognises the device. It appears I have to enable USB debugging, but I don't know how to do this because I cannot access the phone controls, since it is running now only in fastboot mode, or in bootloop if I restart it.
So right now I cannot get up a proper adb shell or anything else that might recognise the data. (I notice fastboot devices gives a device name, but other fastboot commands do not work, and fastboot does not recover data, does it?).
By what steps ought I proceed to recover test and image data when this phone is in fastboot mode? or the original bootloop which is causing the problem?
Many thanks in advance.
I would try to reflash the device with Androxyde's flashtool and not wipe the data in the process.
The bootloader has to be opened in the process.
I do not know what recovery procedures the SONY tools provide (companion, Emma) but I would check them out.
Thanks for that information. But as I understand it, rooting the device will wipe all existing data.
I need to gain access to the device while it is in fastboot mode without wiping the data I am trying to recover. Then I assume I would run adb, testdisk, photoRec, or whatever.
no root required
flashing a stock rom does not give you root rights
for my device there are only Sony roms available - so it might even work without opening the bootloader...
you are right: opening the boot loader wipes the device (factory reset)

Trying to boot into TWRP recovery

I'm trying to install lineage OS 16 on my Sony Xperia Tablet Z LTE, in order for it to be up to date and able to use modern apps. I'm really not that tech savvy, but this far I've managed to unlock the bootloader, root the device and I believe I've managed to flash the recovery drive with the TWRP file meant for my device. I tried to flash the recovery from my windows PC, but every time I received "Failed "remote command not allowed" despite the device being unlocked at the bootloader and it is an A partition. So instead I went ahead and rooted the device and afterward flashed the tablet from the official TWRP app. At the end of the flash, I got "Flash completed successfully" which leads me to believe that I've flashed it correctly.
Now the issue is that no matter what I try, I can't boot into recovery mode. Every time I try, it just boots up regularly. I've tried via ADB terminal, through the TWRP app, and physically with the power button+volume down button, but everytime I get the same result.
This has me wondering, could I just download the Lineage image to my device and flash it directly to the boot partition or would this not work? Also what could be the reason I can't boot into recovery mode?
Sorry if this is not the forum for this topic, i just can't imagine who else would be able to advise me on this
luka0954 said:
I'm trying to install lineage OS 16 on my Sony Xperia Tablet Z LTE, in order for it to be up to date and able to use modern apps. I'm really not that tech savvy, but this far I've managed to unlock the bootloader, root the device and I believe I've managed to flash the recovery drive with the TWRP file meant for my device. I tried to flash the recovery from my windows PC, but every time I received "Failed "remote command not allowed" despite the device being unlocked at the bootloader and it is an A partition. So instead I went ahead and rooted the device and afterward flashed the tablet from the official TWRP app. At the end of the flash, I got "Flash completed successfully" which leads me to believe that I've flashed it correctly.
Now the issue is that no matter what I try, I can't boot into recovery mode. Every time I try, it just boots up regularly. I've tried via ADB terminal, through the TWRP app, and physically with the power button+volume down button, but everytime I get the same result.
This has me wondering, could I just download the Lineage image to my device and flash it directly to the boot partition or would this not work? Also what could be the reason I can't boot into recovery mode?
Sorry if this is not the forum for this topic, i just can't imagine who else would be able to advise me on this
Click to expand...
Click to collapse
Just to be sure, do you have USB debugging enabled?
Droidriven said:
Just to be sure, do you have USB debugging enabled?
Click to expand...
Click to collapse
I do, and of course I went and enabled it again after I bootloaded the device
Droidriven said:
Just to be sure, do you have USB debugging enabled?
Click to expand...
Click to collapse
You said you tried volume down+power, on most devices, that is the combination to boot into bootloader mode, fastboot mode or download mode, depending on the device. Volume up+power is generally the combination to boot into recovery mode. This doesn't seem to be your issue though. Are you sure you flashed TWRP to the correct partition? If your device is an A/B partitioned device, you may have flashed to one of these partitions when you needed to flash to the other partition.
Try flashing a copy of your stock recovery then see if that repairs the recovery partition and allows stock recovery to boot. If it works correctly after flashing stock recovery, you may not be flashing TWRP correctly or the actual flash might be being blocked by something that you're overlooking. Are you certain that your bootloader is unlocked?

Categories

Resources