无法删除 surefirebooster
Cannot delete surefirebooster
我正在使用 Eclipse 工作区(版本:Mars Release (4.5.0)
构建 ID:20150621-1200)在 Windows 10 系统上。在我签出一个项目并尝试使用 Maven clean 构建它之后,它给出了构建失败。这是我得到的错误
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building XYZ:: SU 2.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] Downloading: https://XYZ/maven-resources-plugin/maven-metadata.xml
[INFO] Downloading: https://XYZ/maven-jar-plugin/maven-metadata.xml
[INFO] Downloading: https://XYZ/maven-install-plugin/maven-metadata.xml
[INFO] Downloading: https://XYZ/maven-metadata.xml
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ geodis-su ---
[INFO] Deleting C:\Users\Documents\workspace\XYZ\XYZ-su\target
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 7.300 s
[INFO] Finished at: 2016-05-17T14:35:56+02:00
[INFO] Final Memory: 18M/284M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on project geodis-su: Failed to clean project: Failed to delete C:\Users\Documents\workspace\XYZ\XYZ-su\target\surefire\surefirebooter82744427512387012.jar -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
如果我重新启动我的电脑,我可以删除这个文件(和整个项目),但是当我在我的工作区中再次签出这个项目时,我得到了同样的错误。我该怎么办?
您可能有一个 java 程序 运行 surfire jar。要查看它,请启动一个 jps 命令(这是 JDK 的软提供)您将拥有该进程,然后您可以终止它。
后台必须有一个 java 进程 运行 来运行 surefire jar。尝试从任务管理器中终止所有 java 任务,然后尝试删除 surefire jar 或尝试立即执行 maven clean。
下面的步骤通过命令提示符强制杀死它
- jps -m
- taskkill /PID /F
- 使用
jps -m
检查计算机上的 Java 个进程
- 然后杀例如
taskkill /F /PID 30503
我正在使用 Eclipse 工作区(版本:Mars Release (4.5.0) 构建 ID:20150621-1200)在 Windows 10 系统上。在我签出一个项目并尝试使用 Maven clean 构建它之后,它给出了构建失败。这是我得到的错误
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building XYZ:: SU 2.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] Downloading: https://XYZ/maven-resources-plugin/maven-metadata.xml
[INFO] Downloading: https://XYZ/maven-jar-plugin/maven-metadata.xml
[INFO] Downloading: https://XYZ/maven-install-plugin/maven-metadata.xml
[INFO] Downloading: https://XYZ/maven-metadata.xml
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ geodis-su ---
[INFO] Deleting C:\Users\Documents\workspace\XYZ\XYZ-su\target
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 7.300 s
[INFO] Finished at: 2016-05-17T14:35:56+02:00
[INFO] Final Memory: 18M/284M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on project geodis-su: Failed to clean project: Failed to delete C:\Users\Documents\workspace\XYZ\XYZ-su\target\surefire\surefirebooter82744427512387012.jar -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
如果我重新启动我的电脑,我可以删除这个文件(和整个项目),但是当我在我的工作区中再次签出这个项目时,我得到了同样的错误。我该怎么办?
您可能有一个 java 程序 运行 surfire jar。要查看它,请启动一个 jps 命令(这是 JDK 的软提供)您将拥有该进程,然后您可以终止它。
后台必须有一个 java 进程 运行 来运行 surefire jar。尝试从任务管理器中终止所有 java 任务,然后尝试删除 surefire jar 或尝试立即执行 maven clean。
下面的步骤通过命令提示符强制杀死它
- jps -m
- taskkill /PID /F
- 使用
jps -m
检查计算机上的 Java 个进程
- 然后杀例如
taskkill /F /PID 30503