[
https://issues.apache.org/jira/browse/MASSEMBLY-781?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14640544#comment-14640544
]
Matthew Storer commented on MASSEMBLY-781:
------------------------------------------
So, I found a workaround for this. For the purpose of this example, the user
{{localuser}} is a local user account with a low user ID (e.g., 501), while
{{domainuser}} is a domain user with a high user ID (e.g. 1535409742).
Apparently, not only does the executing user need to have a low user ID, but so
apparently do all of the files that are processed during the assembly. Also,
for this example, the group {{sharedgroup}} is a group that is shared between
{{localuser}} and {{domainuser}}.
1. sudo su - localuser
2. cd <project directory>
3. find . -exec chown localuser {} \;
4. find . -exec chgrp sharedgroup {} \;
5. find . -type d -exec chmod 775 {} \;
6. find . -type f -exec chmod 664 {} \;
7. mvn clean
8. mvn package
Note that I include steps (4), (5), and (6) to ensure that all files are in the
same group, and that all group members have the same access to files and
folders as does the owner. Maybe overkill, but this ensures all files are on
the same page, and that when I exit out of the {{localuser}} shell, back into
the {{domainuser}} shell, that I'll still be able to access and process files
as before.
> Execution make-assembly fails: user id is too big
> -------------------------------------------------
>
> Key: MASSEMBLY-781
> URL: https://issues.apache.org/jira/browse/MASSEMBLY-781
> Project: Maven Assembly Plugin
> Issue Type: Bug
> Affects Versions: 2.5.5
> Environment: Mac OS X 10.10.4 (Yosemite)
> Maven 3.3.3
> Reporter: Matthew Storer
> Labels: assembly, build, maven
>
> maven-assembly-plugin fails make-assembly execution when the executing user's
> ID is "too big."
> While building a multi-module project ("X") from the command line using {{mvn
> package}}, all defined modules build just fine, but assembling X itself fails
> with the following error:
> {quote}
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Building X 1.0
> [INFO]
> ------------------------------------------------------------------------
> [INFO]
> [INFO] --- maven-assembly-plugin:2.5.5:single (make-assembly) @ x ---
> [INFO] Reading assembly descriptor: src/assembly/bin-assembly.xml
> [INFO] Building tar: /bb/x/target/x-1.0-bin.tar.gz
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Reactor Summary:
> [INFO]
> [INFO] Common ............................................. SUCCESS [ 3.180
> s]
> [INFO] A Service .......................................... SUCCESS [ 3.337
> s]
> [INFO] B Service .......................................... SUCCESS [ 2.186
> s]
> [INFO] A User Interface ................................... SUCCESS [ 1.331
> s]
> [INFO] B User Interface ................................... SUCCESS [ 1.380
> s]
> [INFO] X .................................................. FAILURE [ 0.346
> s]
> [INFO]
> ------------------------------------------------------------------------
> [INFO] BUILD FAILURE
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Total time: 19.722 s
> [INFO] Finished at: 2015-07-23T16:32:34-04:00
> [INFO] Final Memory: 53M/279M
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-assembly-plugin:2.5.5:single (make-assembly)
> on project X: Execution make-assembly of goal
> org.apache.maven.plugins:maven-assembly-plugin:2.5.5:single failed: user id
> '1535409742' is too big ( > 2097151 ). -> [Help 1]
> {quote}
> Snippet from X multi-module POM that configures maven-assembly-plugin:
> {quote}
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-assembly-plugin</artifactId>
> <version>2.5.5</version>
> <configuration>
> <descriptors>
> <descriptor>src/assembly/bin-assembly.xml</descriptor>
> <descriptor>src/assembly/src-assembly.xml</descriptor>
> </descriptors>
> </configuration>
> <executions>
> <execution>
> <id>make-assembly</id>
> <phase>package</phase>
> <goals>
> <goal>single</goal>
> </goals>
> </execution>
> </executions>
> </plugin>
> {quote}
> Error and stack trace:
> {quote}
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-assembly-plugin:2.5.5:single (make-assembly)
> on project X: Execution make-assembly of goal
> org.apache.maven.plugins:maven-assembly-plugin:2.5.5:single failed: user id
> '1535409742' is too big ( > 2097151 ). -> [Help 1]
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute
> goal org.apache.maven.plugins:maven-assembly-plugin:2.5.5:single
> (make-assembly) on project X: Execution make-assembly of goal
> org.apache.maven.plugins:maven-assembly-plugin:2.5.5:single failed: user id
> '1535409742' is too big ( > 2097151 ).
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:224)
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
> at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
> at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
> at
> org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
> at
> org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
> at org.apache.maven.cli.MavenCli.execute(MavenCli.java:862)
> at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:286)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:197)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
> Caused by: org.apache.maven.plugin.PluginExecutionException: Execution
> make-assembly of goal
> org.apache.maven.plugins:maven-assembly-plugin:2.5.5:single failed: user id
> '1535409742' is too big ( > 2097151 ).
> at
> org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:145)
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
> ... 20 more
> Caused by: java.lang.RuntimeException: user id '1535409742' is too big ( >
> 2097151 ).
> at
> org.codehaus.plexus.archiver.commonscompress.archivers.tar.TarArchiveOutputStream.failForBigNumber(TarArchiveOutputStream.java:635)
> at
> org.codehaus.plexus.archiver.commonscompress.archivers.tar.TarArchiveOutputStream.failForBigNumber(TarArchiveOutputStream.java:626)
> at
> org.codehaus.plexus.archiver.commonscompress.archivers.tar.TarArchiveOutputStream.failForBigNumbers(TarArchiveOutputStream.java:617)
> at
> org.codehaus.plexus.archiver.commonscompress.archivers.tar.TarArchiveOutputStream.putArchiveEntry(TarArchiveOutputStream.java:290)
> at
> org.codehaus.plexus.archiver.tar.TarArchiver.tarFile(TarArchiver.java:330)
> at
> org.codehaus.plexus.archiver.tar.TarArchiver.execute(TarArchiver.java:189)
> at
> org.codehaus.plexus.archiver.AbstractArchiver.createArchive(AbstractArchiver.java:1039)
> at
> org.apache.maven.plugin.assembly.archive.archiver.AssemblyProxyArchiver.createArchive(AssemblyProxyArchiver.java:437)
> at
> org.apache.maven.plugin.assembly.archive.DefaultAssemblyArchiver.createArchive(DefaultAssemblyArchiver.java:181)
> at
> org.apache.maven.plugin.assembly.mojos.AbstractAssemblyMojo.execute(AbstractAssemblyMojo.java:484)
> at
> org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
> ... 21 more
> {quote}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)