Java on HP-UX 11i Frequently Asked Questions HP Part Number: 5900-1299 Published: November 2010 Edition: 1.
© Copyright 2010 Hewlett-Packard Development Company, L.P. Legal Notices Reproduction, adaptation, or translation without prior written permission is prohibited, except as allowed under the copyright laws. Java™ and all Java based trademarks and logos are trademarks or registered trademarks of Oracle America and/or its affiliates in the United States and other countries.
Table of Contents Product questions.................................................................................................................5 Q: How do I tell what version of Java I'm running?.......................................................5 Q: Can I run multiple versions of Java at the same time?...............................................5 Q: Where can I find more information about Java performance tuning on HP-UX 11i?......................................................................
records in excess of 100000. What probable location should I start looking at for debugging? ...................................................................................................................10 Q: Are gdb's capabilities for debugging Java documented anywhere? .......................11 Q: I have set java -Djava.rmi.server.logCalls=true, and also the system property java.rmi.serever.logCalls to true, and I do not see the log files on the machine. ..............................................
Product questions Q: How do I tell what version of Java I'm running? A: Assuming the directory where Java is installed is in your PATH variable, run java -version Alternatively you can use the full path name. If you have installed Java in the default location, the paths are as follows: Java 1.4: Java 5.0: Java 6.0: /opt/java1.5 /opt/java1.5 /opt/java6 The java -version command also gives you the specific release information, such as the build date and all the minor version information.
Q: Where can I find more information about Java performance tuning on HP-UX 11i? A: Please see our Java performance tuning website, which has a collection of tips, tools, and techniques for helping you improve performance. Also, you can refer to the following for additional performance tuning information: • Java Troubleshooting Guide for HP-UX Systems (on the Business Support Center at http://www.hp.
Q: How do I tell the latest version of Java available? A: See the HP-UX 11i Java home page for the most current releases available for download. Or go to the Software Depot Java download page for a list of all available Java product releases. Q: Where can I find additional FAQs about Java? A: You can try the following websites: www.jguru.com/faq/ and Oracle's Source for Developers website at http://www.oracle.com/technetwork/java/index.html. Q: What is HP's support-life policy for Java 1.4.
Q: How can I exclude a method from HotSpot compilation? A: Create a file in the home directory where the Java application will be started, name it .
Q: Is there a way to know the value of maximum stack size consumed? A: There isn't a straightforward way to do this, however, there is a way using HP OpenView GlancePlus. GlancePlus has a function that reports the memory utilization for the memory mapped regions. First, select the process you want to monitor, then select Process Memory Regions. Isolate the regions allocated for the individual threads by looking for regions whose VSS value matches the value currently defined for -Xss.
HP performs the same functions on the Java reference implementations that we receive from Oracle. Consequently, HP and other licensees have the opportunity to release their products at the same time as the Solaris product from Oracle. In some cases HP has delivered the product before IBM and before Oracle's comparable Solaris product and with higher performance (measured by the industry standard SPECjvm98 benchmark) than either Oracle or IBM.
Q: Are gdb's capabilities for debugging Java documented anywhere? A: You could start with the "Debugging a native JNI library with Java™ 2 HotSpot VM under gdb" section of the HP-UX Java Programmer's Guide. Also, stack unwinding in the Java code is available, so you can do a backtrace through the native code stack frames, interpreter code stack frames, and runtime compiled code stack frames. To use this new feature, you will need the latest version of gdb available from www.hp.com/ go/wdb, plus the 1.3.1.
vm_args.minHeapSize = 32000000; vm_args.maxHeapSize = 96000000; vm_args.nativeStatckSize = 1000000; vm_args.javaStackSize = 1000000; vm_args.disableJIT = JNI_TRUE; if (ret !=0) printf("failed to GetDefaultJavaVMInitArgs/n"); //Note: If you have not set and exported the environment variable //CLASSPATH you may also need to add this: vm_args.classpath =.:/opt/java/lib/classes.zip:./ssjcls01.
Q: I have a program with many threads, and I suspect there is some lock contention between the threads which is slowing down the performance. Can you recommend a tool which will help me identify potential lock contentions? A: Please go to our Java performance tuning website, which contains much useful information on helping you improve the performance of your Java-based applications. In addition, if you are using the SDK 1.3.1.