Related
I am a new to using Linux, I just downloaded the SDK 1.5 and I am having some trouble getting the tools to work properly. For example. If I try to open the emulator it will just sit there and do nothing. I cannot get adb to work either. I set it up / the instructions. Any ideas on what I am missing? Thanks
easiest way to fix the adb problem is to move your adb command that is included in the SDK into your /usr/bin or /bin directory. if you have a problem with either of those then type cd ~/<sdk>/tools followed by ./adb the "./" tells the phone to run the command in the current directory, otherwise you could just type the directory to adb to run it i.e. ~/SDK/tools/adb that's all you need. as far as the emulator i have no idea because i have never gotten it up and running properly
How do I add the ADB command to usr/bin?
You can do as followed:
- Run the Terminal
- cd to your sdk/tools directory
- Run these command:
Code:
#./adb kill-server
#./adb devices
If you see your HTC has been remounted, it's done!
sudo mv ~/sdk/tools/adb /usr/bin/adb
tubaking182 said:
sudo mv ~/sdk/tools/adb /usr/bin/adb
Click to expand...
Click to collapse
Got it thanks for your help! I still can't get the emulator to work. Oh well Thanks again
What version of Linux? Are you using 64 Bit? What is the result of typing
Code:
java -version
You created the AVD, right?
What do you get when you type:
Code:
android list avd
stovenator said:
What version of Linux? Are you using 64 Bit? What is the result of typing
Code:
java -version
Ubuntu version 9.04 & 64 Bit
java version "1.6.0_13"
Java(TM) SE Runtime Environment (build 1.6.0_13-b03)
Java HotSpot(TM) Client VM (build 11.3-b02, mixed mode, sharing)
You created the AVD, right?
What do you get when you type:
Code:
android list avd
Click to expand...
Click to collapse
bash: android: command not found
They made a change in 1.5 SDK that you must specifiy the virtual device you want the emulator to run. if you just double click on "emulator", it will print the error to console and exit.
So first cd to the tools directory of the sdk and type android[return]
you will be given the commands that android (the program) will accept. you can also do this for emulator.
Great!! Everything is working well now. Thanks for everyones help!!
How Do I get fastboot working in Ubuntu?
jordanjf86 said:
How Do I get fastboot working in Ubuntu?
Click to expand...
Click to collapse
http://andblogs.net/fastboot/
fastboot is included in the 1.5 sdk, once you get adb working it should start working as well.
billc.cn said:
fastboot is included in the 1.5 sdk, once you get adb working it should start working as well.
Click to expand...
Click to collapse
Actually it doesn't seem to be in the Linux 1.5 SDK; I had to build it. It's in the Windows SDK, though. Kinda weird.
Android SDK 1.5 emulator trouble in windows
hi i m new to xda and to android i m not tech savy
i install sdk 1.5 i try ddms it works good what when i try to lanch emulator nothing happnes and i try by going in command promt im getting this error can any one help me out in this
C:\Documents and Settings\jass>emulator
emulator: ERROR: You did not provide the name of an Android Virtual Device
with the '-avd <name>' option. Read -help-avd for more information.
If you *really* want to *NOT* run an AVD, consider using '-data <file>'
to specify a data partition image file (I hope you know what you're doing).
karan09 said:
hi i m new to xda and to android i m not tech savy
i install sdk 1.5 i try ddms it works good what when i try to lanch emulator nothing happnes and i try by going in command promt im getting this error can any one help me out in this
C:\Documents and Settings\jass>emulator
emulator: ERROR: You did not provide the name of an Android Virtual Device
with the '-avd <name>' option. Read -help-avd for more information.
If you *really* want to *NOT* run an AVD, consider using '-data <file>'
to specify a data partition image file (I hope you know what you're doing).
Click to expand...
Click to collapse
First, this is the wrong thread for such a question. This thread is about SDK issues in Linux, and you're asking about using debugging tools in Windows.
Second, if you say yourself that you are "not tech savvy", then I'm not quite sure why you are wanting to play with the SDK tools. I don't mean this in a derogatory way; I'm just not sure what it is that you're trying to accomplish.
That said, Android dev docs can be found here, and information specifically about the emulator is here.
- Chris
Is there any step by step tutorial to get my htc magic rooted
I can only find posts where they say it is like on windows but without installing files but i have no idea how to enter that prompts on terminal
it would be much appreciated any help. I know i am not the only one interested
cesardeluxe said:
Is there any step by step tutorial to get my htc magic rooted
I can only find posts where they say it is like on windows but without installing files but i have no idea how to enter that prompts on terminal
it would be much appreciated any help. I know i am not the only one interested
Click to expand...
Click to collapse
The commands are the same. Just like Linux users can follow Windows directions but with some substitutions.
Download the SDK here: http://developer.android.com/sdk/1.5_r3/index.html
Follow the instructions here: http://developer.android.com/sdk/1.5_r3/installing.html
Once you have the SDK setup, you can follow the steps given in the rooting threads/wiki. Any time it says to enter a command you do it in your terminal (which on OSX i think is Terminal.app, use Spotlight to find it).
Hope this helps a bit.
i dont get this:
Code:
On a Mac, look in your home directory for .bash_profile and proceed as for Linux. You can create the .bash_profile if you haven't already set one up on your machine
i don't have that .bash_profile how do i create it?
thanks
Google easy to use and always there for you.
Clinton
yeah but all tutorials are made for xp or even linux.
I have tried to create it using vi command then edited with the path o the sdk tools
but when i type adb it doesn't do anything
i am stuck there
Did you check my link for your bash_profile ? This help at all?
Clinton
cesardeluxe said:
yeah but all tutorials are made for xp or even linux.
I have tried to create it using vi command then edited with the path o the sdk tools
but when i type adb it doesn't do anything
i am stuck there
Click to expand...
Click to collapse
Try reading this:
http://www.tech-recipes.com/rx/2621/os_x_change_path_environment_variable/
Sounds like the Path variable may be in a different file. It is the same on linux, I think it can be in a few places.
Irf you want to use adb without messing with your path you can do the following:
Code:
cd <android-sdk-location>/tools
./adb devices
This is convoluted so get that PATH working and everything should be nice and easy! Good luck.
I use a Mac, and when I was getting started I used the linux tutorials with no problem.
i can push the 2 files using commands to my sd. Adb devices shows my htc ok
but after i enter to fastboot mode the device is no longe shown
i type
Code:
./fastboot boot recovery-new.img
but the only thing i get is
Code:
-bash: fastboot: command not found
i am on tools directory on terminal
i think fastboot is not in the tools directory ...
i'd rather say the error is caused by that then a missing connection.
Does the phone write "FASTBOOT USB" ?
if you type "ls", can you find a file named fastboot in your directory?
cesardeluxe said:
i can push the 2 files using commands to my sd. Adb devices shows my htc ok
but after i enter to fastboot mode the device is no longe shown
i type
Code:
./fastboot boot recovery-new.img
but the only thing i get is
Code:
-bash: fastboot: command not found
i am on tools directory on terminal
Click to expand...
Click to collapse
The files have to be executable. You can do that by running:
Code:
chmod -R +x /path/to/tools
This makes all the files in the tools directory executable with ./
About the .bashrc or .bash_profile if you don't have one in your home directory you can safely make one. With the following command:
Code:
echo "export PATH=$PATH:/path/to/tools/" > ~/.bashrc
or if the file exists just do:
Code:
echo "export PATH=$PATH:/path/to/tools/" >> ~/.bashrc
Remember to restart the shell after you are done with this.
the reason adb work for you is because adb is in tools directory
fastboot does not. You have to get fastboot somewhere else
Whenever you get command not found, you can run another command to check
ls <program you ran>, and see what happened
Example
in your tools directory, where you have no problem running adb push, try doing "ls adb", without the quote
in your tools directory, where you have problem running fastboot, try doing "ls fastboot", without the quote
and you should see what's going on
BTW, this is fairly basic unix environment. If you are having trouble at this stage, you need to get yourself more familiar with unix environment, which is what osx is based on
I am sorry, but i don't really know where's good tutorial on unix
On google, i just search for "mac osx unix shell tutorial:, and come across this site
http://www.osxfaq.com/tutorials/LearningCenter/
Hope this help
Edit 1: btw, here's where you can find fastboot for MAC. Put it in your tools directory. IF you keep the filename as is, you need to type fastboot-mac whenever you see someone mention fastboot
http://www.htc.com/www/support/android/adp.html
yeah you're right fastboot is not on that tools directory. in fact i have looked into the whole sdk folder and i can't find it.
thanks
hey i managed to apply the update thanks to having fastboot-mac on tools folder
but after booting i go to terminal to apply the final step and i get this
Code:
MBdeluxe:tools cesarleon$ ./adb shell flash_image recovery /sdcard/recovery-new.img
error reading /sdcard/recovery-new.img header: Is a directory
what's wrong ?
thank you people
cesardeluxe said:
hey i managed to apply the update thanks to having fastboot-mac on tools folder
but after booting i go to terminal to apply the final step and i get this
Code:
MBdeluxe:tools cesarleon$ ./adb shell flash_image recovery /sdcard/recovery-new.img
error reading /sdcard/recovery-new.img header: Is a directory
what's wrong ?
thank you people
Click to expand...
Click to collapse
Are u sure that recovery.img got transferred properly? Maybe check the rights on it (it not read only or something). What if you mount the sdcard in OS X and copy and paste (vs push)?
If you're trying to flash the recovery image, try
Code:
adb shell mount -a
adb push recovery-new.img /system/recovery.img
adb push recovery-new.img /sdcard/recovery-new.img
adb flash_image recovery /sdcard/recovery-new.img
Hope that helps
adb shell mount -a
Click to expand...
Click to collapse
didn´t work i think the parameter a is not correct
well this is almost the last step! thank you all for your explanations
cesardeluxe said:
hey i managed to apply the update thanks to having fastboot-mac on tools folder
but after booting i go to terminal to apply the final step and i get this
Code:
MBdeluxe:tools cesarleon$ ./adb shell flash_image recovery /sdcard/recovery-new.img
error reading /sdcard/recovery-new.img header: Is a directory
what's wrong ?
thank you people
Click to expand...
Click to collapse
Very odd error message
Do this to check what your phone's sdcard looks like
Code:
adb shell ls -l /sdcard/recovery-new.img
Next, you should grab the file from your phone to your computer. This step assume you are in your tools directory
Code:
adb pull /sdcard/recovery-new.img recovery-new-phone.img
Finally, try to compare the file you have on your computer against the one you got from your phone, and see if they are the same. This assume you have your working recovery-new.img in tools directory
Code:
diff recovery-new.img recovery-new-phone.img
I have not try this diff command, and I assume it'l handle binary diff
If diff can not handle binary file, do ls and check file size. both file should match
Code:
ls -l recovery-new.img recovery-new-phone.img
If your computer and phone recovery-new.img are not the same, download to phone again
cesardeluxe said:
didn´t work i think the parameter a is not correct
well this is almost the last step! thank you all for your explanations
Click to expand...
Click to collapse
You will get Failed Mounts when u run
Code:
adb shell mount -a
You CAN ignore them.
See here: http://forum.xda-developers.com/showthread.php?p=4029461
This may not be the right way to do it but I always just downloaded the recovery to the tools directory of the android sdk. Then fire up the phone in fastboot mode and do:
./fastboot flash recovery recovery-new.img
(replacing recovery-new.img with the name of the downloaded img file.)
I'm sure there is a reason people are doing it the other way, but for myself one command to do the flash is alot easier!
We are looking for users that is still on STOCK ROM and Kernel. BOTH AT&T and Roger. We are trying to see what errors are in STOCK so we can crush out bugs we might have introduce in modified Kernel or ROM
If you are a user still running STOCK ROM/KERNEL please run this command and post your dump.txt files
adb logcat -d *:E > dump.txt
You must have adb running. USB Drivers installed either by KIES package or Samsung USB Package, ADB should be in your folder if you used Zergberg Root method. Or can be downloaded via the Android SDK package
Your help will only future help the developing
mbze430 said:
We are looking for users that is still on STOCK ROM and Kernel. BOTH AT&T and Roger. We are trying to see what errors are in STOCK so we can crush out bugs we might have introduce in modified Kernel or ROM
If you are a user still running STOCK ROM/KERNEL please run this command and post your dump.txt files
adb logcat -d *:E > dump.txt
You must have adb running. USB Drivers installed either by KIES package or Samsung USB Package, ADB should be in your folder if you used Zergberg Root method. Or can be downloaded via the Android SDK package
Your help will only future help the developing
Click to expand...
Click to collapse
Here ya go
oh ok lol thank u i found it dugh
silver03wrx said:
im trying to do this i keep getting the message the process cannot access the file because it is being used by another process?. i did adb kill-server then adb start server it started then i typed in adb logcat -d *:E > dump.txt. and i can not find the dang text file on my sd card lol sorry have not used adb much
Click to expand...
Click to collapse
the text file will be located in the directory where you ran the command from and not in the sdcard or in the phone
ok thanks bud here ya go
Attached my dump file.
I may need to google some of the crap that was in it.
[Linux/Mac] ADB & Fastboot Install Script
I have created a script to be used to install ADB and Fastboot on a Mac or a Linux computer. Simply run the script in Terminal or a similar application and it will copy ADB and Fastboot to /usr/local/bin/
Also, as of Version 3.1 this also installs the JDK for Linux-based systems.
While advanced users probably won't need this, it would be good for new users who need help using the ADB and Fastboot commands.
You can see the source at GitHub.
Download
If you have any problems or errors, let me know.
Changelog:
20171202
Moved entirely to GitHub
On Debian-based Linux, installs the adb and fastboot packages
Other systems, the binaries are pulled from Google's website
Executables are given +x permissions
Version 5.0
Hosted on GitHub and Google Code
Uses latest adb and fastboot (as of April 3, 2014)
Install to /usr/local/bin/
Version 4.1
Uses cp rather than mv
Hosted on GitHub again
Team BlueRidge project
Version 4.0
Now installs adb and fastboot to /usr/bin/ which is a more appropriate directory for the files.
Includes Readme now!
Version 3.1
Added JDK Install for Linux
Version 3
Created separate scripts for Linux & Mac
Updated uninstall script
Version 2.1.1
Fixed errors in installer
Version 2.1
More code efficient.
Better comments in script.
Version 2
Combined installer scripts into one Universal
Updated Uninstall.sh to remove udev rules
Version 1.1
Added udev rules for Linux
Version 1
Initial release
Linux
Didn't work on linux, I suggest making a seperate script for linux, I believe the problem is where it detects linux. It gets sudo but nothing more. I ran each command by itself under linux and it worked. Thanks.
shootind5nukes said:
Didn't work on linux, I suggest making a seperate script for linux, I believe the problem is where it detects linux. It gets sudo but nothing more. I ran each command by itself under linux and it worked. Thanks.
Click to expand...
Click to collapse
Thanks! I'll fix that and post an update soon!
JDK is now installed on Linux systems!
Now hosted on Google Code rather than GitHub.
Now installs to /usr/bin/, which is a more appropriate directory as these files are not required for normal system booting or are required for the general functions of your operating system.
i know this thread is old but i need some help.
my devices are not showing up after running the script.
i used adb devices and ./adb devices
boneskid1 said:
i know this thread is old but i need some help.
my devices are not showing up after running the script.
i used adb devices and ./adb devices
Click to expand...
Click to collapse
Does it say that ADB is not found or your devices?
Try enabling ADB (USB Debugging) on your device if it says no devices were found.
Gingerbread: Settings>Applications>Development>USB Debugging
Ice Cream Sandwich: Settings>Developer options>Android debugging
Thanks!!!! This worked perfectly. Using Ubuntu 11.10.
romuloxiii said:
Thanks!!!! This worked perfectly. Using Ubuntu 11.10.
Click to expand...
Click to collapse
I'm happy I could help! Don't forget to click "Thanks" if you liked it!
If you have any issues in the future with it, please feel free to let me know!
Good news!!! This is now a Team BlueRidge project and is on Team BlueRidge's GitHub
since tar.gz files are linux that means I download the zip file on my mac right? sorry if the question is obvious
prflash3 said:
since tar.gz files are linux that means I download the zip file on my mac right? sorry if the question is obvious
Click to expand...
Click to collapse
Download whichever for whichever platform. It's the script inside that you use that matters.
Trying to run the script on OSX, but when I am prompted to enter my password I can't type anything. Please help.
Ditto ul49, being prompted for a password, please advise
Simply type your account password. It won't look like anything is being typed but it is. This is how the "sudo" command works. It is for security.
really glad i found this.
i run "sh "sh script name" and i get this error
ADB-Install-Linux.sh: 5: ADB-Install-Linux.sh: Syntax error: newline unexpected
not sure if it's installed or what
thanks for making this set of scripts and if u could advise me on that error id be grateful.
---------- Post added at 05:46 PM ---------- Previous post was at 05:44 PM ----------
crazy
apt-get install android-tools-fastboot
and
apt-get install android-tools-adb
worked
Just released the first update in two years. Sorry to leave this project unmaintained. The files are now hosted by Team BlueRidge as Google Code no longer supports downloads.
First, thank you very much for putting this together for fellow users. While I'm not the most savy of guys I thought I might just share my experience while installing this ADB + Fastboot package on my MacBook Pro (mid 2012) running OS X Mavericks 10.9.3 in the hopes that somebody might benefit from it as well.
So here it goes:
I tried running the installation script found in "Androidv5.zip" which up until now is the latest version (I think). The script failed to install:
"This will install ADB and Fastboot on your computer.
Root Permissions required. Please type your password.
Password:
Changed directory to /Users/User/Downloads/Androidv5
Moving ADB
cp: /usr/local/bin/adb: No such file or directory
ADB Moved to /usr/local/bin/adb
moving Fastboot
cp: /usr/local/bin/fastboot: No such file or directory
Fastboot moved to /usr/local/bin/fastboot
You may now run Android Debug Bridge and Fastboot commands
Have a nice day."
So I figured I'd open the script file and run each command manually but they would still not work. I then decided to open the target directory
from terminal and it couldn't find it either, so I openned the /usr/ directory to find where the /bin/ directory was... and I found it at | /usr/bin | instead of | /usr/local/bin |.
I ran the commands in the script again manually one by one with the target directory set to | /usr/bin | and then closed terminal and reopened. After that I tried running "adb devices" and the output was "permission denied".
I then applied a "chmod 775 /usr/bin/adb" "chmod 775 /usr/bin/fastboot", closed & reopened terminal and voilà it worked!
Again I'm not a savy guy... there might probably be a better way to do this or perhaps I didn't run the install script as it was supposed to but anyway I decided to let you guys know how it went just in case it proves useful to somebody else....
Then again thanks a lot for sharing this! I finally have ADB + Fastboot on my Mac without having to nag about downloading the Android SDK. :laugh: :good:
Hello,
I couldn't find an up to date thread with this, so I decided to create it.
I uploaded the newest adb and fastboot binaries out of the Android SDK for OS X and Linux and wrote a little script, which installs it for you.
You can find the script and the binaries here: https://github.com/simmac/minimal_adb_fastboot
I will try to keep the binaries up to date! You can help me by posting an answer as an heads up, I will do the rest.
How to install:
Download the zip
unzip it
cd to the directory (probably Downloads/minimal_adb_fastboot ) *
Start the shell script with ./install.sh
*You don't longer have to do this. Since v1.1 you can call the script with /path/to/script/./install.sh . (eg Downloads/minimal_adb_fastboot-master/./install.sh )
You can either download the zip directly ( https://github.com/simmac/minimal_adb_fastboot/archive/master.zip ) or clone the repository ( https://github.com/simmac/minimal_adb_fastboot ).
[LEGACY] Installer Package! You can now install the binaries via my installer package, which simply copies the binaries to /usr/bin. Download: https://github.com/simmac/minimal_a...nload/1.1.1/Quick_ADB-Fastboot_Installer.mpkg NOTE: The package isn't supported anymore, please use the script!
NOTE: This is for OS X and Linux!
I hope I help you with this.
Changelog:
15.11.2014: Initial release with adb version 1.0.32
16.11.2014: v1.1 allows you to call the script from everywhere
23.11.2014: v1.1.1: Name changed to "Quick ADB / Fastboot installer" due to name conflict with "Minimal ADB and Fastboot"
[*]10.03.2015: v1.2: Update to Platform-Tools v22 and adjustments to the script.
13.03.2015: v1.2.1 Improved version check
14.03.2015: v2.0: Linux support! (experimental)
31.05.2015: v3.0: Major code cleanup, uninstaller and more
v1.1 release
I just released v1.1 of my script.
Changes: The script can now be called from everywhere, you don't have to navigate to the folder anymore.
Thanks! Working great for me.
Good to hear, @JennyLikesSka !
Excellent. The first link on Google didn't support sideload but this did so thanks so much!
AlecRobertson said:
Excellent. The first link on Google didn't support sideload but this did so thanks so much!
Click to expand...
Click to collapse
You are welcome!
That's exactly why I made this I couldn't find the newest Binaries anywhere, so I downloaded the whole SDK and extracted the bins.
Maybe a mod wants to pin the thread?
v 1.1.1 release notes + installer package
I just released v1.1.1, which changes the name to "Quick ADB/Fastboot installer" due to name conflict with the "Minimal ADB and Fastboot" tool.
Also, I did some cleanups in the code and made an installer package, which simply copies the binaries in /usr/bin.
Download the installer package here: https://drive.google.com/file/d/0B_i0YdEB_NoQVklSNldvRTVpZU0/view
And the normal command line installer here: https://github.com/simmac/minimal_adb_fastboot/archive/1.1.1.zip
I run accross the issue with flashing my N5 with stock 5.0 and adb needing to be updated to 1.0.32
I have downloaded and run command prompts up to where it says - Installation completed successfully! adb version 1.0.32 is now installed.
I then tried to flash again, but still get the error to update my adb?
simmac said:
I just released v1.1.1, which changes the name to "Quick ADB/Fastboot installer" due to name conflict with the "Minimal ADB and Fastboot" tool.
Also, I did some cleanups in the code and made an installer package, which simply copies the binaries in /usr/bin.
Download the installer package here: https://drive.google.com/file/d/0B_i0YdEB_NoQVklSNldvRTVpZU0/view
And the normal command line installer here: https://github.com/simmac/minimal_adb_fastboot/archive/1.1.1.zip
Click to expand...
Click to collapse
The package won't open on my mac. Just get an error message.
@dholm: How do you run adb/fastboot?
With "adb" or "./adb"?
@JennyLikesSka: Which Message?
Did you try open it with rightclick - > Open?
Which OS X version do you run?
simmac said:
@dholm: How do you run adb/fastboot?
With "adb" or "./adb"?
@JennyLikesSka: Which Message?
Did you try open it with rightclick - > Open?
Which OS X version do you run?
Click to expand...
Click to collapse
./adb
dholms said:
./adb
Click to expand...
Click to collapse
I see, that's your error.
With installing adb, you don't have to execute it with ./ before the command name, simply type in the command via "adb" .
Ha I will give that a try, thanks!
dholms said:
Ha I will give that a try, thanks!
Click to expand...
Click to collapse
Do this, please report back, also if it worked.
simmac said:
Do this, please report back, also if it worked.
Click to expand...
Click to collapse
It got passed my previous issue, but it now shows
E: footer is wrong
E: signature verification failed
Install aborted
My steps were
1. Install 5.0 (LRX21O) from here - https://developers.google.com/android/nexus/images
2. Install Android SDK from here - https://developer.android.com/sdk/index.html
3. Rename folders (1 = ota.zip and 2= android)
4. Copy ota.zip to platform-tools folder
5. Run terminal commands (cd /Users/*username*/Desktop/android/sdk/platform-tools -> adb devices -> adb reboot-bootloader -> put into recovery then hold power button and tap volume up -> install from adb -> adb sideload ota.zip
@dholms: Seems like an issue with your update.zip. Are you rooted?
simmac said:
@dholms: Seems like an issue with your update.zip. Are you rooted?
Click to expand...
Click to collapse
Lock state was unlocked to install DP of 5.0 - That was it...
Edit: seems this might be the issue - http://forum.xda-developers.com/google-nexus-5/help/e-footer-wrong-t2938236
dholms said:
Edit: seems this might be the issue - http://forum.xda-developers.com/google-nexus-5/help/e-footer-wrong-t2938236
Click to expand...
Click to collapse
Yeah, seems so, you may have to flash the image.
But my Installer worked, right?
simmac said:
Yeah, seems so, you may have to flash the image.
But my Installer worked, right?
Click to expand...
Click to collapse
Yes it did, thank you very much!