问题
I have ran into a curious error when trying to update Android SDK Tools
to revision 21
from revision 20.0.3
. The ADT plug-in updated properly so now I am at a stand still until resolved.
The initial error I got listed cmd.exe
& java.exe
as locking the directory, I forced closed cmd.exe
and got this:
If I force close java.exe
then obviously my SDK Manager closes.
SDK Manager Log:
This is my work computer so I'd really like to avoid any down-time resulting from a reboot, just curious if anyone has come across this issue and been able to resolve.
I have tried closing Eclispe and running SDK Manager from the file directory, same issue, I read that someone had experienced this while having the directory opened so I closed and still, same issue. Any help is appreciated.
Eclipse:
Version: 3.7.2
Build id: M20120208-0800
Update:
Fresh reboot did NOT resolve.
回答1:
I resolved this by copying my \tools
folder, naming the copy \toolsCopy
. Then I ran android.bat
from the \toolsCopy
folder with Administrator privileges.
Running the SDK manager from \tools
locked the renaming of the \tools
directory, for obvious reasons. SMH
回答2:
It work for me after long search
Close the sdk manager and eclipse.
Go to the folder where you have stored your adt.
In that adt folder you'll find a folder known as tools.
Make a copy of the contents of that folder and paste it in a folder called copytools.
Now go to the command prompt and go to the location of the copytools.
Then execute the command android.bat the sdk manager will start.
Now update all the plugins you want. It'll update your original folder.
After the update delete the copy.
回答3:
I got mine working by going into the android-sdk\temp folder and extracting the tools_r22.3-windows.zip
and renaming the current tools
folder to tools123
and moved the extracted tools folder to \android-sdk\
回答4:
- Close command line & explorer (whatever is blocking java.exe)
- Cut all files & folders from temp folder (android-sdk\temp)
- Paste it to some other folder say (temp_old)
- Run cmd.exe (Run as administrator) and start the process again.
- If still it doesn't work, manually copy tools directory to temp folder & check.
回答5:
IF USING ANDROID BUNDLE
close the SDK manager and eclipse. From the SDK folder in bundle goto tools. Copy all files of the tools folder to another folder named toolscopy. Now in cmd navigate to SDK folder then to toolscopy and execute "android.bat". Now the SDK manager will execute and you can update all your updates. you can delete the toolscopy folder as the tools folder will automatically get updatesd :D
回答6:
Close eclipse and try again it will work.. (After closing eclipse Android SDK Manager window will not close)
or,
Just go to task manager and end the eclipse process and try again it will work..
回答7:
I solved it in a very simple way, worked well for me.
- close eclipse.exe
- go to your directory containing android-sdks
- run SDK Manager.exe
- install required packages
- close sdk Manager.exe
- Start eclipse and you are almost there
- update your ADT plugins by visiting Help menu in eclipse and then Check for Updates
- in case if it doesn't (which it didn't in my case remove the old versions of plugins manually) work and install them again from https://dl-ssl.google.com/android/eclipse/
回答8:
Steps to Resolve that
- Close the Eclipse
2.Run the SDK Manager
3.Now update the packages
It works for me
回答9:
I got the same problem. Then go to temp folder extract "tools_r24.0.2-windows.zip" copy "tools" folder from extracted folder and then paste it inside "sdk" folder.(or override on tools folder) :)
回答10:
100 % working...
- close eclipse.exe
- go to your directory containing android-sdks
- run SDK Manager.exe
- install required packages
- close sdk Manager.exe
- Start eclipse and you are almost there
- update your ADT plugins by visiting Help menu in eclipse and then Check for Updates
- Restart your computer.
回答11:
If you install SDK with eclipse in execution this error will go occur. For you resolve this problem, you should have stop the eclipse application.
回答12:
I solved this using "unlocker" by emptyloop to unlock the directory without having to kill java.exe using the task manager.
来源:https://stackoverflow.com/questions/13587478/sdk-manager-failed-to-install-java-exe-locking-directory