JBoss5: Cannot deploy due to java.util.zip.ZipException: error in opening zip file

前端 未结 25 2496
情书的邮戳
情书的邮戳 2020-12-03 06:15

I have a web client and a EJB project, which I created with Eclipse 3.4. When I want to deploy it on Jboss 5.0.1, I receive the error below. I searched a lot but I wasn\'t a

相关标签:
25条回答
  • 2020-12-03 06:36

    I got a very similar error and it was due to the number of maximum open files being reached. I started the application after a ulimit -n 8192 and it was able to "unzip" the file.

    0 讨论(0)
  • 2020-12-03 06:36

    Sometimes this errors shows because of version of compilation of jar/ear difers from the jdk on the server.

    0 讨论(0)
  • 2020-12-03 06:36

    I have experienced the same problem with JBoss 5.1.0.GA and Seam 2.1.1.GA. The JDK is java jdk1.6.0._07 for both Eclipse 3.5 and JBoss.

    I was able to fix the problem. Maybe the origin of the problem has to do with you concrete case, or may not, but in any event, I thought that it may help.

    I am creating the application EAR file using the build file that is included in the Seam installation examples; my build file it is a modified version of the one that comes with the bookings example. This sampl build file does an include to the build file that is common to all examples. It provides a lot of functionality that you can take advantage to create your distribution files.

    The common build examples offers several fileset and path entries that you can override to include the libraries that are unique to your project.

    Concretely, I was overriding "build.classpath.extras" and "ear.lib.extras".

    I wanted to include a determined library in the EJB jar file that gets packaged into the EAR file (the jar file where my model and action classes are); so I just overrided "jar.extras" in my build file.

    At that time is when I suffered this problem. Although my desired library in the root was copied into the root folder of the EJB jar file, apparently without problems, JBoss was dropping this error message.

    So I just stopped using "jar.extras", and I moved the reference to the desired library to "build.classpath.extras": the effect of this action was that the the library was copied to the \lib folder of the EAR file. Now the application seems to work well, and the problem dissapeared.

    0 讨论(0)
  • 2020-12-03 06:36

    I solved this problem by running the server with the same JDK as i used to compile/build the EAR.

    0 讨论(0)
  • 2020-12-03 06:39

    Are you able to open the ear file outside of JBoss (using WinZip or WinRAR)? It could be that the zip file is corrupted.

    You could try writing a little test program using java.util.zip.ZipFile.open() and see if you can debug this in a more isolated situation.

    0 讨论(0)
  • 2020-12-03 06:40

    I had the same problem with a "big" EAR deployed via ANT using a copy task. It seems that JBoss was trying to unzip it before it was totally copied. I solved the pb using a move task instead of a copy (taking care that the source folder for the move was on the same disk partition)

    0 讨论(0)
提交回复
热议问题