Maven Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean Failed to delete
2017-07-21 22:09
916 查看
When I‘m trying to exucute next goals:clean install tomcat7:run ,there is an error :
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean(default-clean) on project myproject: Failed to clean project: Failed to delete-> [Help 1]D:\EclipseWorkspace\myproject\target\tomcat\logs\access_log.2015-02-21
I‘ve googled and understand that tomcat uses this access_log file,
where he logs user requests. And by the time when I want to execute goals listed above, as I‘m using Eclipse IDE, the JVM denies for deleting this file.
solution1:
Have you stopped Tomcat before clean? If not this is a typical problem on Windows, cause if the file is being
used windows will lock that file and you can‘t delete it.
solution2:
I‘ve seen this sort of error whenever there‘s a process that‘s holding a lock on a file in some subfolder
that‘s Maven is trying to clean. Check that your Tomcat instance is really stopped (look for java processes in Task Manager that shouldn‘t be there).
关闭这个进程就可以了,因为再次build时tomcat并没有真正关闭。
I‘ve also created this issue for myself by opening the access log in a text editor, and then forgetting to close the editor after shutting down the Tomcat and trying to run a new build.
similar:
kill the java (TM) process from processes in you computer. re-run mvn cmd . It should work now.
相关文章推荐
- Maven Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean Failed to delete
- Maven Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean Failed to delete access_log
- maven编译错误:Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean
- Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean
- maven 编译出错 Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean
- Maven项目报错:Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clea
- Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on proj
- maven 编译出错Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean
- 关于Maven项目“Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean问题的解决方案
- Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on proj
- maven 编译出错 Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean
- Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on proj
- maven 编译出错 Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean
- Maven项目报错:Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clea
- Maven项目报错:Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean ...
- maven clean install命令报错 Failed to execute goal org.apache.maven.plugins:maven-clean-plugin
- maven打包报错:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5:test
- maven package:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5:test
- maven 打包错误解决:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5:test
- maven打包报错:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5:test