在用Eclipse+Tomcat配置J2EE項(xiàng)目時(shí),出現(xiàn)如下提示錯(cuò)誤:
Undeployment Failure could not be redeployed because it could 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.
最終解決方法如下:
1、停止運(yùn)行Tomcat,右鍵點(diǎn)擊項(xiàng)目名稱:
2、點(diǎn)擊“Properties”,在彈出窗口選中“Java Build Path”,再點(diǎn)“Libraries”書簽,如下圖
3、把所有項(xiàng)目的jar都Remove掉,然后再把這個(gè)項(xiàng)目的jar都加進(jìn)來,
4、添加完后,再次Redeploy,
5、看到Successfully deplayed,即配置成功了。如上圖。