How to make 64-bit JVM the default on Solaris 10


 
Thread Tools Search this Thread
Operating Systems Solaris How to make 64-bit JVM the default on Solaris 10
# 1  
Old 06-10-2008
How to make 64-bit JVM the default on Solaris 10

Hi,

I am running my application on a 64-bit Solaris 10 machine. Currently, my application uses JRE 1.6 32-bit version. I am trying to make it work with JRE 1.6 64-bit version. I successfully installed 64-bit java using the instructions here: How do I install Java for my Solaris x64 computer ? - 1.5.0 and am able to invoke 64-bit java using either

Code:
$JAVA_HOME/bin/java -d64

or by using

Code:
$JAVA_HOME/bin/sparcv9/java

My application always invokes the java executable under $JAVA_HOME/bin. By default, this is invoking the java 32-bit version which I do not want. Of course, I could add the -d64 option to all calls to java in my application. However, I do not want to do that as java is being called from a number of scripts and some scripts are also being shared between multiple platforms.

How do I make the 64-bit java the default? I tried copying over the java executable from under $JAVA_HOME/bin/sparcv9 to $JAVA_HOME/bin. This seems to invokes the java 64-bit version correctly from within my application. However I do not know if this is the right thing to do or if it has adverse side effects.

Any help/inputs will be greatly appreciated!

Thank you so much.
# 2  
Old 06-11-2008
what about changing $JAVA_HOME from its current variable to something like

Code:
export JAVA_HOME=$JAVA_HOME/bin/sparc9

# 3  
Old 06-11-2008
Hi Pupp,

Thank you for your response! I considered your suggestion - but as I said, since some scripts are common across platforms, if possible, I would like to avoid Solaris specific changes to them.

Also the java executable for 64 bit is present directly under the sparcv9 directory. Usually the executables are supposed to be under $JAVA_HOME/bin, right?

Last edited by AKiwi; 06-11-2008 at 07:58 PM..
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Default JVM Memory

Hi , Whenever I am starting JVM it is getting started with Xms as 256MB, which is 1/64 of the Memory available and by default this should happen. But I want to change and start the every JVM with 128MB. Is there any way to do or I have to manually specify Xms tag while starting JVM. Thanks (1 Reply)
Discussion started by: Raj999
1 Replies

2. UNIX for Dummies Questions & Answers

JVM for Solaris and Linux

Hi I am using 2 servers Linux and Solaris both 32 bits. If I start the jvm using -Xmx2g, How much the actual heap space I will have condiering I give 128M to permGen on both Solaris and Linux. Thanks (0 Replies)
Discussion started by: Raj999
0 Replies

3. Solaris

JVM startup script in Solaris

Hi, I've installed dynatrace on a SunOS(5.10) & I need to update its agent path in JVM start up script. Where can I find or which script starts JVM? Some Details here : Java location : /<server location>/oracle/forms/FRHome_1/jdk/jre/bin Please help me in this. I did some research... (2 Replies)
Discussion started by: raj100
2 Replies

4. Solaris

How to increase jvm size for solaris 10 (sparc) operating system

Hi, I have solaris 10 (sparc) operating system machine on which I have installed supported weblogic 10.3. It was installed properly. As we know weblogic uses jvm to run and uses a part of jvm memory. But I am facing one problem in which JVM is getting crashed again and again resulting my... (2 Replies)
Discussion started by: neeraj.tati
2 Replies

5. Solaris

Solaris os 32 bit or 64 bit

:confused: how to find out wether my os is 32 bit or 64 bit. I am using Solaris 5.6. also i want to know the difference between 32 bit and 64bit os. any help will be much appreciated as i am in urgent need of this information (6 Replies)
Discussion started by: asalman.qazi
6 Replies

6. Solaris

Porting C++ 32-bit code on 64-bit Solaris

Hi, I am trying to convert 32-bit code to 64-bit. I have defined function int main() { int* l; size_t len1; fun(len1); return 0; } void fun(int* ptr) { cout<<"\nsizeof(ptr)"<<sizeof(ptr); } However while compiling getting error as : Error: Formal argument ptr... (2 Replies)
Discussion started by: amit_27
2 Replies

7. Solaris

Solaris 64-bit to 32-bit

I had previous implemented the following in my menu.lst to be able to get to 32-bit operations. # title Solaris 10 32-bit root (hd0,0,a) kernel /platform/i86pc/multiboot kernel/unix module /platform/i86pc/boot_archive </code> Now, it is not working as I get the following error : ... (0 Replies)
Discussion started by: praveenr
0 Replies

8. Solaris

32 / 64 bit OS in Solaris

Dear All, This is Viswanadhan, new to Sun Solaris domain. In Sun Solaris ( SPARC ) has 32 bit and 64 bit OS. While insallation of OS there no specific option for 32 / 64 bit OS .On which basis OS installs for 32 / 64 bit OS ? Regards, Viswanadhan. (1 Reply)
Discussion started by: viswanadhan
1 Replies

9. Solaris

64 bit solaris 9

How can I tell if im running a 64 bit version of solaris? (1 Reply)
Discussion started by: csaunders
1 Replies
Login or Register to Ask a Question