Solved

Java VM parameters on Solaris

Posted on 2010-11-16
11
707 Views
Last Modified: 2013-12-27
I would like to set permanent parameters for Java VM on Solaris, so I will don't need to set them for each NetBeans project. I have also Oracle 11g installed on this server and total RAM 24GB.
Please advice:
how to distribute RAM between Java and Oracle for the best productivity and
how to set  these -Xms and -Xmx parameters for Java.
Thank you
0
Comment
Question by:gbcbr
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
  • 2
11 Comments
 
LVL 16

Expert Comment

by:Joseph Gan
ID: 34148811
To set java parameters:

# which java
this will show the path for current java, eg. /usr/bin/java, normally this is a symbolic link.

To cleanup old java, just remove this link.

Then, create a symbolic link to your new java command where ever is:

# ln -s {new java path} /usr/bin/java (example only, depend on "which java" command output).
0
 

Author Comment

by:gbcbr
ID: 34148879
you copy answer from @arnold@ to my previous question by mistake?
0
 
LVL 16

Expert Comment

by:Joseph Gan
ID: 34149265
That was my answer even though I did not ge any pionts.
0
The Ultimate Checklist to Optimize Your Website

Websites are getting bigger and complicated by the day. Video, images, custom fonts are all great for showcasing your product/service. But the price to pay in terms of reduced page load times and ultimately, decreased sales, can lead to some difficult decisions about what to cut.

 

Author Comment

by:gbcbr
ID: 34149310
I'm very sorry, I'll give you points on this question.
But please answer on this question, not for previous.
Sorry again.
0
 
LVL 16

Expert Comment

by:Joseph Gan
ID: 34149427
Don't know can set RAM to Java. One way can allocate RAM to Oracle is to set them in/etc/system file as recommemded by Oracle doc.
eg.
set shmsys:shminfo_shmmax=#######
0
 

Author Comment

by:gbcbr
ID: 34182604
Maybe experts for Solaris can help?
0
 
LVL 9

Expert Comment

by:fcontrepois
ID: 34222163
Oracle and java handle the memory on their own.

Oracle 11 just requires an amount of memory and it will manage all the others settings.

A dev database with less than 100'000 rows per table can be handled in a 2-4 GB ram

Java requires a little more tuning, depending on the application it need to manage and the version. Generally starting setting -Xmx will be enough

If you start the java app from command line just add -Xmx1g
Es. java -Xmx1g main
For application servers and other complex java app there should be a file to set the java executable parameters

To have more info answer the following questions:
do you have a single oracle instance or multiple ?
what are you trying to run on java?
0
 

Author Comment

by:gbcbr
ID: 34222687
I have single instance, but the question is that when I try to set -Xmx and -Xms on Solaris version of Netbeans it doesn't accept any arrangements, and I have to leave it empty.
I want to set for Java 30% - 8g, but I can't, something block this arrangement.
0
 
LVL 9

Accepted Solution

by:
fcontrepois earned 500 total points
ID: 34223588
http://performance.netbeans.org/howto/jvmswitches/

Looks like you can Use ./netbeans -J-Xmx256m
0
 

Author Closing Comment

by:gbcbr
ID: 34224451
thank you for the good link
0

Featured Post

The Ultimate Checklist to Optimize Your Website

Websites are getting bigger and complicated by the day. Video, images, custom fonts are all great for showcasing your product/service. But the price to pay in terms of reduced page load times and ultimately, decreased sales, can lead to some difficult decisions about what to cut.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Are you developing a Java application and want to create Excel Spreadsheets? You have come to the right place, this article will describe how you can create Excel Spreadsheets from a Java Application. For the purposes of this article, I will be u…
Introduction Java can be integrated with native programs using an interface called JNI(Java Native Interface). Native programs are programs which can directly run on the processor. JNI is simply a naming and calling convention so that the JVM (Java…
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question