File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Memory settings

 
Jes Sie
Ranch Hand
Posts: 188
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I've got this machine here running JBoss that has got about 3 GB RAM. Now, the memory doesn't seem to used agressively.

Currently, what I've got is -Xms512m -Xmx1024m

Pls let me now the exact settings so that I could increase it further, please.

PS: I was told the max the JVM could take is 2 GB.
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24204
34
Chrome Eclipse IDE Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There two flags each give a number in megabytes. You can increase them to use more memory. The mx is the total Java heap size, which can go up to about 1850MB on many platforms, while ms is the initial heap size. They can both be the same number or you can use a range as you are here.
 
Joe Ess
Bartender
Posts: 9214
9
Linux Mac OS X Windows
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You are complaining because the JVM isn't using enough memory? I think that's a first. Most people complain that it uses too much.
The JVM is tuned to make the best use of the memory allocated and request more when necessary. You can crank up the values of -Xms and -Xmx, but if your application doesn't need that memory you are wasting valuable resources.
Depending on your JVM version, you may be able to use a -server switch on the command line to tell it to tune for long-running server applications or use -client to tune for short-run GUI intensive programs. This selection is made automatically in JDK 1.5.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic