Java – Error : Could not find End Of Central Directory

antjavaunixweblogic

I am trying to deploy a war on weblogic9 using an ant task on a Unix box. I am getting the following error :
[wldeploy] Error opening file [file path] Could not find End Of Central Directory.
The war file has the name similar to a datasource. This error only occurs if the war file name matches with a datasource. The war gets successfully deployed of the name is different than a datasource in weblogic.

Best Answer

That sounds a lot like a corrupted JAR / WAR / EAR file. Try to upload it again. Or try to make sure there is no conflicting file on the WL server where it tries to unzip it ...