includeMe
includeMe

Reputation: 2672

Failed to get adb version; error = 13 in Ubuntu 11.10

I added 32-bit android adk to eclipse(Classic, Indigo, Version: 3.7.0 Build id: I20110613-1736) in Ubuntu 11.10. I use 32-bit Ubuntu. When I start Eclipse the following error occurs.

Failed to get the adb version: Cannot run program "android-sdk-linux_x86/platform-tools/adb":java.io.IOException:error=13, Permission denied

I had already tried

1)set chmod -R 777 for android-sdk-linux_x86, platform-tools and adb. 

2)added jdk 6 as follows
sudo apt-get update
sudo apt-get install sun-java6-jre sun-java6-plugin
sudo apt-get install sun-java6-bin 
sudo apt-get install sun-java6-jdk

But these two fixes doesn't work. What will be the issue? and can anyone guide me, to fix this issue?

Upvotes: 1

Views: 13370

Answers (2)

includeMe
includeMe

Reputation: 2672

Finally the issue is fixed. The solution I tried is much similar to @cataxo's answer. In addition to adding the platform-tools I had to add the tools folder in the bashrc.

This is how I added the android paths in the bashrc file.

# Android tools
export PATH=${PATH}:~/android-sdk-linux_x86/tools
export PATH=${PATH}:~/android-sdk-linux_x86/platform-tools

export ANDROID_SDK_HOME=~/android-sdk-linux_x86/tools
export PATH=$PATH:$ANDROID_SDK_HOME

For those who have this problem after adding this, if you still have this issue then please make sure that the java path is added. It may be like

export JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.26
export PATH=$PATH:$JAVA_HOME

The java version name may varry depending on the version installed on your machine. To find the version name type java -version from terminal.

If still the issue exists then please check the permissions of avd folder, its contents and .android folder.

Upvotes: 3

catoxo
catoxo

Reputation: 61

I have the same problem. But my jdk version is 7 . I solved it by doing the following steps:

  1. ctrl+alt+t>>vi ~/.bashrc>>Add the path "android-sdk/platform-tools" to export Path= ....:Path
  2. set chmod -R 777 android-sdk`

Upvotes: 6

Related Questions