If a file is locked, you can wait until the lock times out
In myeclipse, the Java project is rolled over and modified, and finally the deployment fails. the following error message is displayed:
Deployment failure on Tomcat 6. x. cocould not copy all resources to E: \ apache-Tomcat-6.0.16 \ webapps \ hebbnwebservices. if a file is locked, you can wait until the lock times out to redeploy, or stop the server and redeploy, or manually remove the deployment
E: \ apache-Tomcat-6.0.16 \ webapps \ hebbnwebservices
When you click the "deploy" button again, the following message is displayed:
Undeployment failure cocould not be redeployed because it cocould not be completely removed in the undeployment phase. the most common cuase of this problem is attempting to redeploy while the server is running, which has locked one or more files.
To correct the deployment you will need to stop the server and then redeploy the project before restarting the server.
The solution is to re-Add the JAR file referenced in the project in eclipse. The basic reason is that the previous JAR file does not exist, but the project information also exists, that is, the project. the classpath file also contains references to non-existing jar files.
Right-click the project name, select Properties, select Java build path, select libraries, remove all the jar files in the project, and click "add jars ", add the jar files in the project, and the re-deployment will be normal.