Setting JVM options
843829Sep 17 2006 — edited Sep 19 2006Hi All,
Thank you for any reply on this topic.
I have a problem with JVM on my Virtual hosting where i have 470 megs of ram available in total.
when i type
java -version
in command line, i get
Cannot allocate ...memory
Cannot start the java virtual machine,.... blah blah
just 2 lines, you get the idea.
if i do java -Xmx32m -version
its ALL GOOD and well , writes me all my info about my 1.6.0 jvm
i can even do -Xmx380m
It just eats 460m instead .
The problem is, i have some tools (sun app serv.) that call java and jre related files e.g. keytool that throw same error Cannot start.... blah blah.
Now the question is :
How do i implicitly specify Xmx option for the jvm
so that it would ALWAYS be restricted?
i dont have access to the source that calls all these tools and pass an argument there , cant do that.
Any ideas?
Do you think i can write somehow a shell script , call it java and have arguments there?
How do i do that? since java has many arguments (LOTSSS)
HELP IS VERY APPRECIATED
Thank you