[ 
http://jira.codehaus.org/browse/MASSEMBLY-386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=162676#action_162676
 ] 

Thomas Dudziak commented on MASSEMBLY-386:
------------------------------------------

The above stacktrace is the output of mvn -X. Maven runs with these settings: 
-Xmx1024m -Xms512m. Increasing these to 2048m and 1024m respectively made no 
difference.

> Creation of tar.gz fails with "java.io.IOException: Corrupt GZIP trailer"
> -------------------------------------------------------------------------
>
>                 Key: MASSEMBLY-386
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-386
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Bug
>    Affects Versions: 2.2-beta-3
>         Environment: mvn -version:
> Maven version: 2.0.9
> Java version: 1.6.0_10
> OS name: "linux" version: "2.6.27-9-generic" arch: "amd64" Family: "unix"
> OS is Ubuntu 8.10 Intrepid 64bit.
> java -version:
> java version "1.6.0_10"
> Java(TM) SE Runtime Environment (build 1.6.0_10-b33)
> Java HotSpot(TM) 64-Bit Server VM (build 11.0-b15, mixed mode)
>            Reporter: Thomas Dudziak
>            Priority: Critical
>
> For a build of mine
> [INFO] [assembly:single {execution: assemble}]
> [INFO] 
> ------------------------------------------------------------------------
> [ERROR] FATAL ERROR
> [INFO] 
> ------------------------------------------------------------------------
> [INFO] null
> Corrupt GZIP trailer
> [INFO] 
> ------------------------------------------------------------------------
> [DEBUG] Trace
> java.lang.reflect.UndeclaredThrowableException
>         at 
> org.codehaus.plexus.archiver.tar.TarFile$1.hasMoreElements(TarFile.java:75)
>         at 
> org.codehaus.plexus.archiver.tar.PlexusIoTarFileResourceCollection$1.hasNext(PlexusIoTarFileResourceCollection.java:34)
>         at 
> org.codehaus.plexus.components.io.resources.AbstractPlexusIoArchiveResourceCollection.getResources(AbstractPlexusIoArchiveResourceCollection.java:58)
>         at 
> org.codehaus.plexus.components.io.resources.PlexusIoProxyResourceCollection.getResources(PlexusIoProxyResourceCollection.java:67)
>         at 
> org.codehaus.plexus.archiver.AbstractArchiver$1.hasNext(AbstractArchiver.java:362)
>         at 
> org.codehaus.plexus.archiver.AbstractArchiver$1.hasNext(AbstractArchiver.java:392)
>         at 
> org.apache.maven.plugin.assembly.filter.ComponentsXmlArchiverFileFilter.finalizeArchiveCreation(ComponentsXmlArchiverFileFilter.java:166)
>         at 
> org.codehaus.plexus.archiver.AbstractArchiver.runArchiveFinalizers(AbstractArchiver.java:760)
>         at 
> org.codehaus.plexus.archiver.AbstractArchiver.createArchive(AbstractArchiver.java:784)
>         at 
> org.apache.maven.plugin.assembly.archive.archiver.AssemblyProxyArchiver.createArchive(AssemblyProxyArchiver.java:496)
>         at 
> org.apache.maven.plugin.assembly.archive.DefaultAssemblyArchiver.createArchive(DefaultAssemblyArchiver.java:190)
>         at 
> org.apache.maven.plugin.assembly.mojos.AbstractAssemblyMojo.execute(AbstractAssemblyMojo.java:354)
>         at 
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:451)
>         at 
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:558)
>         at 
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:499)
>         at 
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:478)
>         at 
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:330)
>         at 
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:291)
>         at 
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
>         at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
>         at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
>         at org.apache.maven.cli.MavenCli.main(MavenCli.java:287)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>         at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>         at java.lang.reflect.Method.invoke(Method.java:597)
>         at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>         at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
>         at 
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>         at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: java.io.IOException: Corrupt GZIP trailer
>         at java.util.zip.GZIPInputStream.readTrailer(GZIPInputStream.java:182)
>         at java.util.zip.GZIPInputStream.read(GZIPInputStream.java:94)
>         at 
> org.codehaus.plexus.archiver.tar.TarBuffer.readBlock(TarBuffer.java:262)
>         at 
> org.codehaus.plexus.archiver.tar.TarBuffer.readRecord(TarBuffer.java:222)
>         at 
> org.codehaus.plexus.archiver.tar.TarInputStream.read(TarInputStream.java:377)
>         at 
> org.codehaus.plexus.archiver.tar.TarInputStream.skip(TarInputStream.java:144)
>         at 
> org.codehaus.plexus.archiver.tar.TarInputStream.getNextEntry(TarInputStream.java:215)
>         at 
> org.codehaus.plexus.archiver.tar.TarFile$1.hasMoreElements(TarFile.java:71)
>         ... 29 more
> [INFO] 
> ------------------------------------------------------------------------
> [INFO] Total time: 1 minute 3 seconds
> [INFO] Finished at: Tue Jan 27 05:35:34 PST 2009
> [INFO] Final Memory: 60M/368M
> [INFO] 
> ------------------------------------------------------------------------
> The assembly plugin version is configured something like this:
>       <plugin>
>         <artifactId>maven-assembly-plugin</artifactId>
>         <version>2.2-beta-3</version>
>         <executions>
>           <execution>
>             <id>assemble</id>
>             <phase>package</phase>
>             <goals>
>               <goal>single</goal>
>             </goals>
>             <configuration>
>               <descriptorRefs>
>                 <descriptorRef>default-war-assembly</descriptorRef>
>               </descriptorRefs>
>             </configuration>
>           </execution>
>         </executions>
>         <dependencies>
>           <dependency>
>             <groupId>foo.maven</groupId>
>             <artifactId>default-assemblies</artifactId>
>             <version>1.0</version>
>           </dependency>
>         </dependencies>
>         <configuration>
>           <tarLongFileMode>gnu</tarLongFileMode>
>         </configuration>
>       </plugin>
> The referenced assembly itself is a straightforward tar.gz assembly with only 
> a few file and dependency sets:
> <assembly>
>   <id></id>
>   <formats>
>     <format>tar.gz</format>
>   </formats>
>   <includeBaseDirectory>false</includeBaseDirectory>
>   <fileSets>
>     ...
>   </fileSets>
>   <dependencySets>
>     ...
>   </dependencySets>
> </assembly>
> I tested the exact same configuration on MacOS and works without problems. 
> The MacOS configuration tested was:
> Maven version: 2.0.9
> Java version: 1.6.0_07
> OS name: "mac os x" version: "10.5.6" arch: "x86_64" Family: "mac"
> The resulting tar.gz file was 82916719 bytes big with 556 files in it. 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to