Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When I try to run the Android SDK Manager from the command line it doesn't open. Keeps giving me command not found or permission denied message like so.

osama@prometheus:/media/osama/develop/android-sdk-linux/tools$ pwd
osama@prometheus:/media/osama/develop/android-sdk-linux/tools$ /media/osama/develop/android-sdk-linux/tools/android
bash: /media/osama/develop/android-sdk-linux/tools/android: Permission denied
osama@prometheus:/media/osama/develop/android-sdk-linux/tools$ sudo /media/osama/develop/android-sdk-linux/tools/android
sudo: /media/osama/develop/android-sdk-linux/tools/android: command not found

Am I missing something? Am i doing something wrong? Please help.

share|improve this question
up vote 5 down vote accepted

The reason you could not run it is because the SDK was on an external drive mounted with the noexec flag active. If you run the mount command you should see the word noexec on the line of the external drive. This is a safety feature to prevent executing malicious software by accident. As a result the android binary could not have the executable bit set, hence you could not run it.

Copying it to a different disk (as you did) where you can set the executable bit with chmod +x /path/to/android is the solution.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.