[
https://issues.apache.org/jira/browse/KARAF-1019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13152695#comment-13152695
]
Jean-Baptiste Onofré commented on KARAF-1019:
---------------------------------------------
Tomcat and Karaf are not the same at all, especially because Tomcat is not OSGi
powered, and so don't use an OSGi framework.
In Tomcat, the memory options are exactly done in the same way as Karaf. Using
CATALINA_OPTS is not a good practice, the JAVA_OPTS should be used.
As in Karaf, it doesn't affect the others Java programs as the JAVA_OPTS is a
local variable in the catalina.sh, as in the karaf.sh.
I'm agree to remove the MaxPermSize (and let the user eventually override it),
but not the Xms/Xmx.
> Set java memory options only when required
> ------------------------------------------
>
> Key: KARAF-1019
> URL: https://issues.apache.org/jira/browse/KARAF-1019
> Project: Karaf
> Issue Type: Improvement
> Components: karaf-core
> Affects Versions: 2.2.4
> Environment: Windows 2003 @ amd64
> jdk1.6.0_29 x64
> Reporter: Alexey Markevich
> Assignee: Jean-Baptiste Onofré
> Fix For: 2.2.5, 3.0.0
>
> Attachments: karaf, karaf.bat, karaf.bat, set_java
> memory_options_only_when_required.patch, set_java
> memory_options_only_when_required_unix.patch
>
>
> Related to https://issues.apache.org/jira/browse/KARAF-818
> Using my x64 environment I got PermGen space error.
> Sure - I can change JAVA_MAX_MEM, JAVA_PERM_MEM, JAVA_MIN_MEM,
> JAVA_MAX_PERM_MEM variables.
> But I found that without memory settings [1] my scenario works fine.
> Is it possible to set java memory options only if variables are present?
> 1. set DEFAULT_JAVA_OPTS=-server -Dderby.system.home="%KARAF_DATA%\derby"
> -Dderby.storage.fileSyncTransactionLog=true -Dcom.sun.management.jmxremote
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira