Android 以下进程: -cmd.exe -java.exe 正在锁定以下目录:
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/10473971/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
The following processes: -cmd.exe -java.exe are locking the following directory:
提问by Sherif ElNady
I am installing 2.3.3 android API and i got this error:
我正在安装 2.3.3 android API,但出现此错误:
Warning:
The following processes:
-cmd.exe
-java.exe
are locking the following directory:
C:\Program Files (x86)\Android\android-sdk\tools
Any help??
有什么帮助吗??
回答by Ahmed
just go this dir:
去这个目录:
C:\Program Files (x86)\Android\Android SDK\temp
and cut every thing was there then paste it in a new folder..
并剪切那里的所有东西,然后将其粘贴到一个新文件夹中..
Run the Update again..
再次运行更新..
回答by hydrogirl
I got the same problem. Then I downoaded latest SDK(only the SDK. no need to download android platforms).
我遇到了同样的问题。然后我下载了最新的SDK(只有SDK。不需要下载android平台)。
There's a folder call "tools" in "android-sdk" folder. I replaced the previous "tools" folder with newly downoaded "tools" folder. So far it's working in Eclipse.
“android-sdk”文件夹中有一个名为“tools”的文件夹。我用新下载的“工具”文件夹替换了之前的“工具”文件夹。到目前为止,它在 Eclipse 中工作。
回答by mughil
I did better went to sdk/temp and found out
tools_r22.6.3-windows.zip
which was downloaded but not installed
i just extracted the zip and replaced tools in \sdk\tools
我做得更好去sdk / temp并发现
tools_r22.6.3-windows.zip
哪个已下载但未安装我只是解压缩了zip并替换了工具\sdk\tools
note : exit eclipse and sdk manager , delete the old TOOLS folderrater than replacing it.
注意:退出eclipse和sdk manager,删除旧的TOOLS文件夹rater而不是替换它。
回答by wyatt
What worked for me is changing the name of the folder specified (C:\Program Files (x86)\Android\android-sdk\tools). After changing the name of the folder i opened android studio. next i went into the tools folder that i renamed and ran the android.bat file. this opened up the manager and allowed me to install no problem. A new tools folder will be created and used im assuming its safe to delete the old one that was renamed.
对我有用的是更改指定文件夹的名称(C:\Program Files (x86)\Android\android-sdk\tools)。更改文件夹名称后,我打开了 android studio。接下来我进入我重命名的工具文件夹并运行 android.bat 文件。这打开了管理器,让我安装没有问题。将创建并使用一个新的工具文件夹,假设可以安全地删除已重命名的旧文件夹。
回答by ale83t
I "solved" it in this way: as said before, go to C:\Program Files (x86)\Android\android-sdk\temp and copy the content to a new folder. Extract the content of the zip file, which contains the new tools just downloaded, and copy the entire folder back to C:\Program Files (x86)\Android\android-sdk. This worked for me.
我以这种方式“解决”了它:如前所述,转到 C:\Program Files (x86)\Android\android-sdk\temp 并将内容复制到一个新文件夹中。解压 zip 文件的内容,其中包含刚刚下载的新工具,然后将整个文件夹复制回 C:\Program Files (x86)\Android\android-sdk。这对我有用。
回答by karthick
Download sdk from http://developer.android.com/sdk/index.html.Copy tools folder from the downloaded sdk folder and replace existing tools dir in already existing sdk folder. This worked for me. I face this issue while updating sdk. Upon copying and pasting the tools will not give any issue as you will be replacing updated version of tools to your existing sdk. This is not the right way as you need to do it all the time when you need to update sdk. Better way is to copy tools dir in ur sdk and paste it with diff name like toolsDiplicate in this folder run android.bat file as administrator. Hope this helps. Any other way to resolve this issue or any reasons for which we face this issue please let me know
从http://developer.android.com/sdk/index.html下载 sdk。从下载的 sdk 文件夹中复制工具文件夹,并替换现有 sdk 文件夹中的现有工具目录。这对我有用。我在更新 sdk 时遇到了这个问题。复制和粘贴这些工具不会出现任何问题,因为您会将更新版本的工具替换为现有的 sdk。这不是正确的方法,因为当您需要更新 sdk 时,您需要一直这样做。更好的方法是将工具目录复制到您的 sdk 中,并使用不同名称(如 toolsDiplicate)将其粘贴到此文件夹中,以管理员身份运行 android.bat 文件。希望这可以帮助。解决此问题的任何其他方法或我们面临此问题的任何原因,请告诉我
回答by Khawaja Absar
I resolved this by copying my \tools folder, naming the copy \toolsCopy. Then I ran android.bat from the \toolsCopy folder with Administrator privileges.
我通过复制我的 \tools 文件夹解决了这个问题,将副本命名为 \toolsCopy。然后我以管理员权限从 \toolsCopy 文件夹运行 android.bat。
Running the SDK manager from \tools locked the renaming of the \tools directory, for obvious reasons. SMH
出于显而易见的原因,从 \tools 运行 SDK 管理器会锁定 \tools 目录的重命名。SMH
回答by QuaziRidwanHasib
- Go to your android-sdk folder.
- Rename 'tools' folder like 'tools1' or 'toolss' or anything else
- Open cmd with Administration and go to that new renamed tools1/toolss folder from cmd Ex-C:\Users\Eshad\AppData\Local\Android\android-sdk\toolss>android
- Type 'android' for running the android.bat file
- Now update
- 转到您的 android-sdk 文件夹。
- 将“tools”文件夹重命名为“tools1”或“toolss”或其他任何名称
- 使用管理打开 cmd 并从 cmd Ex-C:\Users\Eshad\AppData\Local\Android\android-sdk\toolss>android 转到新重命名的 tools1/toolss 文件夹
- 输入“android”来运行 android.bat 文件
- 现在更新
回答by Vishal Nair
If you are on Windows instead of doing all those tricky things I solved it by downloading the 'sdk only' installer.exe which you can get here -> http://developer.android.com/sdk/index.html
如果你在 Windows 上而不是做所有这些棘手的事情,我通过下载“仅限 sdk”的 installer.exe 来解决它,你可以在这里找到 -> http://developer.android.com/sdk/index.html
1)Scroll down and click on DOWNLOAD FOR OTHER PLATFORMS
1)向下滚动并点击其他平台的下载
2)You will see two tables ADT bundle and SDK tools only .In that 'Sdk Tools only' one you can get the installer.exe(dont click on the .zip download) ... Just download it and run it but remember if you have saved your android in some other drive which is not the default then you will have to specify the path to the android sdk folder when the installer asks you to specify the path.
2)您将看到两个表 ADT 包和 SDK 工具。在那个“仅 Sdk 工具”中,您可以获得 installer.exe(不要单击 .zip 下载)...只需下载并运行它,但请记住是否您已将您的 android 保存在其他一些非默认驱动器中,然后当安装程序要求您指定路径时,您必须指定 android sdk 文件夹的路径。
This solved my problem quit well without any problem.Cheers !!!
这解决了我的问题,没有任何问题。干杯!
回答by erdomester
I received this error while the ddms was running (i was taking print screens from you phone). Exit and click Yes.
我在 ddms 运行时收到此错误(我正在从您的手机上获取打印屏幕)。退出并单击是。