Flex 3 Heap Size
I've changed every config and ini file suggested to increase
Flex's heap size. I've enabled the heap monitor on the console and
it never increases over 64M. On the simplest code examples I exceed
the heap limits and need to restart.
Anyone have any other suggestions to increase the heap?
Flex3 version 3.0.194161
Eclipse Platform 3.3.1
BUMP - I was really hoping someone could respond to this
post, as I'm interested in hearing possible solutions.
Similar Messages
-
The initial heap size must be less than or equal to the maximum heap size.
All,
Please help!!
I have tested my Application Client Project in WSAD on my pc and it works fine.
I have 1gb RAM on my pc. When I deploy the same app on another xp pc(same as mine but 512mb RAM) I get a heap size error. Here is the exact error:
Incompatible initial and maximum heap sizes specified:
initial size: 268435456 bytes, maximum heap size: 267380736 bytes
The initial heap size must be less than or equal to the maximum heap size.
The default initial and maximum heap sizes are 4194304 and 267380736 bytes.
Usage: java [-options] class [args...]
(to execute a class)
or java -jar [-options] jarfile [args...]
(to execute a jar file)
where options include:
-cp -classpath <directories and zip/jar files separated by ;>
set search path for application classes and resources
-D<name>=<value>
set a system property
-verbose[:class|gc|jni]
enable verbose output
-version print product version
-showversion print product version and continue
-? -help print this help message
-X print help on non-standard options
Could not create the Java virtual machine.
Press any key to continue . . .
Here is the batch file that runs my app:
@echo off
SET appClientEar=C:\corp\apps\mts\jars\MTSClientEAR.ear
set JVM_ARGS=-Xms256M -Xmx256M
set CLIENT_PROPS=C:\corp\apps\mts\jars\medicalclient.properties
set APP_ARGS=
call C:\bnsf\IBM\WebSphere\AppClient\bin\launchClientBNSF.bat "%JVM_ARGS%" %appClientEar% "-CCpropfile=%CLIENT_PROPS%" %APP_ARGS%
@pause
I have changed the value of Xms and Xmx of JVM_ARGS to different size but I sitll get error. Anyone knows what the problem is. Thanks..Don't know why, but the "maximum heap size: 267380736 bytes" value is just slightly less than 256*1024*1024, wheras the reported initial size is equal to that.
Try setting the initial value to 255MB. -
What is the best way to verify default heap size in Java
Hi All,
What is the best way to verify default heap size in Java ? does it vary over JVM to JVM . I was reading this article http://javarevisited.blogspot.sg/2011/05/java-heap-space-memory-size-jvm.html , and it says default size is 128 MB but When I run following code :
public static void main(String args[]) {
int MB = 1024*1024;
System.out.println(Runtime.getRuntime().totalMemory()/MB);
It print "870" i.e. 870 MB.
I am bit confused, what is the best way to verify default heap size in any JVM ?
Edited by: 938864 on Jun 5, 2012 11:16 PM938864 wrote:
Hi Kayaman,
Sorry but I don't agree with you on verification part, Why not I can verify it ? to me default means value when I don't specify -Xms and -Xmx and by the way I was testing that program on 32 bit JRE 1.6 on Windows. I am also curious significant difference between 128MB and 870MB I saw, do you see anything obviously wrong ?That spec is outdated. Since Java 6 update 18 (Sun/Oracle implementation) the default maximum heap space is calculated based on total memory availability, but never more than 1GB on 32 bits JVMs / client VMs. On a 64 bits server VM the default can go as high as 32gb.
The best way to verify ANYTHING is to address multiple sources of information and especially those produced by the source, not some page you find on the big bad internet. Even wikipedia is a whole lot better than any random internet site IMO. That's common sense, I can't believe you put much thought into it that you have to ask in a forum. -
Any way to increase the default Heap size for all Java VMs in Solaris 8
Hello,
I have a java product that deals with large databases under Solaris 8. It is a jar file, started by a cron job every night. Some nights it will fail because it runs out of Heap memory depending on the amount of records it has to deal with. I know that I could increase the java VM heap size with "java -jar -mx YY JARFILE" command but I have other java products that are showing the same behavior, and I would like to correct them all in one shot if possible.
What I would like to do is find a system or configuration parameter that forces all Java VMs to use a larger MAX Heap size than the default 16M specified in the Man page for Java. Is there a way to accomplish that?
TIA
MaizoYou could always download the source and modify it.
-
Massive memory hemorrhage; heap size to go from about 64mb, to 1.3gb usage
**[SOLVED]**
Note: I posted this on stackoverflow as well, but a solution was not found.
Here's the problem:
[1] http://i.stack.imgur.com/sqqtS.png
As you can see, the memory usage balloons out of control! I've had to add arguments to the JVM to increase the heapsize just to avoid out of memory errors while I figure out what's going on. Not good!
##Basic Application Summary (for context)
This application is (eventually) going to be used for basic on screen CV and template matching type things for automation purposes. I want to achieve as high of a frame rate as possible for watching the screen, and handle all of the processing via a series of separate consumer threads.
I quickly found out that the stock Robot class is really terrible speed wise, so I opened up the source, took out all of the duplicated effort and wasted overhead, and rebuilt it as my own class called FastRobot.
##The Class' Code:
public class FastRobot {
private Rectangle screenRect;
private GraphicsDevice screen;
private final Toolkit toolkit;
private final Robot elRoboto;
private final RobotPeer peer;
private final Point gdloc;
private final DirectColorModel screenCapCM;
private final int[] bandmasks;
public FastRobot() throws HeadlessException, AWTException {
this.screenRect = new Rectangle(Toolkit.getDefaultToolkit().getScreenSize());
this.screen = GraphicsEnvironment.getLocalGraphicsEnvironment().getDefaultScreenDevice();
toolkit = Toolkit.getDefaultToolkit();
elRoboto = new Robot();
peer = ((ComponentFactory)toolkit).createRobot(elRoboto, screen);
gdloc = screen.getDefaultConfiguration().getBounds().getLocation();
this.screenRect.translate(gdloc.x, gdloc.y);
screenCapCM = new DirectColorModel(24,
/* red mask */ 0x00FF0000,
/* green mask */ 0x0000FF00,
/* blue mask */ 0x000000FF);
bandmasks = new int[3];
bandmasks[0] = screenCapCM.getRedMask();
bandmasks[1] = screenCapCM.getGreenMask();
bandmasks[2] = screenCapCM.getBlueMask();
Toolkit.getDefaultToolkit().sync();
public void autoResetGraphicsEnv() {
this.screenRect = new Rectangle(Toolkit.getDefaultToolkit().getScreenSize());
this.screen = GraphicsEnvironment.getLocalGraphicsEnvironment().getDefaultScreenDevice();
public void manuallySetGraphicsEnv(Rectangle screenRect, GraphicsDevice screen) {
this.screenRect = screenRect;
this.screen = screen;
public BufferedImage createBufferedScreenCapture(int pixels[]) throws HeadlessException, AWTException {
// BufferedImage image;
DataBufferInt buffer;
WritableRaster raster;
pixels = peer.getRGBPixels(screenRect);
buffer = new DataBufferInt(pixels, pixels.length);
raster = Raster.createPackedRaster(buffer, screenRect.width, screenRect.height, screenRect.width, bandmasks, null);
return new BufferedImage(screenCapCM, raster, false, null);
public int[] createArrayScreenCapture() throws HeadlessException, AWTException {
return peer.getRGBPixels(screenRect);
public WritableRaster createRasterScreenCapture(int pixels[]) throws HeadlessException, AWTException {
// BufferedImage image;
DataBufferInt buffer;
WritableRaster raster;
pixels = peer.getRGBPixels(screenRect);
buffer = new DataBufferInt(pixels, pixels.length);
raster = Raster.createPackedRaster(buffer, screenRect.width, screenRect.height, screenRect.width, bandmasks, null);
// SunWritableRaster.makeTrackable(buffer);
return raster;
}In essence, all I've changed from the original is moving many of the allocations from function bodies, and set them as attributes of the class so they're not called every time. Doing this actually had a significant affect on frame rate. Even on my severely under powered laptop, it went from ~4 fps with the stock Robot class, to ~30fps with my FastRobot class.
##First Test:
When I started outofmemory errors in my main program, I set up this very simple test to keep an eye on the FastRobot. Note: this is the code which produced the heap profile above.
public class TestFBot {
public static void main(String[] args) {
try {
FastRobot fbot = new FastRobot();
double startTime = System.currentTimeMillis();
for (int i=0; i < 1000; i++)
fbot.createArrayScreenCapture();
System.out.println("Time taken: " + (System.currentTimeMillis() - startTime)/1000.);
} catch (AWTException e) {
e.printStackTrace();
}##Examined:
It doesn't do this every time, which is really strange (and frustrating!). In fact, it rarely does it at all with the above code. However, the memory issue becomes easily reproducible if I have multiple for loops back to back.
#Test 2
public class TestFBot {
public static void main(String[] args) {
try {
FastRobot fbot = new FastRobot();
double startTime = System.currentTimeMillis();
for (int i=0; i < 1000; i++)
fbot.createArrayScreenCapture();
System.out.println("Time taken: " + (System.currentTimeMillis() - startTime)/1000.);
startTime = System.currentTimeMillis();
for (int i=0; i < 500; i++)
fbot.createArrayScreenCapture();
System.out.println("Time taken: " + (System.currentTimeMillis() - startTime)/1000.);
startTime = System.currentTimeMillis();
for (int i=0; i < 200; i++)
fbot.createArrayScreenCapture();
System.out.println("Time taken: " + (System.currentTimeMillis() - startTime)/1000.);
startTime = System.currentTimeMillis();
for (int i=0; i < 1500; i++)
fbot.createArrayScreenCapture();
System.out.println("Time taken: " + (System.currentTimeMillis() - startTime)/1000.);
} catch (AWTException e) {
e.printStackTrace();
}##Examined
The out of control heap is now reproducible I'd say about 80% of the time. I've looked all though the profiler, and the thing of most note (I think) is that the garbage collector seemingly stops right as the fourth and final loop begins.
The output form the above code gave the following times:
Time taken: 24.282 //Loop1
Time taken: 11.294 //Loop2
Time taken: 7.1 //Loop3
Time taken: 70.739 //Loop4
Now, if you sum the first three loops, it adds up to 42.676, which suspiciously corresponds to the exact time that the garbage collector stops, and the memory spikes.
[2] http://i.stack.imgur.com/fSTOs.png
Now, this is my first rodeo with profiling, not to mention the first time I've ever even thought about garbage collection -- it was always something that just kind of worked magically in the background -- so, I'm unsure what, if anything, I've found out.
##Additional Profile Information
[3] http://i.stack.imgur.com/ENocy.png
Augusto suggested looking at the memory profile. There are 1500+ `int[]` that are listed as "unreachable, but not yet collected." These are surely the `int[]` arrays that the `peer.getRGBPixels()` creates, but for some reason they're not being destroyed. This additional info, unfortunately, only adds to my confusion, as I'm not sure why the GC wouldn't be collecting them
##Profile using small heap argument -Xmx256m:
At irreputable and Hot Licks suggestion I set the max heap size to something significantly smaller. While this does prevent it from making the 1gb jump in memory usage, it still doesn't explain why the program is ballooning to its max heap size upon entering the 4th iteration.
[4] http://i.stack.imgur.com/bR3NP.png
As you can see, the exact issue still exists, it's just been made smaller. ;) The issue with this solution is that the program, for some reason, is still eating through all of the memory it can -- there is also a marked change in fps performance from the first the iterations, which consume very little memory, and the final iteration, which consumes as much memory as it can.
The question remains why is it ballooning at all?
##Results after hitting "Force Garbage Collection" button:
At jtahlborn's suggestion, I hit the Force Garbage Collection button. It worked beautifully. It goes from 1gb of memory usage, down to the basline of 60mb or so.
[5] http://i.stack.imgur.com/x4282.png
So, this seems to be the cure. The question now is, how do I pro grammatically force the GC to do this?
##Results after adding local Peer to function's scope:
At David Waters suggestion, I modified the `createArrayCapture()` function so that it holds a local `Peer` object.
Unfortunately no change in the memory usage pattern.
[6] http://i.stack.imgur.com/Ky5vb.png
Still gets huge on the 3rd or 4th iteration.
#Memory Pool Analysis:
###ScreenShots from the different memory pools
##All pools:
[7] http://i.stack.imgur.com/nXXeo.png
##Eden Pool:
[8] http://i.stack.imgur.com/R4ZHG.png
##Old Gen:
[9] http://i.stack.imgur.com/gmfe2.png
Just about all of the memory usage seems to fall in this pool.
Note: PS Survivor Space had (apparently) 0 usage
##I'm left with several questions:
(a) does the Garbage Profiler graph mean what I think it means? Or am I confusing correlation with causation? As I said, I'm in an unknown area with these issues.
(b) If it is the garbage collector... what do I do about it..? Why is it stopping altogether, and then running at a reduced rate for the remainder of the program?
(c) How do I fix this?
Does anyone have any idea what's going on here?
[1]: http://i.stack.imgur.com/sqqtS.png
[2]: http://i.stack.imgur.com/fSTOs.png
[3]: http://i.stack.imgur.com/ENocy.png
[4]: http://i.stack.imgur.com/bR3NP.png
[5]: http://i.stack.imgur.com/x4282.png
[6]: http://i.stack.imgur.com/Ky5vb.png
[7]: http://i.stack.imgur.com/nXXeo.png
[8]: http://i.stack.imgur.com/R4ZHG.png
[9]: http://i.stack.imgur.com/gmfe2.png
Edited by: 991051 on Feb 28, 2013 11:30 AM
Edited by: 991051 on Feb 28, 2013 11:35 AM
Edited by: 991051 on Feb 28, 2013 11:36 AM
Edited by: 991051 on Mar 1, 2013 9:44 AMSO came through.
Turns out this issue was directly related to the garbage collector. The default one, for whatever reason, would get behind on its collection at points, and thus the memory would balloon out of control, which then, once allocated, became the new normal for the GC to operate at.
Manually setting the GC to ConcurrentMarkSweep solved this issue completely. After numerous tests, I have been unable to reproduce the memory issue. The garbage collector does an excellent job of keeping on top of these minor collections. -
Hi,
i'm new to 10g appl server
Failed to deploy web application "AGXI51". Failed to deploy web application "AGXI51". . The evaluate phase failed. The Adapter used in the evaluate may have thrown an exception.
Resolution:
Please call Oracle support.
Base Exception:
java.lang.OutOfMemoryError
null. java.lang.OutOfMemoryError
i'm getting this Error while deploying the application.So wat is the procedure to increase the Heap Size
Regards,
Niranjan.DLocate opmn.xml on your instance. In file locate section relevant for container you use (i.e. "home"). In next line you can see tags where startup parameters are set. You should add following parameters (this will set heap size on 512Mb)
-Xms512m -Xmx512m
For detailed explanation I would recommend you to check following link:
http://download-uk.oracle.com/docs/cd/B25221_03/web.1013/b14431/troublesht.htm
Hope this help. -
Invalid initial heap size error when starting weblogic server 11g R1
I installed JDeveloper Studio 11.1.1.2.0 . When iItried to start weblogic server 11g R1, I had this message :
starting weblogic with Java version:
java version "1.6.0_14"
Java(TM) SE Runtime Environment (build 1.6.0_14-b08)
Java HotSpot(TM) Client VM (build 14.0-b16, mixed mode)
Starting WLS with line:
C:\Oracle\MIDDLE~1\JDK160~1.5-3\bin\java -client -Xms256m -Xmx512m -XX:CompileThreshold=8000 -XX:PermSize=128m -XX:MaxPermSize=512m -Dweblogic.Name=DefaultServer -Djava.security.policy=C:\Oracle\MIDDLE~1\WLSERV~1.3\server\lib\weblogic.policy -Djavax.net.ssl.trustStore=C:\Oracle\Middleware\wlserver_10.3\server\lib\DemoTrust.jks -Dweblogic.nodemanager.ServiceEnabled=true -Xverify:none -da -Dplatform.home=C:\Oracle\MIDDLE~1\WLSERV~1.3 -Dwls.home=C:\Oracle\MIDDLE~1\WLSERV~1.3\server -Dweblogic.home=C:\Oracle\MIDDLE~1\WLSERV~1.3\server -Djps.app.credential.overwrite.allowed=true -Ddomain.home=C:\DOCUME~1\Admin\APPLIC~1\JDEVEL~1\SYSTEM~1.36\DEFAUL~1 -Dcommon.components.home=C:\Oracle\MIDDLE~1\ORACLE~1 -Djrf.version=11.1.1 -Dorg.apache.commons.logging.Log=org.apache.commons.logging.impl.Jdk14Logger -Djrockit.optfile=C:\Oracle\MIDDLE~1\ORACLE~1\modules\oracle.jrf_11.1.1\jrocket_optfile.txt -Doracle.domain.config.dir=C:\DOCUME~1\Admin\APPLIC~1\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\FMWCON~1 -Doracle.server.config.dir=C:\DOCUME~1\Admin\APPLIC~1\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\FMWCON~1\servers\DefaultServer -Doracle.security.jps.config=C:\DOCUME~1\Admin\APPLIC~1\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\fmwconfig\jps-config.xml -Djava.protocol.handler.pkgs=oracle.mds.net.protocol -Digf.arisidbeans.carmlloc=C:\DOCUME~1\Admin\APPLIC~1\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\FMWCON~1\carml -Digf.arisidstack.home=C:\DOCUME~1\Admin\APPLIC~1\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\FMWCON~1\arisidprovider -Dweblogic.alternateTypesDirectory=\modules\oracle.ossoiap_11.1.1,\modules\oracle.oamprovider_11.1.1 -Dweblogic.jdbc.remoteEnabled=false -Dwsm.repository.path=C:\DOCUME~1\Admin\APPLIC~1\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\oracle\store\gmds "-Xms512m -Xmx512m" -Dweblogic.management.discover=true -Dwlw.iterativeDev= -Dwlw.testConsole= -Dwlw.logErrorsToConsole= -Dweblogic.ext.dirs=C:\Oracle\MIDDLE~1\patch_wls1032\profiles\default\sysext_manifest_classpath;C:\Oracle\MIDDLE~1\patch_jdev1111\profiles\default\sysext_manifest_classpath weblogic.Server
Could not create the Java virtual machine.
Invalid initial heap size: -Xms512m -Xmx512m
Process exited.
Please, how can I fixe this error ?For 2 GB machine set the parameters as below:
/ide/bin/ide.conf
AddVMOption -Xmx1232M
AddVMOption -Xms64M
/jdev/bin/jdef.conf
AddVMOption -XX:MaxPermSize=128M
For 3 GB machine set the parameters as below:
/ide/bin/ide.conf
AddVMOption -Xmx1488M
AddVMOption -Xms64M
/jdev/bin/jdef.conf
AddVMOption -XX:MaxPermSize=128M -
Problem increasing heap size using Java Control Panel
I am running a web-based bioinformatics package which uses a Java applet as the client application. It mostly works fine, but some large clustering processes don't complete, they just cycle endlessly. The user manual advises increasing heap space "by entering the following command in the Java Control Panel or Java Plug-in dialog: -Xms128M -Xmx256M." I can open the Java Control Panel OK and enter the necessary command in the Java Runtime Parameters box, but after clicking OK then Apply, the Runtime Parameters box is empty again and there is no increase in the heap size allocation. In other words, the change doesn't take effect.
I have already tried: adjusting one parameter at a time (max heap size first, then min); changing uppercase to lowercase M (-Xmx256m); restarting the browser after the change; rebooting my PC - none of these has helped.
Technical details: it's Java 6 standard edition, build 1.6.0_10-rc-b28; browser is Internet Explorer 7; operating system is Vista (Service Pack 1); PC is a 2.4 GHz processor with 2 GB RAM (so I have plenty available to allocate to Java). I have local admin privilege on my PC.
Help would be much appreciated, as I really need to complete these cluster analyses. I'm a biologist not a developer, so ideally I need a solution that doesn't involve major programming, though I'm OK with registry edits and use of the command line. Thanks in advance.The failure to retain the parameters is a bug, per hdong in this [Java,net thread|http://forums.java.net/jive/thread.jspa?threadID=44540&tstart=0] dated August 14
"I did a little more research and found out that the problem is only with "-rc" or "-beta" versions of plugin. When 1.6.0_10 is finally released, the version string will be "1.6.0_10". Plugin works fine to set/get jvm parameters when version string is "1.6.0_10".
I am surprised that this issue was not discovered earlier. It was probably because the internal test binary use "1.6.0_10" as version string.
Yeah, it is a bug that will affect many manny developers. It will be fixed as soon as possible." -
JVM heap size limit under Windows
Hi,
I'm looking either for some help with a workaround, or
confirmation that the information I've found is still the case for the
current state of Java.
Development machine is Win XP Pro, 2G RAM.
Biggest heap I can allocate is about 1.6G, and that is not large enough for this
app.
I have a Swing application that
1) must run on Win XP, 32 bit
2) must implement an editor (similar to Excel but with fewer features) to handle large csv files
( up to about 800Mb).
3) Strong preference for Java 5, though higher could conceivably be supported.
Research so far tells me that this is the result of process memory limitations
of Windows and the JVM, and that I might be able to squeeze a little more heap with
Windows' rebase command, but probably not enough and I would start running the
risk of conflicts with other applications on my users' systems. Ugh.
Also I read of the Windows /3GB switch, but posts say that the JDK's available are not
built to be able to use that feature. I havent had a chance to add memory to
test that yet. However, I'm also under the impression that I should be able to
allocate a heap larger than physical RAM ... except for that process size limit.
So ... my information is basically that I'm stuck with a limit of about 1.6G for
heap size, regardless of the RAM on my computer.
Can anyone confirm whether that is still correct, preferably with a pointer to some
official reference ?
Or better yet, point me toward a workaround?
Thanks!
-tom>
Some bookmarks I have on this topic.
http://sinewalker.wordpress.com/2007/03/04/32-bit-windows-and-jvm-virtual-memory-limit/
http://stackoverflow.com/questions/171205/java-maximum-memory-on-windows-xp
The first link pulled together what I found in lots of bits and pieces elsewhere, nice to have a coherent summary :)
The second link offered a bit of insight into the jvm that I hadn't seen yet .
Thanks! -
Maximum heap size for 64bit JVM
Hi,
I am trying to set the maximum heap size for a java process in a 64bit JVM . I am not able to set more then 3G
command line config:
java -Xms64m -Xmx3g -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.port=8000 com.superpages.puboptions.CampaignFeedStarter >> publisher.out 2>&1 &
Hardware / software configs
*$uname -a*
SunOS labsbear 5.9 Generic_122300-19 sun4u sparc SUNW,Sun-Fire-V440
*16GB total physical memory*
*4 processor machine*
*64 bit JVM*
JDK1.6
where is this limitation coming from. How to set the heap size to 6g.
Thanks for your time
MeenaYou need to use the -d64 switch to request the 64-bit JVM. E.g.,$ java -showversion -Xmx6g HelloWorld
Invalid maximum heap size: -Xmx6g
The specified size exceeds the maximum representable size.
Could not create the Java virtual machine.
$ java -showversion -d64 -Xmx6g HelloWorld
java version "1.6.0_07"
Java(TM) SE Runtime Environment (build 1.6.0_07-b04)
Java HotSpot(TM) 64-Bit Server VM (build 10.0-b23, mixed mode)
Hello world! -
How to set the Heap size for JAVA
I am facing the memory out of space problem:
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
Could anyone suggest me a solution to solve the problem ?
increase the heap size ?
anyway to increase the heap size in the program by default without additional setup?
Thank you.How to determine the program must handled with increase heap size ?
could I know any method to know whether the program is memory leaking or need large memory heap size? -
How to set the maximum heap size on a deployed application?
I�m running a fairly large java application and am getting java.lang.OutOfMemoryError. I could increase the heap size in my development environment to eliminate this error. However, I don�t know how to set this in a deployed application. We are currently using ant to build our software.
Another question, when I execute a statement such as java �Xmx512M �cp app.jar. Is it correct to say that the application in app.jar will use to a maximum of 512MB of memory when running?
Thank you everyone for your help!But first, when you say "a deployed environment" do you mean an executable .jar file? This is what I'm using.The term "deploy" is commonly used to refer to deploying an ear file or a war file on an application server.
I would assume that there is some entry you can include in the .jar's
Manifest.mf file to specify the maximum memory, but I can't find an example of the entry. <a href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6197671"></a> -
Hi,
I am wondering what's the default heap size if I don't add -ms -mx opation? I
set the two options and the following is the output from -verbosegc. what's it
means?
Thanks.
[GC 2598K->2145K(2696K), 0.0035829 secs]
[GC 2656K->2201K(2824K), 0.0036262 secs]
[Full GC 2713K->2070K(4028K), 0.1933980 secs]
[GC 2582K->2229K(4028K), 0.0046565 secs]
[GC 2741K->2373K(4028K), 0.0061002 secs]
[GC 2885K->2514K(4028K), 0.0064346 secs]
[GC 3026K->2656K(4028K), 0.0061670 secs]
[GC 3168K->2798K(4028K), 0.0054694 secs]
[GC 3310K->2940K(4028K), 0.0054521 secs]
[GC 3452K->3080K(4028K), 0.0058119 secs]
[GC 3592K->3216K(4028K), 0.0059069 secs]
[GC 3728K->3357K(4028K), 0.0057200 secs]
[GC 3869K->3496K(4028K), 0.0055719 secs]
[GC 4008K->3636K(4156K), 0.0057239 secs]
[Full GC 4148K->3649K(6544K), 0.3064887 secs]
[GC 4091K->3773K(6544K), 0.0412259 secs]
[GC 4285K->3912K(6544K), 0.0052336 secs]
[GC 4424K->4051K(6544K), 0.0055661 secs]
[GC 4563K->4189K(6544K), 0.0055543 secs]
[GC 4701K->4326K(6544K), 0.0055703 secs]
[GC 4838K->4464K(6544K), 0.0055915 secs]
[GC 4976K->4608K(6544K), 0.0059667 secs]
[GC 5120K->4746K(6544K), 0.0053261 secs]
[GC 5258K->4884K(6544K), 0.0053761 secs]
[GC 5396K->5023K(6544K), 0.0059290 secs]
[GC 5534K->5159K(6544K), 0.0054320 secs]
[GC 5671K->5301K(6544K), 0.0114341 secs]
[GC 5813K->5405K(6544K), 0.0103658 secs]
[GC 5917K->5492K(6544K), 0.0053194 secs]
[GC 6003K->5592K(6544K), 0.0107092 secs]
[GC 6104K->5694K(6544K), 0.0096887 secs]
[GC 6206K->5786K(6544K), 0.0037949 secs]
[GC 6298K->5890K(6544K), 0.0101172 secs]
[GC 6402K->5990K(6544K), 0.0041271 secs]
[GC 6502K->6097K(6672K), 0.0040678 secs]
[Full GC 6609K->6191K(10992K), 0.2664733 secs]
Tue Dec 04 15:22:10 PST 2001:<I> <T3Services> CacheManagerImpl: EMAIL TEMPLATE
C
ACHE STARTING
[GC 6849K->6361K(10992K), 0.0586387 secs]
Tue Dec 04 15:22:10 PST 2001:<I> <T3Services> CacheManagerImpl: SCHEDULE CACHE
S
TARTING
[GC 7129K->6530K(10992K), 0.0083019 secs]
[GC 7298K->6678K(10992K), 0.0058533 secs]
[GC 7446K->6807K(10992K), 0.0052940 secs]
[GC 7575K->6920K(10992K), 0.0048598 secs]I think the default heap size is 16MB, as for the GC output:
these [GC 2598K->2145K(2696K), 0.0035829 secs]
show the collection of Objects within the eden area of the heap (Short lived Objects),
the heap size before GC was 2598K and after GC was 2145K and the time taken was
0.0035829 secs.
These outputs:
[Full GC 2713K->2070K(4028K), 0.1933980 secs]
show the details for a full GC, these are the ones to watch out for, they will
take longer and the JVM (no mater how many processors) will block during a full
GC....I.E no server response at all.
The smaller the heap size the more often a full GC will occur, however the larger
the heap, the longer the full GC will take.
One of the new options for jdk 1.3.1 is the -Xincgc option, this will do incremental
Garbage Collection, overall it will take longer than normal, but the individual
Full GCs will take less time....so the server is not hung for as long at any one
time.
Set -Xms (the minimum heap) to the same as -Xmx (max heap), this increases performance
as the JVM does not have to repeatedly assign more memory to the heap.
Gareth
"Jen" <[email protected]> wrote:
>
Hi,
I am wondering what's the default heap size if I don't add -ms -mx opation?
I
set the two options and the following is the output from -verbosegc.
what's it
means?
Thanks.
[GC 2598K->2145K(2696K), 0.0035829 secs]
[GC 2656K->2201K(2824K), 0.0036262 secs]
[Full GC 2713K->2070K(4028K), 0.1933980 secs]
[GC 2582K->2229K(4028K), 0.0046565 secs]
[GC 2741K->2373K(4028K), 0.0061002 secs]
[GC 2885K->2514K(4028K), 0.0064346 secs]
[GC 3026K->2656K(4028K), 0.0061670 secs]
[GC 3168K->2798K(4028K), 0.0054694 secs]
[GC 3310K->2940K(4028K), 0.0054521 secs]
[GC 3452K->3080K(4028K), 0.0058119 secs]
[GC 3592K->3216K(4028K), 0.0059069 secs]
[GC 3728K->3357K(4028K), 0.0057200 secs]
[GC 3869K->3496K(4028K), 0.0055719 secs]
[GC 4008K->3636K(4156K), 0.0057239 secs]
[Full GC 4148K->3649K(6544K), 0.3064887 secs]
[GC 4091K->3773K(6544K), 0.0412259 secs]
[GC 4285K->3912K(6544K), 0.0052336 secs]
[GC 4424K->4051K(6544K), 0.0055661 secs]
[GC 4563K->4189K(6544K), 0.0055543 secs]
[GC 4701K->4326K(6544K), 0.0055703 secs]
[GC 4838K->4464K(6544K), 0.0055915 secs]
[GC 4976K->4608K(6544K), 0.0059667 secs]
[GC 5120K->4746K(6544K), 0.0053261 secs]
[GC 5258K->4884K(6544K), 0.0053761 secs]
[GC 5396K->5023K(6544K), 0.0059290 secs]
[GC 5534K->5159K(6544K), 0.0054320 secs]
[GC 5671K->5301K(6544K), 0.0114341 secs]
[GC 5813K->5405K(6544K), 0.0103658 secs]
[GC 5917K->5492K(6544K), 0.0053194 secs]
[GC 6003K->5592K(6544K), 0.0107092 secs]
[GC 6104K->5694K(6544K), 0.0096887 secs]
[GC 6206K->5786K(6544K), 0.0037949 secs]
[GC 6298K->5890K(6544K), 0.0101172 secs]
[GC 6402K->5990K(6544K), 0.0041271 secs]
[GC 6502K->6097K(6672K), 0.0040678 secs]
[Full GC 6609K->6191K(10992K), 0.2664733 secs]
Tue Dec 04 15:22:10 PST 2001:<I> <T3Services> CacheManagerImpl: EMAIL
TEMPLATE
C
ACHE STARTING
[GC 6849K->6361K(10992K), 0.0586387 secs]
Tue Dec 04 15:22:10 PST 2001:<I> <T3Services> CacheManagerImpl: SCHEDULE
CACHE
S
TARTING
[GC 7129K->6530K(10992K), 0.0083019 secs]
[GC 7298K->6678K(10992K), 0.0058533 secs]
[GC 7446K->6807K(10992K), 0.0052940 secs]
[GC 7575K->6920K(10992K), 0.0048598 secs] -
Upto how much I can set maximum Heap size for jvm?
I am running application on 8GB RAM Windows 64 bits machine.
I am running out of OutOfMemory (Heap Space). I want to increase the Heap Size for my jvm.
But can anybody please tell me what is the limit by which I can set the maximum size for heap?
Thanks in Advance,
JenishMax allowed memory per process is 2 raised to the 64th power. What maximum memory you can set depends on the memory available
for your application. You may be able to set more than 8GB ram then it will use the swap space and it will slow down your application
performance. So try different memory size and see which one works best for your application. -
How to set max-heap-size outside the jnlp file?
Due to bug_id=6631056 It may not be possible to specify max-heap-size within
the JNLP file for certain jnlp java applications.
Are there other possibilities to specify this Jvm parameter?
In the ControlPanel there is the possibility to specify Xmx for applets but not for jnlp.
I have tried to add properties like
"deployment.javaws.jre.0.args=Xmx\=128M" without success
Many thanksEven in JNLP also you can specify the max heap size
<j2se version="1.5+" initial-heap-size="128m" max-heap-size="512m"/>
Thanks,
Suresh
[http://sureshdevi.co.in|http://sureshdevi.co.in]
Maybe you are looking for
-
Linebreak Code in Character Mode Report
Dear All I m saving a Character Mode Report which is 132 column Wide, and i can access that report in Note Pad in proper format and alignment but when i m use WORDPAD, it open in un aligned format i mean with line break. so any one can give me any Id
-
Error while opening workspace in JDev
Hi Experts, I am getting the following error while opening a workspace in JDev. " XYZ.jws was saved in version file format and cannot be opened with an old version of Jdeveloper " Is it because of wrong committing of files to Repository? Thanks
-
Are there iBook G4 operating restrictions?
Owning 2 older iMacs (OS 8.5 and 9), which I haven't even touched since I got my iBook a couple of years ago, I am using this G4 all day long, i.e for EVERYTHING. It's been perfectly good up to now, but I just bought the upgrade to Tiger and am afrai
-
Numbers won't add pdf extension to filename
Hi, I am a bit frustrated that when I add '.pdf' to my filenames (when exporting to pdf from numbers, pages, etc), it doesn't save them like that, it just takes it off. Which means that I always have to go back to the file and add it in again. I know
-
How do I get my Iphone out of recovery mode without earsing all my personal stuff?