• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Ron McLeod
  • Rob Spoor
  • Tim Cooke
  • Junilu Lacar
  • Henry Wong
  • Liutauras Vilda
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Tim Holloway
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
  • Al Hobbs
  • Mikalai Zaikin
  • Piet Souris

JVM in Server or Client mode ?

Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I'm having problems te determine in what mode my JVM runs:

If you want to maximize performance on application servers that are rarely restarted you should run the HotSpot JVM in server mode. When the JVM is in server mode, it takes several times longer for an application server to get to a state where it can service a large number of requests. However, after it gets to that state, server mode can significantly out perform a comparable JVM running in client mode.

The HotSpot JVM running in server mode uses a high optimization compiler that optimizes and re-optimizes the Java code during the initial warm up stage. All of this optimization work takes awhile, but once the JVM is warmed up, application servers run significantly faster than they do in client mode on the same hardware.

The Solaris implementation of Java 5.0 examines your hardware and tries to select the correct JVM mode for your environment. If the JVM determines that it is running on a server level machine, the JVM automatically enables server mode. In Java 1.4.2 and earlier, the default mode is client mode and must use the -server flag on the JVM command line to enable server mode.

Because the JVM automatically enables server mode <http://java.sun.com/j2se/1.5.0/docs/guide/vm/server-class.html>; if your machine has at least 2 CPUs and 2 GB of memory, your JVMs probably default to server mode. However, you can use the -client and -server flags in the generic JVM arguments to force the virtual machine into either mode if the mode the JVM selects for you does not fit your environment.

I'm running with JVM Setting (Yeah i know, dinosaur software):

************ Start Display Current Environment ************
WebSphere Platform 5.0 [JDK 1.3.1 ${build.level}] [BASE cf100509.03] running with process name prodapp\prodapp\aeg04 and process id 26670
Host Operating System is SunOS, version 5.8
Java version = 1.3.1_08, Java Compiler = null, Java VM name = Java HotSpot(TM) Client VM

The last line says Client VM, does this mean the JVM is running in Client mode? Is there a command line to determine the mode in which the JVM is running?
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
    Bookmark Topic Watch Topic
  • New Topic