We are running on Debian 2.3 ("Woody") using a 2.2.19 kernel and Sun JDK
1.3.1 on a dual processor system.  We certainly do not see your problems.

First of all, the JVM should be hard-limited to consume a maximum of 64MB
unless you use the quasi-documented '-Xmx<size>' switch when invoking
Java.  In the case of jBoss, this means editing the 'run.sh' file.  If you
are not using this switch and memory is getting sucked up, you may have a
problem independent of the JVM.

If you are using the '-Xmx<size>' switch and you are allowing the JVM to
have a very large amount of memory, more than a few hundred megabytes,
then it will usually be a good idea to force garbage collection to even
out over time with the likewise quasi-documented '-Xincgc' switch.  This
would also involve editing the 'run.sh' file.

You seem to be testing uniprocessor mode on a separate machine, which
would be worthless if you are seeing some sort of problem with the kernel
or network stack.  For debugging purposes, you can force Linux to run in
uniprocessor mode with a multiprocessor kernel on an multiprocessor
machine by specifying the keyword 'nosmp' at the boot prompt.  If you are
using Lilo to boot, you can create an alternate boot block in the file
'/etc/lilo.conf' with the additional line 'append="nosmp"' like this:

image=/boot/vmlinuz-2.2.19
        label=Linux
        read-only
image=/boot/vmlinuz-2.2.19
        label=Linux-NOSMP
        read-only
        append="nosmp"

Alternatively, if you will not need this regularly, just stop the boot
with the 'Alt' key and enter "Linux nosmp" at the 'boot:' prompt.

It is also worth distinguishing between consumption of memory as opposed
to consumption of mere address space.  For example, here is jBoss running
on one of our SMP machines with the configuration described above, with
the JVM authorized to consume up to 480MB:

# ps u -C java | head -2
USER       PID %CPU %MEM   VSZ  RSS TTY      STAT START   TIME COMMAND
jboss    19954  0.0 23.5 794452 60796 ?      S    Jun21   0:36
/usr/local/share/jdk1.3.1/bin/i386/native_threads/java
-server -Xms8m -Xmx480m -Xincgc
-Djavax.xml.parsers.DocumentBuilderFactory=org.apache.crimson.jaxp.DocumentBuilderFactoryImpl
-Djavax.xml.parsers.SAXParserFactory=org.apache.crimson.jaxp.SAXParserFactoryImpl
-classpath :/lib/tools.jar:run.jar:../lib/crimson.jar org.jboss.Main
tomcat

The other main task here is PostgreSQL, using only a few megabytes:

test1:/home/mikebw# ps u -C postmaster | head -2
USER       PID %CPU %MEM   VSZ  RSS TTY      STAT START   TIME COMMAND
postgres 17804  0.0  0.6  8116 1632 ?        S    Jun21   0:00
/usr/lib/postgresql/bin/postmaster -D /var/lib/postgres/data

Although the JVM has allocated nearly 800MB of address space ("VSZ" or
"virtual size"), it is only really using 61MB ("RSS" or "resident size").  
This is evident from looking at the system memory picture, showing that we
have never started swapping on our machine which has 256MB RAM and a 1GB
swap file, and actually have half the RAM being used for low priority
tasks such as filesystem buffers:

# free
             total       used       free     shared    buffers     cached
Mem:        257640     221968      35672      56324     119220      24896
-/+ buffers/cache:      77852     179788
Swap:      1048560          0    1048560

In other words, a report that jBoss is using lots of memory opens the door
to more questions about your situation than answers.  I hope this gives
you some clue what to look for.

-- Mike


On 2001-06-25 at 22:37 -0400, Bill Burke wrote:

> Anybody having problems with SUN JDK 1.3 HotSpot server on RedHat 7.1(2.4
> kernel) Dual processor?  We're getting reproducable memory problems when
> invoking some code(mem usage jumps from 100M to 1.3Gig!) But can't reproduce
> the problem with -client or -classic.  Nor can we reproduce on RedHat 6.2
> server, client, or classic with a single processor machine.
> 
> TIA,
> 
> Bill



_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to