The memory arguments don't get injected randomly - so I would track down where the values 384m and 192m are set and work backwards.
If possible can you post your job config.xml and the full output of the build? /James On Friday, 10 April 2015 16:56:59 UTC+1, Keith O'Brien wrote: > > Hi all, > > I have a Maven build configured on our Jenkins CI (1.608) server and the > following MAVEN_OPTS configured in Build section of the job and have > m2release plugin v0.14.0 installed. > > -XX:MaxPermSize=512m -Xmx2048m > > > When running a regular build (clean install) everything works as expected, > however if I try running a Maven Release Build I'm getting the dreaded > "java.lang.OutOfMemoryError: > PermGen space" error. So I have tried setting up my Maven project as best > possible, setting JVM args on the appropriate plugins etc, but the root of > the problem seem to be that the Maven process being executed by the > m2release plugin isn't picking up either the Global MAVEN_OPTS variable I > have added or the values above from the job configuration, instead from the > box itself I can see that the following command is being run: > > /usr/lib/jvm/jdk1.7.0_65/bin/java > -Dmaven.repo.local=/var/jenkins/.m2/repository > -Xmx384m -XX:MaxPermSize=192m -classpath /usr/local/maven/boot/plexus- > classworlds-2.5.1.jar -Dclassworlds.conf=/usr/local/maven/bin/m2.conf - > Dmaven.home=/usr/local/maven org.codehaus.plexus.classworlds.launcher. > Launcher -B -D maven.repo.local=/var/jenkins/.m2/repository -s /tmp/ > release-settings2394907685413605920.xml -D java7.path=/usr/lib/jvm/jdk1. > 7.0_65/bin/java -D maven.release=true -P artifactory clean verify > > .. from this the MaxPermSize is being set to 192m and not the 512m I have > configured everywhere else. To prove that this is the cause of my problem > I have changed the values in this command and run it directly on the > Jenkins server with a successful result. > > > Can anyone tell me how I can change the JVM args on this forked maven > build? > > Thanks, > > Keith. > > -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/1a3000be-3224-46a7-b24c-ce8e95b9b6b5%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
