[noob-read] adb and fastboot. What is it? How can it help you? - Nexus 6 General

Please note, I can only speak with any degree of certainty about devices bought from Play / Moto. I cannot attest to the accuracy of this information for US carrier versions etc. Anything you do is at your own risk
Contents / Thread overview
Introduction
What is Fastboot?
What is adb?
How to install adb and fastboot
How to test adb and fastboot work
OK Gimme some useful fastboot commands please!
OK Gimme some useful adb commands please!
A little more about using Windows command prompt
Myth Busters
Introduction
adb and fastboot are very useful command line tools. They can be used from Windows, Linux or Mac to carry out tasks on your android device, such as moving and backing up files, rooting and restoring your phone to it's factory state. Understanding how to use these tools could save your phone when you get yourself in trouble. This is especially true of rooted users. Particularly those of you who are "new to the scene". You definitely should read and understand this thread before you do ANYTHING root related.
This thread is not intended to be a non-exhausted reference. It is merely here to give an overview of the most basic of basics
{
"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"
}
What is fastboot?
Fastboot comprises of 2 components.
1) Fastboot mode on the phone (The Bootloader)
2) Fastboot tool on your computer
Fastboot is a small command line tool that you can use from your computer whilst the phone is connected via USB and you are booted into the bootloader. The most common uses for fastboot are:
Unlocking the bootloader - needed as part of the rooting process
Flashing a custom recovery to the device - needed as part of the rooting process
Flashing factory images - used for saving / trestoring your device back to stock
Being able to do these 3 things are essential before rooting. Many new users skip learning these and use a toolkit to root. As a result, when they mess up and we try to explain what they need to do to fix their issues, it becomes very difficult for us to help as fastboot is not understood. It is YOUR responsibility to understand these things BEFORE you mess up.
What is adb?
adb is another small command line tool that stands for "Android Debugging Bridge". Again, it can be used from a computer connected via USB to your android device. It can be used whilst the device is booted into Android or (if you have a custom recovery), it can be used in recovery too, unlike fastboot (yes, adb and fastboot are NOT the same thing) which can only be used in the bootloader.
adb can be used to push files to (or pull files from) your phone. It can also be used to execute many of the commands available in Linux terminals (Or Android terminal emulators) on the device itself. We're not here to cover all these commands however. We just want to cover the basics.
How to install adb and fastboot
adb and fastboot are very easy to install and can be installed on Windows, Linux and MAC computers. The Windows install can be a little bit more complicated than the other 2 and may need additional drivers installing too.
Windows.
There is a very handy tool that can install adb and fastboot in 15 seconds. It is recommended that you use this to install adb and fastboot. Please see the link immediately below for that tool:
ADB, Fastboot and Drivers - 15 seconds ADB Installer - Really quick and easy way to install adb and fastboot (by @Snoop05). Download links are at the bottom of post 1.
This tool asks if you want to install adb and fastboot (to which you should answer Y) and then creates c:\adb\adb.exe and c:\adb\fastboot.exe
It then asks if you want to install it system wide .. This is asking to install for all windows users. < 15 second installer needs updating to SDK 23, which is required for latest Android versions.
Download the latest SDK (adb and fastboot) versions here: https://developer.android.com/sdk/index.html (Scroll down to SDK tools only) then download the Windows *Installer*.
Open the installer and select "Platform-tools" and install the packages. This should create "C:\Program Files (x86)\Android\android-sdk\platform-tools"
Now we want to set this path as a Windows Environment variable PATH to make the executables work system wide:
right-click computer > properties > advanced > environment variables.
under system variables click "path" and click "edit"
at the end of the line, add the below:
Code:
;C:\Program Files (x86)\Android\android-sdk\platform-tools
Please note, the semi-colon ; is VERY important.
You may also need to install drivers.
Here is a link to the Google USB Driver: DOWNLOAD THIS
Code:
To install on Windows 7:
- Ensure existing drivers are uninstalled first*
- Extract the zip to c:\adb (created earlier by the installer)
- Right-click "Computer" > Manage in windows and choose "Device Manager"
- Boot the Nexus 6 to the bootloader (Volume down + Power) and connect the USB Cable
- Watch for any new devices with exclamation marks appearing
- Right-Click the new device > Update driver software
- Choose the "browse" method and browse to c:\adb, find teh folder you extracted then follow the wizard to the end - using amd6 64 if you're on a 64 bit system and i386 if you're on a 32 bit system.
*To uninstall existing drivers, boot into Android and connect the USB cable. Monitor device manager for the device showing up. To uninstall the device, right-click it to uninstall it. At the prompt, ensure you also choose to delete the driver. Repeat this for bootloader and recovery.
Code:
To Install on Windows 8, you may need to additionally disable driver enforcement
- From the Metro Start Screen, open Settings (move your mouse to the bottom-right-corner of the screen and wait for the - -- pop-out bar to appear, then click the Gear icon).
- Click ‘More PC Settings’.
- Click ‘General’.
- Scroll down, and click ‘Restart now’ under ‘Advanced startup’.
- Wait a bit.
- Click ‘Troubleshoot’.
- Click ‘Advanced Options’
- Click ‘Windows Startup Settings’
- Click Restart.
Once that is done, your Windows computer is configured for adb and fastboot.
In device manager, the device should show up as below, depending whether you are booted into recovery or bootloader...
Recovery - Android Device > Google Nexus 4 ADB Interface
Bootloader - Android Device > Google Nexus 4 Bootloader Interface
If it shows as something different, either you have existing drivers in the way or something went wrong.
Linux and Mac
Here is a really simple tool to install adb and fastboot on the above OS. The only expectation is you know how to open and run a terminal command. Please see the link immediately below:
Nexus Tools 2.2 (Featured by XDA) - adb and fastboot installer for Linux and Mac (by @corbin052198)
Once you have installed adb and fastboot from the above link, you're ready to go.
How to test adb and fastboot work
As previously mentioned, adb and fastboot are both command line tools. That means you must run these tools from command prompt (cmd in Windows) or Terminal (Linux and Mac).
Remember earlier, I mentioned that fastboot can only be used in bootloader? and adb can only be used in Android (or custom recovery - lets cover that later)? We can use the command "fastboot devices" and "adb devices to see if we have adb and fastboot working correctly.
Lets try it.
Boot your phone into android
Connect it to your computer via USB
Open cmd (start > type "cmd" on Windows) or Terminal (Mac/ Linux
Type in the windows "adb devices" and press enter
Here is what we don't want to see:
Notice how there is nothing underneath where it says "List of attached devices" That means it cannot see any device
Here is what we DO want to see:
We can see that there is now a device listed.
OK lets test fastboot. Unplug the USB and turn off the phone. When it is off, hold down Volume down + power until you feel the vibrate. You will now be in the bootloader. Reconnect the USB cable.
In the same window (cmd or terminal) we're going to now type "fastboot devices".
Again, here is an example of what we don't and do want to see:
If in both modes, you can see your devices "Serial Number", then you know they are both working.
Please note that if you cannot get adb and fastboot to work "system wide", you can open the command prompt to the location of the adb and fastboot executables exist and try from there.
OK Gimme some useful fastboot commands please!
Here are some of the most useful fastboot commands you will come across. Fastboot is used mostly for flashing images to the devices partitions on the internal memory.
Code:
fastboot oem unlock
This unlocks your bootloader and allows you to flash a recovery to root. WARNING, this will wipe your device. Rooting the N6 is essentially unlocking the bootloader, flashing a recovery and then putting the SuperSU zip on your sdcard and flashing it via the recovery. This thread covers rooting: [HOW-TO] The Nexus 6 All-In-One Beginner's Guide by @xBeerdroiDx
Code:
fastboot flash recovery recovery.img
This will flash a recovery.img to the recovery partition. The command is broken down into "fastboot flash" (what to do) "recovery" (where to flash to) "recovery.img" what to flash there. In the terminal or command prompt, you cannot just type "recovery.img" though. It has to be the path to where the recovery image is. For example, if my recovery image is on my desktop, I would have to type:
Code:
fastboot flash recovery c:\users\rootsu\desktop\recovery.img
It is worth noting, that it IS case sensitive, meaning if your file is called Recovery.img, you must type the capital R...
Other things you would flash:
Code:
fastboot flash system system.img
fastboot flash boot boot.img
These will flash the system image (ROM) and boot image (kernel) as you would if you were returning to stock.
A full guide to returning to stock can be found here: [TUTORIAL][GUIDE][HOW TO] Flash Factory Images || Unroot || Relock bootloader by @Mr hOaX
You can also boot into a recovery.img without flashing it...
Code:
fastboot boot c:\users\rootsu\desktop\recovery.img
which is "fastboot boot" (what to do) "c:\users\rootsu\desktop\recovery.img" what to do it with. As you may have noticed, we did not define the recovery partition in this command, that's because we're not flashing it....
OK Gimme some useful adb commands please!
At the moment, we are going to assume you have a custom recovery and you have booted into recovery. The reason for this is using adb in recovery can be much simpler.
Here are some useful scenarios for using adb.
Backup your sdcard to your PC
Code:
adb shell
mount data
exit
adb pull data/media/0 c:\MyBackup
**Please note, some recoveries may "mount data" automatically on boot, so don't be disheartened if you get an error stating device or resource busy. This probably just means you can't mount what is already mounted**
/data/media/0 is the real location of /sdcard for your information. Also referred to as "The mount point". What we have done here is "adb pull" (what to do) "data/media/0" (what to move) "c:\MyBackup" (where to move it to)
Push a zip file from your PC to your sdcard (useful if you wiped your sdcard and rom)
Code:
adb shell
mount data
exit
adb push c:\rom.zip data/media/0
What we have done here is "adb push" (what to do) "c:\rom.zip" (what to move) "data/media/0" (where to move it to)
You can of course also use adb to push and pull files to and from /system too. You just need to:
Code:
adb shell
mount system
exit
I mentioned earlier that using custom recovery is much easier for adb than whilst booted into Android. You need to ensure you have a kernel that allows insecure adb before you do anything with system and data partitions. You also need to ensure that USB debugging has been enabled in developer options.
For example, to mount system to pull files whilst android is running you have to:
Code:
adb root
adb shell
mount -o rw,remount /dev/block/platform/msm_sdcc.1/by-name/system /system
...which is clearly a little bit more involved, so I recommend you use recovery for adb push and pull. You can find more detailed information on adb here: http://developer.android.com/tools/help/adb.html
A little more about using Windows command prompt
One thing to understand is that like Windows, command prompt (cmd.exe) works with directories (or folders if you like). The Linux and Mac terminals are the same, but most linux users, we expect you would already know this.
Here you will see I have downloaded a recovery image that I want to flash using fastboot.
As you can see, the recovery.img is located in C:\users\rootSU\Desktop
Usually when you open the command prompt from the start menu, or run command, the command prompt will default to your user location as seen below:
So lets try and fastboot flash recovery recovery.img...
It fails with a not-too-accurate error message. It has failed because you have not told it where the recovery image is. It assumes it is in the directory as listed in the prompt
So, how do we deal with this? Well, there are 3 ways.
1) We tell the command prompt where the recovery.img actully is in the command itself
Success! As you can see, we have told the command that the location for the file is Desktop\recovery.img
2) We can change the directory in command prompt to the directory where the file is. In this example, we change directory to "Desktop". The change directory command is "cd " or in this case "cd Desktop"
3) ...and possibly the simplest method. We hold shift whilst we right-click on the folder we want to change directory to, and directly open a command prompt there:
Another point to make with command prompt or terminals, is if you do a particular command, it is "pre-programmed" to "expect" a particular format of that command.
For example, we know that adb push as a command expects after it . This means the command is actually
Code:
adb push
BUT if you put something AFTER , for example -
Code:
adb push somethingelse
, it will assume that the "somethingelse" is a bad parameter, and the command will fail. It will probably display (or "print" which is the technical term in a terminal) a helpful guide of how the command should be used instead of trying to run the command which it does not understand.
You're probably wondering why I am telling you this. Well quite simply, it is a warning about folder names. Imagine you have c:\users\rootSU\My Documents as a folder. You assume the command is then
Code:
adb pull /data/media/0 c:\users\rootSU\My Documents
but it is not... There is a space in between My and Documents. What you have actually done is
Code:
adb pull Documents
because it uses a space to signify the end of a command or parameter. It is best to avoid using folders with spaces in them. Avoid as much as you can. In the event it is unavoidable (Although when is it ever>) then please surround the path with quotation marks,
Code:
adb pull /data/media/0 "c:\users\rootSU\My Documents"
so that way, it sees everything between the " " as a single parameter.
Myth Busters
Myth 1: You need USB debugging on to use adb and fastboot
If you cannot boot into Android, it doesn't matter. You DO NOT need USB Debugging turned on to use adb outside of android. USB Debugging is an Android ONLY setting. Fastboot obviously also does not need debugging either as this too is outside of Android
Myth 2: to adb push or fastboot flash files, they must be in the same folder as adb or fastboot executables. Sorry but this is rubbish. You can pass the full path of the image you're flashing or file you're pushing in the command and fastboot / adb can be called system wide if you've set them as an environment variable or used the 15 second installer

thanks(im out of thanks). but ill be back to leave one here!!!!!

simms22 said:
thanks(im out of thanks). but ill be back to leave one here!!!!!
Click to expand...
Click to collapse
No worries. Just putting it here for info. It's not a new work, just a slightly amended version of my N5 thread. No need for thanks

rootSU said:
No worries. Just putting it here for info. It's not a new work, just a slightly amended version of my N5 thread. No need for thanks
Click to expand...
Click to collapse
it was up in the n5 threads before, and was needed here. but its here now as well, so thank you

Good guide. Needs to be a sticky. In fact, I think every device general forum should have a sticky like this. Would have saved me a lot of grief back when....

Excellent update.

Very good to see. I'm sure lots of people will be sending noobs here for the basics.

Up to your usual helpful, good work I see.

rootSU said:
This tool asks if you want to install adb and fastboot (to which you should answer Y) and then creates c:\adb\adb.exe and c:\adb\fastboot.exe
It then asks if you want to install it system wide (to which again, you should answer Y)... This then allows you to type adb commands in the command prompt without having to open a particular directory first. You may or may not understand what I mean when I say that, but take it from me, its much more convenient and easier to use this way.
Click to expand...
Click to collapse
Y option = System-wide = install to "C:\adb" and add path for system variable - This mean you can use it by any account on your pc.
N option = Current user only = install to "C:\Users\[YOUR USERNAME]\adb" and add path for user only - Only user account used for installation can actually use it.
So if you say Y or N you will be still able to use it from any directory with cmd.
rootSU said:
It will also ask if you want to install device drivers. Actually, say N to this as we're going to cover that next, using the google USB drivers
Here is a link to the Google USB Driver: DOWNLOAD THIS
Click to expand...
Click to collapse
Drivers in my installer are the one from the link you posted here. I'm not using any modified drivers, just the one that come with SDK. And they are also digitally signed.
I hope you will fix these But still nice work, beginners should understand it :good:

Snoop05 said:
Y option = System-wide = install to "C:\adb" and add path for system variable - This mean you can use it by any account on your pc.
N option = Current user only = install to "C:\Users\[YOUR USERNAME]\adb" and add path for user only - Only user account used for installation can actually use it.
So if you say Y or N you will be still able to use it from any directory with cmd.
Drivers in my installer are the one from the link you posted here. I'm not using any modified drivers, just the one that come with SDK. And they are also digitally signed.
I hope you will fix these But still nice work, beginners should understand it :good:
Click to expand...
Click to collapse
Thanks for the info. I thought system wide meant it was putting it as a path environment variable. Reason I didmt use the drivers from your tool originally is (well I wrote this thread for N5 originally) they didnt work so had to install the universal naked driver. But if yours are the same as the ones linked, I can update that.

rootSU said:
Thanks for the info. I thought system wide meant it was putting it as a path environment variable. Reason I didmt use the drivers from your tool originally is (well I wrote this thread for N5 originally) they didnt work so had to install the universal naked driver. But if yours are the same as the ones linked, I can update that.
Click to expand...
Click to collapse
Path is added in both cases.

Sooo I need a little help here. I followed the directions to unlock the bootloader and everything went good. I did the CF auto-root, and the phone booted back up as normal. Now, I was trying to flash the M preview, and all of a suddon now my phone isn't recognized in adb. You posted a pic of what we don't want to see when testing for adb, but you don't say how to fix it if we run into the problem. Any way to get it to recognize my phone again so I can get this build on?

papeshfoo said:
Sooo I need a little help here. I followed the directions to unlock the bootloader and everything went good. I did the CF auto-root, and the phone booted back up as normal. Now, I was trying to flash the M preview, and all of a suddon now my phone isn't recognized in adb. You posted a pic of what we don't want to see when testing for adb, but you don't say how to fix it if we run into the problem. Any way to get it to recognize my phone again so I can get this build on?
Click to expand...
Click to collapse
Can you be very specific with your issue please?

papeshfoo said:
Sooo I need a little help here. I followed the directions to unlock the bootloader and everything went good. I did the CF auto-root, and the phone booted back up as normal. Now, I was trying to flash the M preview, and all of a suddon now my phone isn't recognized in adb. You posted a pic of what we don't want to see when testing for adb, but you don't say how to fix it if we run into the problem. Any way to get it to recognize my phone again so I can get this build on?
Click to expand...
Click to collapse
Android M no like root, you'll either have to live with stock or wait for chainfire to do his thing.

This all worked well until I had to find my device in the cmd prompt. It listed no devices when I typed in "ADB Devices". The issue I found was with the ADB Interface Driver. I uninstalled it and reinstalled it thinking it might've been a driver issue, but it still wouldn't work. I tried the "Uninstall driver" then "scan for hardware changes" but that didn't work. Finally I found the universal ADB driver and tried using that. STILL nothing. I figured that, because I don't have my device's driver installed, it might've been that, so I tried to DL it and yet again, nothing. I have a Kyocera Hydro Life, if that helps. Also, I tried looking through the "update driver manually" in order to update the driver software by looking through the different ADB interfaces that it had but my Kyocera driver wasn't there. Is it supposed to be there or do I just use one of the ones provided?
I checked my programs and apps and it says that the Kyocera usb driver was installed. Did I do something wrong?

ScottyChaos said:
This all worked well until I had to find my device in the cmd prompt. It listed no devices when I typed in "ADB Devices". The issue I found was with the ADB Interface Driver. I uninstalled it and reinstalled it thinking it might've been a driver issue, but it still wouldn't work. I tried the "Uninstall driver" then "scan for hardware changes" but that didn't work. Finally I found the universal ADB driver and tried using that. STILL nothing. I figured that, because I don't have my device's driver installed, it might've been that, so I tried to DL it and yet again, nothing. I have a Kyocera Hydro Life, if that helps. Also, I tried looking through the "update driver manually" in order to update the driver software by looking through the different ADB interfaces that it had but my Kyocera driver wasn't there. Is it supposed to be there or do I just use one of the ones provided?
I checked my programs and apps and it says that the Kyocera usb driver was installed. Did I do something wrong?
Click to expand...
Click to collapse
Try a different USB port. If that doesn't work try a different USB cable. If that also doesn't work, you could try disabling driver signature checking for Windows.
If those don't work, try this thread > http://forum.xda-developers.com/showthread.php?t=1583801

cam30era said:
Try a different USB port. If that doesn't work try a different USB cable. If that also doesn't work, you could try disabling driver signature checking for Windows.
If those don't work, try this thread > http://forum.xda-developers.com/showthread.php?t=1583801
Click to expand...
Click to collapse
EDIT: I also forgot to mention that the error code that came up while I was in the dev manager was compatibility error code (28) when I clicked on "Device ADB interface".

ScottyChaos said:
EDIT: I also forgot to mention that the error code that came up while I was in the dev manager was compatibility error code (28) when I clicked on "Device ADB interface".
Click to expand...
Click to collapse
Error 28 means drivers not installed. Try the driver help thread that I linked above.
---------- Post added at 12:33 PM ---------- Previous post was at 12:04 PM ----------
cam30era said:
Error 28 means drivers not installed. Try the driver help thread that I linked above.
Click to expand...
Click to collapse
@ScottyChaos,
Just a fundamental question: I assume you have enabled "Developer Options" in Settings, and then checked "enable USB debugging"?
---------- Post added at 12:39 PM ---------- Previous post was at 12:33 PM ----------
[/COLOR @ScottyChaos,
Here is a thread that you might find interesting > http://forum.xda-developers.com/android/help/metro-pcs-kyocera-hydro-life-rooted-t2870678

Windows 10 device driver management is even more locked down then windows 8. I got two of the three drivers loaded but when going into adb mode on the phone through recovery it just disappeared out of the device manager. I had to unplug and plug in while in that mode to trigger a unloaded driver in the device manager. Once there I had to force the adb driver manually with the nasty windows driver warning and all. Once I did that I could see the device in adb mode and sideload my marshmallow OTA. woot!

I decided to drop a thanks bomb...
ADB is good.
But that fastboot.
Seriously, its ONE command. OK, a few different arguments to use.... But it is so easy, and so powerful. People are afraid to mess up on command line, but its actually way harder to type the wrong thing out then to click the wrong thing.
LEARN IT. Forget your toolkit.
You can fix almost anything, Its not too hard for you. It may be new... YOU CAN DO IT.
Also, I have to say it... Its not going to help anyone, but it will keep me from punching something. ADB and Fastboot... Not the same. You don't ADB a new system image....

Related

[GUIDE] Linux Ubuntu: Unlocking Bootloader / Rooting Nexus S

One thing I've noticed is there isn't a lot of documentation for getting set up and unlocking your bootloader on a Linux OS. Setting up your machine to get adb and fastboot to recognize your device takes a tiny bit of extra work on a Linux operating system, but what exactly needs to be done may not be clear to everyone. Whether it's because you're new to the Android SDK/adb, somewhat new to Linux, or can't simply can't seem to find the Vendor Code for the Nexus S. (For those who are looking specifically for this, it's '18d1', and I assume will be the same on all Nexus devices to come; If this means nothing to you right now, read on.)
Disclaimer: I take no responsibility if something goes wrong (if it does, it should be fixable though), Unlocking your bootloader voids your warranty (but you can lock it back), Unlocking the bootloader will wipe your entire phone, including USB Storage; so make a copy of all those family photos and other files you may have put onto the USB storage if you want to keep them.
For the sake of sanity, this guide assumes you are using Ubuntu. If you're using something else (or different applications), there are terminal commands offered, and you probably have an idea on how to adapt the given instructions to your Linux OS.
Preparation: Installing the Android SDK, ADB, Fastboot & Setting Up Your Nexus S to be Recognized
1. Download the Android SDK for Linux: http://dl.google.com/android/android-sdk_r08-linux_86.tgz
2. Save it in a folder of your choice. I chose to keep it in my Downloads folder, myself. If you'd like, you can rename it to the simpler name of 'AndroidSDK.tgz'. The rest of the guide will assume that you did, because I'm lazy, and it makes things simpler; it will also assume you saved it in Downloads. If you feel that you have the intuition to rename and edit the path names based on your own choices, then fine; but if you're utterly lost here, just stick with what I'm doing; download to 'Downloads', rename to 'AndroidSDK.tgz'.
3. Now that you have it, navigate to the folder you downloaded it to, right-click, and click 'Extract' to unzip it. If for some reason you cannot do this, open up a terminal and try this command:
Code:
tar zxvf /home/<your-user-name>/Downloads/AndroidSDK.tgz
You may have to adjust the command if you didn't save it under Downloads or didn't rename the file to AndroidSDK.tgz.
4. Now, we'll install adb and some other software packages by starting up the Android SDK and AVD Manager. Start it either by:
- Navigating to your AndroidSDK folder, going to the 'tools' folder and double-clicking the file called 'android'; if a popup opens asking you what you want to do with it click 'Run'.
- Using this command:
Code:
/home/<your-user-name>/Downloads/AndroidSDK/tools/android
5. In Android SDK and AVD Manager, click on "Available packages". Check the box next to "Android SDK Tools, revision 8" and "Android SDK Platform-tools", and click on "Install Selected" then "Install". When prompted click "Yes" to restart ADB.
6.You should now have a folder in /home/<your-user-name>/Downloads/AndroidSDK/ called "platform-tools".
7. Download fastboot here: http://developer.htc.com/adp.html
- Save it to the aforementioned platform-tools folder.
- Now, navigate to the file, right click it, click 'Properties', go to the 'Permissions' Tab and check 'Allow executing file as program'. Alternatively, run this command:
Code:
chmod +x /home/<your-user-name>/Downloads/AndroidSDK/platform-tools/fastboot
8. Now to set things up so adb and fastboot recognize your Nexus.
- Type this command into a terminal:
Code:
gksudo gedit /etc/udev/rules.d/51-android.rules
- Paste this into the blank file:
Code:
SUBSYSTEM=="usb", SYSFS{idVendor}=="18d1", MODE="0666"
- Click save and close.
- Then, type the following terminal command:
Code:
sudo restart udev
9. Almost done with preparations! Run this command:
Code:
gedit .bashrc
And add this line to the top of the file:
Code:
#AndroidDev PATH
export PATH=${PATH}:/home/<your-user-name>/Downloads/AndroidSDK/tools:/home/<your-user-name>/Downloads/AndroidSDK/platform-tools
Then save the file and close.
10. Download this file and save it to /home/<your-user-name>/Downloads/AndroidSDK/platform-tools: http://www.mediafire.com/?4pe5y906zr67nfh
10.We're ready to go!
Unlocking the Bootloader on your Nexus S and Rooting
Once again, unlocking your bootloader wipes everything on your device, including USB storage. Make a backup of any files you want to keep.
1. On your Nexus S, go to Menu>Settings>Applications. Select "Development" and check the box next to "USB debugging"
2. Power off the phone, and then hold down the Volume Up button and the Power button simultaneously to get into Bootloader/Fastboot mode. Connect your Nexus to the computer via USB.
3. Run this command to unlock your bootloader: (Once again WIPES EVERYTHING!)
Code:
fastboot oem unlock
Hit Enter and on your phone you will be prompted to confirm the action. (Use Volume +/- buttons to choose, power button to confirm choice) Confirm. At this point you will have an unlocked bootloader.
4. Copy/paste the following into the Terminal window:
Code:
fastboot flash recovery /home/<your-user-name>/AndroidSDK/platform-tools/recovery-clockwork-herring.img
5. Use the Volume +/- buttons to choose the Recovery option, then press the power button.
6. In Recovery, go to 'mounts and storage' and choose 'mount USB storage'.
7. Go to this page: http://forum.xda-developers.com/showthread.php?t=682828
About 1/5 of the way down on that page, find the link for "su-2.3.6.1-ef-signed.zip", which is the link for the Froyo version of Superuser. Control-click (right click) on that link and choose "Download Link As..." Save that file to your desktop and then copy it to the main directory of your mounted phone.
8. Click 'Unmount'. Go back to 'mounts and storage' and choose 'mount /system'. Then Go Back and choose 'install zip from sdcard'>'choose zip from sdcard'>su-2.3.6.1-ef-signed.zip
9. When it's finshed installing, reboot. You are now rooted.
Special Thanks
Amin Sabet; I used your Mac guide as a reference and copy/pasted some things for convenience.
Koush; For first posting the unlocking information, developing ClockworkMod Recovery, and ROM Manager. You should probably hook him up with a donation. https://www.paypal.com/us/cgi-bin/w...63663d3faee8d9384d85353843a619606282818e091d0
Michael.B.; for suggesting adding the platform-tools folder to the .bashrc file.
Linus Torvalds; Without which we'd have neither Android nor Ubuntu.
Feel free to leave your comments on the guide below.
Good guide for beginners, I would throw in how to update their path so they can just type adb or fastboot
On Linux, edit your ~/.bash_profile or ~/.bashrc file. Look for a line that sets the PATH environment variable and add the full path to the tools/ and platform-tools directories to it. If you don't see a line setting the path, you can add one:
export PATH=${PATH}:/home/<your-user-name>/Downloads/AndroidSDK/tools:/home/<your-user-name>/Downloads/AndroidSDK/platform-tools
Click to expand...
Click to collapse
Be sure to update your username above.
Thanks a lot man, great guide. I didn't get my NS yet but this is gonna be very useful soon
ps: someone please stick this
Michael.B. said:
Good guide for beginners, I would throw in how to update their path so they can just type adb or fastboot
Be sure to update your username above.
Click to expand...
Click to collapse
Thanks for the tip. I added your tip and instructions for marking fastboot as executable.
Stuck due to the thread's usefulness
I forgot to ask: will this work for 64 bit systems?
nicholasbgr said:
I forgot to ask: will this work for 64 bit systems?
Click to expand...
Click to collapse
It should work just fine.
Thanks, got me rooted nice and quickly.
BlackOtaku said:
It should work just fine.
Click to expand...
Click to collapse
Yes but don't forget to install 32 libs.
Thanks for guide
Useful !
I'm waiting for cyanogen ROM so i'll able to install
Cheers
To confirm, yes it works on 64bit. I am running that
Thanks for the confirmation, guys
Good stuff, much appreciated.
I'm working on a simple shell script that should automate some of the more menial tasks while holding the user's hand through the process. I should have it up later today.
UPDATE: It's up! Link on the first page.
Sent from my Nexus S using XDA App
question:
If I use
Code:
fastboot boot recovery.img
instead of
Code:
fastboot flash recovery recovery.img
will i get OTA updates?
confiq said:
question:
If I use
Code:
fastboot boot recovery.img
instead of
Code:
fastboot flash recovery recovery.img
will i get OTA updates?
Click to expand...
Click to collapse
Or, I don't get OTA until i change OS with zip file (ex: su app) ?
confiq said:
Or, I don't get OTA until i change OS with zip file (ex: su app) ?
Click to expand...
Click to collapse
You shouldn't flash the recovery in the boot partition, I think that will cause problems with the phone period. :S
If you flash a custom boot.img (which this guide doesn't cover, though the script will flash Superboot) or kernel like Paul's Superboot, Supercurio's Voodoo Kernel, or Koush's insecure boot.img, OTA updates will fail to install. OTA updates will also reflash your recovery back to stock. One of the devs around here will probably start modifying them so they don't check the boot.img or reflash the recovery though.
Thanks for this! Worked perfectly
Hi all,
I have a strange problem. I can install ClockworkMod recovery but, when I reboot the phone, I don't have superuser installed and su doesn't work. If I reboot the phone, I have to install the recovery every time. It seems it isn't permanent.
Thanks
Matroska
matroska said:
Hi all,
I have a strange problem. I can install ClockworkMod recovery but, when I reboot the phone, I don't have superuser installed and su doesn't work. If I reboot the phone, I have to install the recovery every time. It seems it isn't permanent.
Thanks
Matroska
Click to expand...
Click to collapse
To fix the problem, before selecting zip file, you have to select mount /system. Then go to apply update.zip and proceed as usual.
Thanks
ok im stock
with this part fastboot oem unlock ware i put this code in my terminal of my pc ,,i put the cell in fasboot , i intall everiting if i put that code in my terminal
bash: /home/toshiba/.bashrc: line 2: syntax error near unexpected token `('
bash: /home/toshiba/.bashrc: line 2: `export PATH=${PATH}:/home/<your-user-name>/Downloads/AndroidSDK/tools:/home/<your-user-name>/Downloads/AndroidSDK/platform-tools# ~/.bashrc: executed by bash(1) for non-login shells.'
[email protected]:~$ fastboot oem unlock
fastboot: command not found
[email protected]:~$
what can i do or im doing wrong

Trying to root but can't get ADB working

I've finally decided to try to root my G2 but can't get past the ADB setup. I downloaded the SDK, but when I open the manager and try to install platform tools it goes through the motions and then tells me nothing was installed. When I open a command prompt and type "ADB devices" it doesn't recognize anything. What am I doing wrong??
EDIT: specifically, when I try to install platform-tools it tells me it couldn't create a directory and nothing was installed.
66 people have read this and nobody has any suggestions to help?
i think you miss the 1st procedure....
you must have the unknown resources and the usb debbuging enabled.....
then you can proceed to your super one click rooting.....
I have a problem after rebooting my PC: <Java not found...> Reinstalling doesn't help, adding environment variables too. Any idea?
Just root using the rage/visionary method. No adb needed and very easy to do. Here is the linkhttp://forum.xda-developers.com/showthread.php?t=834228
Sent from my SilverBullet 'HTCDesireZ running CM7'
juvanni said:
i think you miss the 1st procedure....
you must have the unknown resources and the usb debbuging enabled.....
then you can proceed to your super one click rooting.....
Click to expand...
Click to collapse
I don't understand? I'm trying to root following the recommended wiki instructions, and I haven't been able to get adb to work so I haven't gotten past that step.
Are you running windows x64? Cause the android installer has issues detecting java on x64 systems.
When it says 'Can't find java' or whatever the error is, click back, then next again, it should find it the second time around. Well thats what happened for me anyway.
-Nipqer
If you're on froyo just use the app z4 root or universal androot
You can also use superoneclick root 2.11
Its very easy and it only take about 3 minutes
Stewie just said that!
I appreciate the help so far, but my problem is I have gingerbread and everything I've read requires froyo for root, and the only way I've read to downgrade uses ADB, so any non-ADB rooting method still won't work for me. I've followed the "ADB for dummies" thread and the other instruction thread and everything seems fine, but when I type in the first command for the downgrading it says adb isn't a recognized command. Am I in the wrong command prompt? I feel like its probably something really dumb I'm doing or not doing but for the life of me I can't figure it out.
Navigate to the folder adb is in.
Hold shift, right click in the folder (make sure nothing is selected)
select 'Open command window here' (or something along those lines)
Adb should work.
-Nipqer
OK, so I'm definitely in the right folder, I read and followed ADB for Dummies thread. Trying to follow this direction:
"Run the following command to verify the exploit has access to what it needs. (Only the first line is the command. The second line should be the result returned if all goes well.)
Code:
$ adb shell cat /dev/msm_rotator
/dev/msm_rotator: invalid length"
When I type that in, should there be spaces between the "adb" and "shell"? Should there be a space after the command prompt and before "adb"? I've tried several variations of it and it keeps telling me "adb is not recognized as an internal or external operable program or batch file."
ok you need to run the command from the folder with adb.exe in it, type it as adb<space>shell<space>cat<space>/dev/msm_rotator
If you are getting an error search for adb.exe and once found try the command again from this folder,if as you say you are in the right folder then I think you will have to reinstall adb as I just ran the command in the form above and it works so if you still get an error then something has gone wrong with the install
P.S Another way to make sure that adb is working and recognises your phone is to type adb devices, if your phone is attached and recognised then it will return a number
Thank you! I had to uninstall and reinstall the package, I don't know what was wrong but it seems to be working now. Also, I knew I was probably doing something stupid, and I was. I wasn't in the platform-tools directory for my command prompt, I was in the TOOLs directory. Just so I'm clear, every command I type into the terminal should be in the Platform-tools directory, correct?
Now, assuming I can follow all the other directions with no problems, once I get to the downgrade pushing steps, I will lose all my current settings, right? It will be a fresh froyo 2.2 like it came to me originally? Other than using Appbrain to back up my current apps, how else should I make a backup?
Final question, do I need to follow the temp root directions and push the downgrade all at one time? Or can I do the temp root and come back at a later time to push the downgrade?
First problem solved then!
Yes but follow this Step 4
Now we need to update your Path variable. This lets you run adb on your PC from a command window no matter which directory you are in (which makes things a lot easier). If you don't setup your Path, then every time you want to run adb, you will either have to type the whole long pathname where you put adb, or cd to where you've put adb and run it from there (which could be inconvenient if you are transferring files to/from your phone).
On your PC, right-click on "My Computer" and select "Properties". (on Vista, click on "Change Settings"). Go to the "Advanced" tab, then select "Environment Variables". Find the "Path" variable in the list of variables that it shows (you might need to scroll), and then double-click on that entry to edit it. Add the full path of the "tools" and "platform-tools" folders of the SDK to your path. e.g. if the SDK has been installed in "c:\Program Files\android-sdk-windows", then add to your Path "c:\Program Files\android-sdk-windows\tools;c:\Program Files\android-sdk-windows\platform-tools" (Please Note - don't put any spaces between the semi-colon and pathname, otherwise it won't work !)if you want to.
Once done you can use ADB from the command prompt in ANY folder,very handy IMO.
If I was you I would set aside enough time and see it through,no point to temp rooting alone.
Get Titanium backup from the market an absolute essential app with this you can backup,upload to dropbox(Another essential app) uninstall apps and a host of other useful tools.
Read the guide first as well,good luck.

The Complete Noob-iots Guide To Rooting, Recovery, and Troubleshooting

The purpose of this tutorial is not to teach you everything. It's just to give the less-than-average user (noob) an idea of why certain steps are taken and how to prevent and or troubleshoot problems that most people have when rooting or flashing ROMs on their device. I am also assuming that if you do decide to root your device you have at least a basic working knowledge of a computer. If you don't know what a desktop is or how to find the "any" key, you have no business being anywhere near a computer much less an android device…continue no further. Read my tutorial…If you like it, let me know. If I missed anything or got something wrong, let me know…I'll try to fix it. If you're impartial to it, I couldn't care less. If you hate it, PM me…I have some important information for you about anger management.
ROOTING
While there are different rooting "methods" they all rely on the same basic concept. Get temporary root access to your system in order to use the adb (Android Debug Bridge) to transfer necessary files and change permissions to permanently root (take ownership of) the device.
Before programs like KindleFireUtility and KindleWater, rooting the Kindle Fire was done manually through a command line interface (command prompt). Although those programs still use the same methods, you never see it. But why use command prompt? What do those commands mean anyway? Anyone can point and click but if you don't know what is going on behind the scenes then you are big trouble when things go wrong…and they inevitably will. So, let's get started.
From here on out we will consider this the beginning of the tutorial. Read everything first before doing anything. Pay close attention to what's being said and follow instructions carefully. Now...
Before anything your device needs to be fully charged and have the Android SDK and the Kindle adb drivers installed onto your computer. I'm not going to go into how to install SDK or Kindle adb drivers here because there are millions of pages on the internet that will teach you, and quite frankly that's not the purpose of this tutorial. That being said, lets get down to business and talk about the older (manual) methods of rooting the Kindle Fire.
First, lets start with the device turned on. Now go to your Kindle Fire settings and scroll down and select "Devices". Make sure "Allow Installation of Applications" is set to ON. This allows you to install apps not downloaded from the Amazon App Store. Next we open the App Store and search for and install a file management utility (ES File Explorer is a good one to start with). This will be necessary to temporarily root your device. Exit the App Store.
Now plug your device into the computer. For the purposes of this exercise there are two USB modes you will need to know, USB debugging and USB file transfer. On stock devices when you plug into your computer you will see a black screen that says "You can now transfer files from your computer to Kindle". This we will call USB file transfer mode. You will use this to transfer a program to your device that will give you temporary root permissions. The old program for this was ZergRush, nowadays its BurritoRoot and tomorrow it will probably be something else. Whatever it is, find whichever one works for your device's software version and transfer it to your device using Explorer (Windows) or Finder (Mac). Since you don't have root access yet, everything you put on your device for now will go directly to the SDcard partition, far away from system folders (for all intents and purposes).
Press "disconnect" on your Kindle Fire. Now, and by default, your Kindle is in USB debugging mode. What that means is that when you are not in USB file transfer mode your device is constantly listening for debugging commands coming from the USB port. We will be using this to send adb commands to the device which are necessary for rooting and setting up recovery. Now open the file management app you installed from the App Store, navigate to the temporary root program you transferred from your computer and open it. Install and follow the instructions, if any. Next go to your computer and navigate to your Android SDK folder and look for a folder called "platform-tools" if you don't see it, open the tools folder and double-click the file named "Android". Select "platform-tools" and install.
To make things simple, lets to take the platform-tools folder and place it on your desktop (just be sure to put it back when this is all over).
At this point we need to get Superuser. This is what we will use to give your apps root access. Go to http://www.androidsu.com/superuser and download the one for Gingerbread. Extract the superuser.zip file, open the folder and navigate to the system folder inside. There, inside the "app" and "bin" folders you will see two files called "superuser.apk" and "SU". Place them in the platform-tools folder that is now on your desktop. And now the fun part, it's time to start rooting.
Open your command prompt (or terminal for mac users) and type and enter:
cd Desktop/platform-tools
Here, you are telling the computer to cd (change directory) to the platform-tools folder located inside the Desktop folder. This is going to be your workspace. Everything you do from here on will be done from this folder. If you don't get any errors then you are in good shape. Otherwise you messed up somewhere and probably skipped a step...go back and read from the beginning. Make sure your Kindle Fire is turned on and NOT in USB file transfer mode. If you are not sure what mode you're in, go back to the beginning. If this is your second time around, stop. You need to learn more about how to change directories using command line interface.
When you are in the platform-tools folder, type and enter this command:
adb devices
Mac and Linux users will put ./ before all adb and fastboot commands from here on out. It will look like: ./adb devices
Here you are using the adb program to print a list of connected devices. You should see a bunch of numbers that mean nothing to you at this skill level. Move on. If you don't see any numbers then you either don't have your drivers installed properly or you skipped a step; go back to the beginning.
If you do get a bunch of numbers your device is connected. Now type and enter:
adb root

...gives root permissions to the adb
adb remount
...mounts the system partition to a "read/write" state allowing you to make changes to system files and folders. Consequentially, if you enter adb remount a second time, you will change it back to "read only". Don't do that.
adb push su /system/xbin/su
...will push (transfer) the file named "SU" that is in your workspace (platform-tools folder) to the su folder inside the xbin folder of your device's system folder. The SU binary file is what other apps call to when they need superuser rights.
adb shell chown 0.0 /system/xbin/su
...this is where it gets a little funky. It opens a shell interface within the adb in order to chown (give ownership permissions) to user 0.0 for the su folder. A shell is a piece of software with a particular set of commands built in to act as sort of a go-between between the user, operating system and hardware kernel services. But who is user 0.0? [Edit:] User 0.0 is the root user. Thanks to b63 for that piece of knowledge
adb shell chmod 06755 /system/xbin/su
...opens a shell within the adb to chmod (change mode) of the su folder to 06755. What that basically means is you are changing the folder permissions to rwxr-xr-x or read/write/execute for the owner, and read/execute for the group and others.
adb install superuser.apk
...installs the program superuser.apk located in the platform-tools folder. Superuser.apk maintains a database of what apps you allow to access SU binary file.
That's how the rooting process works. Again if you get any errors, you did something wrong. Go back to the beginning and read it all over again. Attention is key.
Also, I suggest you skip the one-click methods for rooting and get used to using the command line interface so you understand how the process works in order to quickly troubleshoot problems should they arise. Oh and congratulations, you are rooted.
RECOVERY
Now lets install a custom recovery utility and a new boot-loader. For this you will be using the fastboot command. Before we go on, one thing you absolutely must get your head around is the difference between how fastboot interacts with your device versus how adb interacts with your device. fastboot deals with the boot portion of the device whereas adb only deals with the system portion. What that means is adb will only work when the device is completely booted. If for some reason your device doesn't boot properly then you should not be issuing adb commands. It's like trying to light a match in a vacuum. Fastboot works in the same way in that you must be in the fastboot bootmode in order to issue fastboot commands. Unless you have custom recovery installed or a factory programming cable there is only one way to get into fastboot mode. We'll talk about that later.
Installing recovery is a simple process but it is where people tend to have the most problems. Part of the reason is the misunderstanding of the different bootmodes. For now, you only need to be concerned with two of them; normal bootmode (4000) and fastboot bootmode (4002). The main reason people run into trouble is that once you are in a particular bootmode, it doesn't change until you tell it to (with the exception of temporary fastboot which we will get into later).
In normal bootmode your device will boot...normally (imagine that). With the fastboot bootmode the boot-loader will hang at the Kindle Fire splash screen (or yellow triangle if you have recovery installed) to wait for further commands. If this happens to you, chances are your only problem is you are in the wrong bootmode, which is easy to fix. Knowing that, installing a custom recovery should be a breeze.
First find whatever recovery you want to use (unzip it if you have to) and place the .img file into your platform-tools folder that you were using earlier. We're going to use adb to change the bootmode to fastboot in order to install custom recovery. Remember, anything that pertains to the boot-loader, (Kindle Fire logo/yellow triangle) will be done in the fastboot bootmode; that includes custom recovery installation. For more information on Kindle Fire bootmodes, boot-loaders, fastboot and just about everything else, see this post:
http://forum.xda-developers.com/showthread.php?t=1552547
From your command prompt type and enter:
adb shell
su
idme bootmode 4002
reboot
What that does is tells adb to open a shell and su (substitute user) for the root user, change the bootmode from normal (4000) to fastboot (4002) and reboot. The root user has the necessary permissions to change the bootmode from the adb. Your device will reboot then hang at the splash screen because it is in the fastboot bootmode.
Now install your custom recovery (we'll call it customrecovery.img for now)
fastboot -i 0x1949 boot customrecovery.img
again, for Mac and Linux you would type: ./fastboot -i 0x1949 boot customrecovery.img
That tells your computer to, using the fastboot program that is in your platform-tools folder, boot the device with the ID of 0x1949 (your Kindle) with the file named "customrecovery.img"
After installation, reboot, but you will still be in the fastboot bootmode. So type:
fastboot -i 0x1949 oem idme bootmode 4000

fastboot reboot
…tells the device to reset the partition where the recovery(?) is located, change the bootmode to normal (4000) and reboot.
TROUBLESHOOTING
Flashing custom ROMS are another source of frustrations as they add too many variables to the equation. Some ROMS can be very unstable and cause weird things to happen to your device. But just knowing how this stuff works will help you fix 90% of the problems that may come up. If you are having trouble with your device, troubleshoot the problem:
Does the device turn on?
No

Is it fully charged?
No--> Charge it

Is it fully charged?
Yes--> Hold the power button for 30 seconds and restart

Does the device turn on?
No--> Hold the power button for 3 minutes and restart
Does the device turn on?

No--> Google search "Motorola USB factory programming cable"

Does it boot normally?
No

Do you have custom recovery installed
No--> You need to get into fastboot mode to issue fastboot commands. Google search "Motorola USB factory programming cable"

Do you have custom recovery installed?
Yes--> During the first 5 seconds of seeing the boot splash screen (this is temporary fastboot mode that comes with custom recovery) issue fastboot command to change bootmode to 4000. Reboot

Does it boot normally?

No

Can you get into recovery?
No--> During the first 5 seconds of seeing the boot splash screen (temporary fastboot mode) issue fastboot command to install a new customrecovery.img. Reboot.

Can you get into recovery?

Yes--> Re-flash your ROM. Reboot.

Does it boot normally?

No--> Enter recovery, factory reset, wipe cache, wipe dalvik cache, re-flash your ROM. Reboot

Does it boot normally?
No--> Enter recovery, factory reset, wipe cache, wipe dalvik cache, flash a different ROM. Reboot

Does it boot normally?
No--> Post your problem on the XDA forum. Include all pertinent information such as what rom you are using, what the exact problem is, what you were doing before the problem occurred and all the steps you have taken to try and fix the problem.

Does it boot normally?
Yes--> Give yourself a pat on the back, because you rock!
Do you Rock?
No--> Start over from the beginning
nice
--sent from my glacier.

[Q] only thing on phone is Twrp - HELP

My Verizon LGG2 is now only with twrp 2.7 - no os and when plugged into the computer it cannot go into download mode to flash an os. It also doesn't recognize or install driver softwear as it always does. Am I completely shot or is abd a solution as twrp says something about abd sideload but I know nothing about how to do that although I have read of people doing it before,but not about what they used it for.
Of course any help is most greatly appreciated as the phone is useless to me in this state.
You have to be more specific did you try to flash a ROM/what ROM did you try to flash
Sent from my LG-VS980 using Tapatalk
rnh said:
My Verizon LGG2 is now only with twrp 2.7 - no os and when plugged into the computer it cannot go into download mode to flash an os. It also doesn't recognize or install driver softwear as it always does. Am I completely shot or is abd a solution as twrp says something about abd sideload but I know nothing about how to do that although I have read of people doing it before,but not about what they used it for.
Of course any help is most greatly appreciated as the phone is useless to me in this state.
Click to expand...
Click to collapse
Be more specific. If you can download any ROM that fits your phone model, put it on a flash drive and use OTG cable to connect it to the phone and then flash the ROM.
Thank you spin and coo. To be more specific, I wiped the internal sd by accident and the rom that was on it but I do have the stock os backed up on my computer, When I try to go into download mode - holding down the volume up button and plugging in the cable to use the flash tool to flash the 11b kdz file to the phone, the phone just vibrates and twrp pos up. Before that it would go into fastboot mode but that has disappeared. That is why I say the only thing that appears to be on the phone as far as softwear is twrp. Do you need more info?
rnh said:
Thank you spin and coo. To be more specific, I wiped the internal sd by accident and the rom that was on it but I do have the stock os backed up on my computer, When I try to go into download mode - holding down the volume up button and plugging in the cable to use the flash tool to flash the 11b kdz file to the phone, the phone just vibrates and twrp pos up. Before that it would go into fastboot mode but that has disappeared. That is why I say the only thing that appears to be on the phone as far as softwear is twrp. Do you need more info?
Click to expand...
Click to collapse
OP, check out this post I wrote to someone else. I haven't done it myself, but I helped a buddy over the phone once with the adb sideload option. It was successful and the steps SHOULD be the same even though the reference links in my post are for an HTC phone.
http://forum.xda-developers.com/showpost.php?p=52116786&postcount=559
jas0nnn said:
OP, check out this post I wrote to someone else. I haven't done it myself, but I helped a buddy over the phone once with the adb sideload option. It was successful and the steps SHOULD be the same even though the reference links in my post are for an HTC phone.
http://forum.xda-developers.com/showpost.php?p=52116786&postcount=559
Click to expand...
Click to collapse
Thank you Jas0nnn. Looks promising. Also that otgcable is cheap and it looks as if I could load my backed up computer rom onto a flash drive and install it although I there is no driver softwear installed.
rnh said:
Thank you Jas0nnn. Looks promising. Also that otgcable is cheap and it looks as if I could load my backed up computer rom onto a flash drive and install it although I there is no driver softwear installed.
Click to expand...
Click to collapse
An OTG cable would be nice. But keep in mind you don't need it. You can still use sideload to "push" your backed up ROM from your desktop to your phone and then flash it.
How do I do that? Adb looks complicated. And the instructions which I briefly looked at only speak of pushing rom files, not complete roms.
Sent from my DROID RAZR using Tapatalk
Well I got home from work and installed and extracted the sdk zip after doing extensive reading and lo and behold after unzipping it and hitting download manager the command window pops up and promptly closes. That's it . What do I do now? TIA
rnh said:
Well I got home from work and installed and extracted the sdk zip after doing extensive reading and lo and behold after unzipping it and hitting download manager the command window pops up and promptly closes. That's it . What do I do now? TIA
Click to expand...
Click to collapse
Hmm, I think we have a miscommunication here or the ADB Sideload post is not clear enough.
First, install the ADB drivers. This will allow you to open up a command window prompt (type "cmd" in your windows search in your start menu").
ADB: http://forum.xda-developers.com/showthread.php?t=2588979
Then, you want to boot into TWRP. Plug in your phone to your computer (running Windows w/ ADB drivers installed). Go to advanced->adb sideload (don't know the exact sequence but it should be like this). This should allow you to do the commands from the "Instructions" section of this post:
http://forum.xda-developers.com/showthread.php?t=2318497
Start at step 8. By using the "adb sideload" command, you will be able to transfer a .zip from your desktop to your phone. That way, you can use good ol' TWRP to flash that .zip and get yourself back into a ROM. To use the "adb sideload" command in cmd prompt, you need to first change directory or "cd" into the directory in which you have you .zip file on your desktop. That way when you invoke the command and give it a file name, it'll look in your current directory for it. Good luck and sorry for the late response -- I was on travel.
jas0nnn said:
Hmm, I think we have a miscommunication here or the ADB Sideload post is not clear enough.
First, install the ADB drivers. This will allow you to open up a command window prompt (type "cmd" in your windows search in your start menu").
ADB: http://forum.xda-developers.com/showthread.php?t=2588979
Then, you want to boot into TWRP. Plug in your phone to your computer (running Windows w/ ADB drivers installed). Go to advanced->adb sideload (don't know the exact sequence but it should be like this). This should allow you to do the commands from the "Instructions" section of this post:
http://forum.xda-developers.com/showthread.php?t=2318497
Start at step 8. By using the "adb sideload" command, you will be able to transfer a .zip from your desktop to your phone. That way, you can use good ol' TWRP to flash that .zip and get yourself back into a ROM. To use the "adb sideload" command in cmd prompt, you need to first change directory or "cd" into the directory in which you have you .zip file on your desktop. That way when you invoke the command and give it a file name, it'll look in your current directory for it. Good luck and sorry for the late response -- I was on travel.
Click to expand...
Click to collapse
Hope it was a good trip. Do I still use the the normal ABD or the 1.3 ADB installer and fastboot to push the zip? I feel stupid to ask you to spoon feed me but I'm not a computer person. Do the drivers need to install on the phone because I don't think they will.
Well, I extracted the zip to c and placed the zip file into platform tools but the sdk manager wont open or update and the cmd won't recognize the path to access platform tools and access the zip to install it. Should be simple but I suppose it's not
rnh said:
Hope it was a good trip. Do I still use the the normal ABD or the 1.3 ADB installer and fastboot to push the zip? I feel stupid to ask you to spoon feed me but I'm not a computer person. Do the drivers need to install on the phone because I don't think they will.
Click to expand...
Click to collapse
It's ok, I understand. The community doesn't quite standardize everything or have a central area to learn the environment and such. Abandon the whole platform-tools thing. Stick with the ADB installer as it simplifies things for you.
However here's a quick explanation of how the whole software development kit (SDK) thing works. What typically happens with the instructions of downloading the software development kit (sdk) is you are supposed to download your adb drivers and put them in a folder (like platform-tools). There is an application called adb.exe which you use -- this is called the "adb driver" which relies on all the other files in the same folder where adb.exe is.If you open up cmd and change directory or "cd" into the folder which holds adb.exe, you can type "adb" in the command line to execute the adb.exe program. This is why the instructions tell you to place the .zip file of interest in the same folder as adb.exe.
The 1.3 ADB installer will install the same files (adb.exe and associate files) and point the command prompt, cmd, to adb.exe, regardless of what directory you're currently in while using cmd. So whether I am currently in C:\ or C:\Users\jas0nn, I can type "adb" in command prompt, and the application will execute. With the the method above, you have to specifically change directory into the folder which holds adb.exe in order to invoke the adb application in the command prompt. To check if your phone is recognizable, you can type "adb devices" in cmd and see if a device number pops up. If so, you're connected. I did forget to mention that you need to make sure your LG G2 USB drivers are installed. You can find them here: http://wacomalt.com/dropbox/LGG2/StockRevert/LG VZW_United_WHQL_v2.11.1.exe
tl;dr: ditch the SDK installer route. Use the 1.3 ADB installer and push the zip into your phone using adb sideload. You need the drivers from here: http://wacomalt.com/dropbox/LGG2/StockRevert/LG VZW_United_WHQL_v2.11.1.exe in order to successfully communicate to your phone via adb.
jas0nnn said:
It's ok, I understand. The community doesn't quite standardize everything or have a central area to learn the environment and such. Abandon the whole platform-tools thing. Stick with the ADB installer as it simplifies things for you.
However here's a quick explanation of how the whole software development kit (SDK) thing works. What typically happens with the instructions of downloading the software development kit (sdk) is you are supposed to download your adb drivers and put them in a folder (like platform-tools). There is an application called adb.exe which you use -- this is called the "adb driver" which relies on all the other files in the same folder where adb.exe is.If you open up cmd and change directory or "cd" into the folder which holds adb.exe, you can type "adb" in the command line to execute the adb.exe program. This is why the instructions tell you to place the .zip file of interest in the same folder as adb.exe.
The 1.3 ADB installer will install the same files (adb.exe and associate files) and point the command prompt, cmd, to adb.exe, regardless of what directory you're currently in while using cmd. So whether I am currently in C:\ or C:\Users\jas0nn, I can type "adb" in command prompt, and the application will execute. With the the method above, you have to specifically change directory into the folder which holds adb.exe in order to invoke the adb application in the command prompt. To check if your phone is recognizable, you can type "adb devices" in cmd and see if a device number pops up. If so, you're connected. I did forget to mention that you need to make sure your LG G2 USB drivers are installed. You can find them here: http://wacomalt.com/dropbox/LGG2/StockRevert/LG VZW_United_WHQL_v2.11.1.exe
tl;dr: ditch the SDK installer route. Use the 1.3 ADB installer and push the zip into your phone using adb sideload. You need the drivers from here: http://wacomalt.com/dropbox/LGG2/StockRevert/LG VZW_United_WHQL_v2.11.1.exe in order to successfully communicate to your phone via adb.
Click to expand...
Click to collapse
Well that was quick jas0nn. Thank you. The abd drivers nexus one installed from the abd google drivers but not the lg g2 drivers. Typing abd devices in cmd brings up not recognized. Guess I'm screwed unless you have any other suggestions.
rnh said:
Well that was quick jas0nn. Thank you. The abd drivers nexus one installed from the abd google drivers but not the lg g2 drivers. Typing abd devices in cmd brings up not recognized. Guess I'm screwed unless you have any other suggestions.
Click to expand...
Click to collapse
Install the LG G2 USB drivers I showed you above.
Enter yes to every option in the ADB Installer v1.3 while installing.
If you get a message "'adb' is not recognized as an.." then you have not successfully installed the adb drivers via the adb installer v1.3.
You're not screwed quite yet. Typically there is always a solution in the engineering world ;].
Here is a pic of the commands I tried
{
"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"
}
Sent from my DROID RAZR using Tapatalk
rnh said:
Here is a pic of the commands I tried View attachment 2712870
Sent from my DROID RAZR using Tapatalk
Click to expand...
Click to collapse
"adb" not "abd." "adb" for "android debug bridge."
Sent from my DROID RAZR using Tapatalk
rnh said:
View attachment 2712879
Sent from my DROID RAZR using Tapatalk
Click to expand...
Click to collapse
Looks like your device is connected. Feel free to read the help pages by typing "adb help."
Good luck.
For whatever reason, my phone was in the same situation as yours where I could only reboot into twrp. I found a pretty easy solution below:
before trying anything else just type in these commands
What worked for me was from the TWRP terminal command was to type
dd if=/dev/zero of=/dev/block/platform/msm_sdcc.1/by-name/fota
then hit enter
type
dd if=/dev/zero of=/dev/block/platform/msm_sdcc.1/by-name/misc
then hit enter and reboot.
got help from the IRC xda-devs for the second step to complete the fix.
It worked for me and now my phone seems to be running normal. The whole thread is located here:
http://forums.androidcentral.com/ge...ricked-lg-g2-stuck-twrp-no-download-mode.html
I think my phone somehow took the OTA while I had KK rooted installed. I plugged in my device to charge and got up to get a drink and when I came back my friend's cat was playing with the charger cable and my phone was in twrp. Went the whole weekend on vacation without my phone. It was rough. All seems well now.
Edit: I think I had to enter everything in twice. 1st time it worked but then rebooted back into twrp on it's own, the 2nd time it worked. Hope it helps.

Rollback 3rd Gen on 3.2.6 and unlock bootloader

I have a 3rd Gen fire hdx 8.9 on 14.3.2.6. Safestrap is installed. I want to roll back and unlock my bootloader to install the nexus rom.
Is there a tutorial available? Do I need to uninstall safestrap first?
Check page 1 of this thread, basically it's all there, so read the info & the linked threads. Any questions ask first, i.e. before you brick your kindle.
Note that you can NOT use the rollback images, nor edit the build number. You must use the procedure described in post 1 of the thread and download the rollback zip I linked in post 4, you need to scroll down to get to the 3.2.5/3.2.6 procedure.
Cl4ncy said:
Check page 1 of this thread, basically it's all there, so read the info & the linked threads. Any questions ask first, i.e. before you brick your kindle.
Note that you can NOT use the rollback images, nor edit the build number. You must use the procedure described in post 1 of the thread and download the rollback zip I linked in post 4, you need to scroll down to get to the 3.2.5/3.2.6 procedure.
Click to expand...
Click to collapse
I followed the procedure but I'm not clear that I downgraded correctly. No when I look at my system update, it says I am on 14.3.0.0_user_300079820. I thought I was supposed to be on 14.3.1.0_user_310079820? The file I downloaded from the thread is indeed "update-kindle-14.3.1.0_user_310079820.bin". Is there something else I need to do to downgrade before updating the bootloader?
rootnooby said:
I followed the procedure but I'm not clear that I downgraded correctly. No when I look at my system update, it says I am on 14.3.0.0_user_300079820. I thought I was supposed to be on 14.3.1.0_user_310079820? The file I downloaded from the thread is indeed "update-kindle-14.3.1.0_user_310079820.bin". Is there something else I need to do to downgrade before updating the bootloader?
Click to expand...
Click to collapse
I checked the rollback.zip for Apollo, it seems to be in the build.prop file, so nothing to worry about.
Now you should install TWRP via adb, update the 3.2.3.2 bootloader in TWRP, and finally unlock the bootloader.
Be sure to root and disable OTA via HDXToolkit, and enable USB debugging in Fire OS, before you flash TWRP.
And be sure to create a backup of Fire OS in TWRP before you flash any custom ROM.
Thanks. Is there a link outlining the steps to install twrp via add? Sorry for the need to have my hand held through this!
rootnooby said:
Thanks. Is there a link outlining the steps to install twrp via add? Sorry for the need to have my hand held through this!
Click to expand...
Click to collapse
You must have Minimal ADB and Fastboot installed, download the Apollo TWRP Image here, copy it to the root of the sdcard (i.e. the directory you see in Explorer when you connect the HDX to your PC, so don't open any directory there),then you open a DOS box, change dir to the adb directory (enter cd\adb), then execute the commands mentioned in the TWRP thread with the correct file name for the Apollo TWRP image.
Thanks so much. I'll give it a go tonight.
rootnooby said:
Thanks so much. I'll give it a go tonight.
Click to expand...
Click to collapse
looks like I got through everything except the last remaining step of unlocking the bootloader. I confirmed that I am rooted and OTA is blocked. Not sure how to get this unlocked so I can finally have a real ROM!
rootnooby said:
looks like I got through everything except the last remaining step of unlocking the bootloader. I confirmed that I am rooted and OTA is blocked. Not sure how to get this unlocked so I can finally have a real ROM!
Click to expand...
Click to collapse
OK, so you have Minimal ADB and Fastboot installed, unlocking the bootloader is really simple (with a little knowledge about command prompts), so download these drivers you need to install when the good ol' "waiting for device" issue occurs (check device manager then, the HDX probably has a yellow exclamation mark there).
You must download the software and the Python script mentioned here, and then follow the path outlined there, or (after installation of the required software) also here. Basically you just need to open a couple of command prompts (DOS boxes), change dir to the adb directory (enter cd\adb - or cd\python27 to go to the Python directory), then get the ID and serial, use the Python script with them, and finally execute the fastboot commands to unlock the bootloader.
That's it - and it's a no brainer, you can't mess up anything, if the unlock code is incorrect, it just won't flash (well, you must enter the fastboot commands correctly of course).
Cl4ncy said:
OK, so you have Minimal ADB and Fastboot installed, unlocking the bootloader is really simple (with a little knowledge about command prompts), so download these drivers you need to install when the good ol' "waiting for device" issue occurs (check device manager then, the HDX probably has a yellow exclamation mark there).
You must download the software and the Python script mentioned here, and then follow the path outlined there, or (after installation of the required software) also here. Basically you just need to open a couple of command prompts (DOS boxes), change dir to the adb directory (enter cd\adb - or cd\python27 to go to the Python directory), then get the ID and serial, use the Python script with them, and finally execute the fastboot commands to unlock the bootloader.
That's it - and it's a no brainer, you can't mess up anything, if the unlock code is incorrect, it just won't flash (well, you must enter the fastboot commands correctly of course).
Click to expand...
Click to collapse
Thanks. Running into an error creating the unlock file. I installed python, but I don't think i installed gmpy2-2.0.7-cp27-none-win_amd64.whl (md5) properly. The error I'm getting when I run the following command "python.exe cuberHDX.py 0xmmssssssss" "is "no module named gmpy2". I am using my correct code in the previous command. When I downloaded the gmpy2-2.0.7-cp27-none-win_amd64.whl (md5), I copied into the Python27 directory. Not sure if this is correct.
rootnooby said:
Thanks. Running into an error creating the unlock file. I installed python, but I don't think i installed gmpy2-2.0.7-cp27-none-win_amd64.whl (md5) properly. The error I'm getting when I run the following command "python.exe cuberHDX.py 0xmmssssssss" "is "no module named gmpy2". I am using my correct code in the previous command. When I downloaded the gmpy2-2.0.7-cp27-none-win_amd64.whl (md5), I copied into the Python27 directory. Not sure if this is correct.
Click to expand...
Click to collapse
Try to use the exe installer for 2.0.6 from here. If it still fails, PM me your ID and serial, I'll create the .unlock file for you then.
Cl4ncy said:
Try to use the exe installer for 2.0.6 from here. If it still fails, PM me your ID and serial, I'll create the .unlock file for you then.
Click to expand...
Click to collapse
Thanks. It worked. I now have an unlock code. I'm not clear where my fastboot directory is? It says I need to "copy that file to your fastboot directory" before i run the commands. Would that just be the root of the kindle itself? Sorry for the question.
rootnooby said:
Thanks. It worked. I now have an unlock code. I'm not clear where my fastboot directory is? It says I need to "copy that file to your fastboot directory" before i run the commands. Would that just be the root of the kindle itself? Sorry for the question.
Click to expand...
Click to collapse
If you installed Minimal ADB and Fastboot, it's the adb directory (e.g. C:\adb), you should have fastboot.exe in there as well. Just copy/move the .unlock file in the adb directory, open two DOS boxes, enter cd\adb in both,
then enter adb reboot-bootloader in the first one,
and the fastboot commands
fastboot -i 0x1949 devices
fastboot -i 0x1949 flash unlock 0xmmssssssss.unlock (mm=your ID, ssssssss=your serial)
fastboot -i 0x1949 reboot
in the second (again: if you see "waiting for device" on the fastboot prompt, install these drivers in device manager for the HDX (probably sitting there with a yellow exclamation mark).
Cl4ncy said:
If you installed Minimal ADB and Fastboot, it's the adb directory (e.g. C:\adb), you should have fastboot.exe in there as well. Just copy/move the .unlock file in the adb directory, open two DOS boxes, enter cd\adb in both,
then enter adb reboot-boorloader in the first one,
and the fastboot commands
fastboot -i 0x1949 devices
fastboot -i 0x1949 flash unlock 0xmmssssssss.unlock (mm=your ID, ssssssss=your serial)
fastboot -i 0x1949 reboot
in the second (again: if you see "waiting for device" on the fastboot prompt, install these drivers in device manager for the HDX (probably sitting there with a yellow exclamation mark).
Click to expand...
Click to collapse
Wow. I think it all worked! Assuming that's it. I can go ahead and load ROMs!
rootnooby said:
Wow. I think it all worked! Assuming that's it. I can go ahead and load ROMs!
Click to expand...
Click to collapse
If it looked like this, i.e. unlock code is correct, then yes.
Enjoy your "free" HDX.
yes, it does look like that so I have unlocked successfully! I ran a backup using twrp, and that worked well. One problem I'm having now is that my computer doesn't seem to recognize the Kindle when connected via USB any more. I'm getting a message that says some candles are not compatible and a separate file needs to be downloaded. When I go to the Kindle support website, this is applicable for older systems running Windows XP. Have you seen this problem before? Now that I have a backup I want to move it over to my PC so I don't use all that storage.
rootnooby said:
yes, it does look like that so I have unlocked successfully! I ran a backup using twrp, and that worked well. One problem I'm having now is that my computer doesn't seem to recognize the Kindle when connected via USB any more. I'm getting a message that says some candles are not compatible and a separate file needs to be downloaded. When I go to the Kindle support website, this is applicable for older systems running Windows XP. Have you seen this problem before? Now that I have a backup I want to move it over to my PC so I don't use all that storage.
Click to expand...
Click to collapse
Yes, it seems that the drivers required for fastboot cause such a problem, remove them in device manager (select to delete the driver files), then dis- and re-connect the HDX, so the original HDX drivers will be re-installed. Should do the trick in this case.

Categories

Resources