Performance issue in linux

we installed jive_messenger_2005-03-15.tar.gz in RH9,machine’'s CPU P3 1G,Memory is 512M,

Server setting page display:

JVM Version:1.5.0 Sun Microsystems Inc. – Java HotSpot™ Client VM

Java Memory:13.73 MB of 63.56 MB (21.6%) used

it’'s 10 user online.

now we have two problem:

1,whether Java server VM have much faster for applications in jive.if it is much faster why do it change server VM in linux?

2,whether java memory is small in 64M,we want to current online in 200~300 user.why do we add java memory in linux?

just other question,how many online user can charge in single jive server?what machine necessary it it?

thanks.

From what I have seen the Sun JVM usually defaults to client mode. This can be verified by typing “java -vesrion” in a terminal window. It is better to to run Jive Messenger using the server mode. You can do this by editing the messenger.sh and adding the server argument as below. When you run in server mode you automatically get more memory allocated to the JVM, I think 512Mb might be adequate depending on your requirements, in any case I don’'t think you can really have less. You can add the memory arguments below and see how you get on.

nohup “$app_java_home/bin/java”+ -Xms248M -Xmx450M -server+ -Dinstall4j.jvmDir="$app_java_home" -Din

stall4j.appDir="$app_home" -Dexe4j.moduleName="$prg_dir/$prg" $INSTALL4J_ADD_VM_PARAMS -classpath “$local_classpath” com.install4j.runtime.Launcher start org.

jivesoftware.messenger.starter.ServerStarter false false "$prg_dir/…/logs/stder

ror.log" “$prg_dir/…/logs/stdoutt.log” true true false “” true true 0 0 “” 20

20 “Arial” “0,0,0” 8 500 “version 2.1.1” 20 40 “Arial” “0,0,0” 8 500 -1 -Dmessen

gerHome=$app_home -Dmessenger.lib.dir=$app_home/lib “$@” &

++

could you give more details on how to run java in server mode? I’'m running Jive with jive-messengerd daemon at bootup. Do i have to edit messenger.sh? Maybe only /bin/messenger ? Or maybe there is an option to turn server mode in java? We are using this machine only for Jive, so Java could run in server mode all the time.

The messengerd script simply calls jive_messenger/bin/messenger so the additional arguments added to messenger script still apply.

The arguments JVM arguments -Xms -Xmx are to set the min/max heap size and the argument -server tells the jvm to run in server mode.

See my previous post to see where to put it in messenger script

Conor.

well, there is -server parameter in messenger script already, w/o min/max params. Hm… this what i get with “java -server”:

java version “1.5.0_01”

Java™ 2 Runtime Environment, Standard Edition (build 1.5.0_01-b08)

Java HotSpot™ Client VM (build 1.5.0_01-b08, mixed mode, sharing)

so it runs in client or what mode?

Seems like your default is client mode. On my solaris box the default is server mode as below, which happened at install time, I have seen other solaris installations where the default is client mode. The only way I know how to run in server mode is to add the -server switch.

bash-2.05# java -version

java version “1.5.0_01”

Java™ 2 Runtime Environment, Standard Edition (build 1.5.0_01-b08)

Java HotSpot™ Server VM (build 1.5.0_01-b08, mixed mode)

You can verify the client and server versions as follows.

bash-2.05# java -client -version

java version “1.5.0_01”

Java™ 2 Runtime Environment, Standard Edition (build 1.5.0_01-b08)

Java HotSpot™ Client VM (build 1.5.0_01-b08, mixed mode, sharing)

bash-2.05# java -server -version

java version “1.5.0_01”

Java™ 2 Runtime Environment, Standard Edition (build 1.5.0_01-b08)

Java HotSpot™ Server VM (build 1.5.0_01-b08, mixed mode)

If you are running on windows the default is certainly client mode.

Conor.

well, there is -server parameter in messenger script

already, w/o min/max params. Hm… this what i get

with “java -server”:

java version “1.5.0_01”

Java™ 2 Runtime Environment, Standard Edition

(build 1.5.0_01-b08)

Java HotSpot™ Client VM (build 1.5.0_01-b08, mixed

mode, sharing)

so it runs in client or what mode?

This probably means that you don’'t have the Hotspot server VM installed. Be sure to download the full JDK from java.sun.com. If you install that, you should have the server VM (and on Linux, the default should be the server VM).

-Matt

i’‘m using Archlinux. And i have installed only j2re package. there is also j2sdk package. But i thought it’'s only for developers. So i have to install this package too?

thanks for Conor ,my problem already resolved in your suggestion.i added it to last line in messenger.sh .

messenger_exec_command=“exec “$JAVACMD”* -Xms248M -Xmx450M -server* $MESSENGER_OPTS -classpath “$LOCALCLASSPATH” -jar “$MESSENGER_LIB”/startup.jar”

hey matt,i used linux RH7.2,the default was the client VM.i necessary add ‘’-server’’ to messenger.sh that it can run in server VM.

another question want to discuss,When jive run in server mode ,default java memory is 64M,i am not add "-Xms248M -Xmx450M " to mesenger.sh,whether server can automatically increase more memory allocated to JVM.

RedHat 7.2 is very old, and we’'d definitely recommend upgrading to at least Red Hat 9 (but preferably something even newer).

another question want to discuss,When jive run in

server mode ,default java memory is 64M,i am not add

"-Xms248M -Xmx450M " to mesenger.sh,whether server

can automatically increase more memory allocated to

JVM.

The server VM will automatically use more memory if it thinks it can. For example, on a machine with 2GB of RAM it will use 512 MB for the heap. Maybe you don’'t have a lot of RAM in your server?

Regards,

Matt

thanks matt ,my machine RAM is 512M , there is have a lot of application on it,it maybe not free memory to JAVA VM.

i try it in RH9 (Shrike),Java VM can’‘t automatic to adopt server VM,i think a part of linux can’‘t automatic find java server VM.i have seen it have “-server” option in messenger.bat,so i suggest to add ‘’-server’’ option to messenger.sh

so, as i’'m going to upgrade JM to 2.2.1 and java to 1.5.0_04 today, and the Server Vm was mentioned in “CPU load” thread, i have remembered this topic. So waht do i have to install to be able to run it in Server Mode?

j2sdk?

And do i have to turn it on somehow or it would switch to Serve mode automaticly upon restart?

that’'s what i have:

$ java -version -client

java version “1.5.0_03”

Java™ 2 Runtime Environment, Standard Edition (build 1.5.0_03-b07)

Java HotSpot™ Client VM (build 1.5.0_03-b07, mixed mode, sharing)

$ java -version -server

java version “1.5.0_03”

Java™ 2 Runtime Environment, Standard Edition (build 1.5.0_03-b07)

Java HotSpot™ Server VM (build 1.5.0_03-b07, mixed mode)

so i already have Server VM?

hi all,

i’'ve tried to read this

“nohup “$app_java_home/bin/java” -Xms248M -Xmx450M -server -Dinstall4j.jvmDir=”$app_java_home" -Din

stall4j.appDir="$app_home" -Dexe4j.moduleName="$prg_dir/$prg" $INSTALL4J_ADD_VM_PARAMS -classpath “$local_classpath” com.install4j.runtime.Launcher start org.

jivesoftware.messenger.starter.ServerStarter false false "$prg_dir/…/logs/stder

ror.log" “$prg_dir/…/logs/stdoutt.log” true true false “” true true 0 0 “” 20

20 “Arial” “0,0,0” 8 500 “version 2.1.1” 20 40 “Arial” “0,0,0” 8 500 -1 -Dmessen

gerHome=$app_home -Dmessenger.lib.dir=$app_home/lib “$@” &"

but don’‘t understand nothing. i want to increase my java memory too, but don’‘t know how. now, it’'s 64MB, i want at least 100. how do i do that? i have JDK installed too, do i need to run it to make server? how does this work? now, as you can see, is client…

root@sepsrv123:~# java -version

java version “1.5.0_04”

Java™ 2 Runtime Environment, Standard Edition (build 1.5.0_04-b05)

Java HotSpot™ Client VM (build 1.5.0_04-b05, mixed mode, sharing)

root@sepsrv123:~#

regards,

Rodrigo.