[Building Sakai] Out of Memory Error

Matthew Jones jonespm at umich.edu
Thu Feb 17 09:26:12 PST 2011


As mentioned in the install guide (Section 4.1) you have to set MAVEN_OPTS
to give it more memory. This is a common thing for java applications to
increase these settings "Xms512m -Xmx1024m -XX:PermSize=64m
-XX:MaxPermSize=128m".

https://confluence.sakaiproject.org/display/DOC/Install+Guide+-+Source+Install+(2.7)

If it *still* doesn't compile, just double these values ("Xms512m -Xmx2048m
-XX:PermSize=64m -XX:MaxPermSize=256m"). This would allow it to use up to
2GB of heap and have a permgen of 256. This would be fine if you have a 4GB
machine. Otherwise you'd have to scale back the heap, but increase the
MaxPermSize. Also I'd open up a command window to check to verify that
windows is exporting them correctly. (with the set command you'd see the
MAVEN_OPTS)

[image: MAVEN_OPTS.png]

As far as the other question *-Pcafe* enables the cafe profile. In the
pom.xml file in the root directory from whatever you check out (for example
trunk [1]) there are a number of profiles, such as cafe, experimental and
full. Cafe builds the least amount of tools. If you activate a profile, then
others are not activated. Doing a full sakai build has more tools and
requires more memory. You can read more about maven build profiles here. [2]

[1] https://source.sakaiproject.org/svn/sakai/trunk/
[2]
http://maven.apache.org/guides/introduction/introduction-to-profiles.html

-Matthew

On Thu, Feb 17, 2011 at 11:59 AM, Eric Millin <etmillin at gmail.com> wrote:

> Hello,
>
> I'm getting the pgem out of memory exception during compilation when I run
> "mvn clean install sakai:deploy".  I double checked my env variables and
> they're the same as the ones in installation guide.  I can, however, compile
> with the -Pcafe option.
>
> How can I fix this?  Also, what does the -Pcafe option do?  My background
> is .NET, so I feel rather out of my element atm.
>
> Thanks,
>
> Eric
>
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>
> TO UNSUBSCRIBE: send email to
> sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of
> "unsubscribe"
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20110217/0c056767/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: image/png
Size: 6939 bytes
Desc: not available
Url : http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20110217/0c056767/attachment.png 


More information about the sakai-dev mailing list