<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Java - JVM large heap size problem in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999124#M126071</link>
    <description />
    <pubDate>Tue, 17 Jun 2003 14:41:37 GMT</pubDate>
    <dc:creator>Jeff Schussele</dc:creator>
    <dc:date>2003-06-17T14:41:37Z</dc:date>
    <item>
      <title>Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999116#M126063</link>
      <description />
      <pubDate>Tue, 17 Jun 2003 07:01:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999116#M126063</guid>
      <dc:creator>Morgan Pyne</dc:creator>
      <dc:date>2003-06-17T07:01:21Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999117#M126064</link>
      <description>point to note : I'm not a java programmer.&lt;BR /&gt;&lt;BR /&gt;OK that over with I've found the following which may help ....&lt;BR /&gt;&lt;BR /&gt; Making the heap larger decreases the frequency of collections but makes each collection take longer. One good rule of thumb is that you should ensure that there is more than 50% free space available in the heap after a collection. With the -verbosegc flag on, it will print the amount of free space after each collection.&lt;BR /&gt;&lt;BR /&gt;For server applications where swap space and physical memory are not concerns, it may be better to run with a very large heap to spread out the collections. For applications that have a stable heap resident set (i.e., they have a consistent amount of live data after each collection), you can set the initial and maximum heap sizes to be the same value. Setting the heap sizes to be 3-4 times the resident set will put the amount of free heap space in the 65-75% range.&lt;BR /&gt;&lt;BR /&gt;Increasing the startup heap size will cause more system swap to be used. The user will have to balance heap requirements against swap usage. The -ms setting should be high enough that the system is not frantically doing garbage collection, but low enough that system resources are not being consumed too eagerly.&lt;BR /&gt;&lt;BR /&gt;For example, your application needs between 12 and 16 MB. You would want to specify:&lt;BR /&gt;&lt;BR /&gt;   -ms32m -mx32m&lt;BR /&gt;&lt;BR /&gt;This would prevent the JVM from trying to fit your app into 1 MB or 4 MB, and would also provide plenty of free space to improve gc performance.&lt;BR /&gt;&lt;BR /&gt;For applications that have a widely varying resident set (or have a different resident set on different runs), try to leave the initial heap size at the default and set the maximum value large enough to handle the largest data set. An example of this kind of application is the Java compiler itself. When compiling small files, it doesn't use much heap space. When compiling lots of files (or very large ones) it uses a lot of space. By keeping the initial heap size low, it doesn't overuse the physical memory of the machine when compiling small files. The tradeoff is that compiling large files will cause the collector to go through some spasms in order to grow the heap to its desired size.&lt;BR /&gt;&lt;BR /&gt;The default is 1 MB.</description>
      <pubDate>Tue, 17 Jun 2003 07:58:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999117#M126064</guid>
      <dc:creator>Alex Glennie</dc:creator>
      <dc:date>2003-06-17T07:58:06Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999118#M126065</link>
      <description>Hi Alex,&lt;BR /&gt;&lt;BR /&gt;Thx, for the reply. Useful info regarding heap management, however I can't give you any points since you didn't actually address my problem/question at all :-(&lt;BR /&gt;&lt;BR /&gt;Cheers,&lt;BR /&gt;Morgan&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 17 Jun 2003 12:25:20 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999118#M126065</guid>
      <dc:creator>Morgan Pyne</dc:creator>
      <dc:date>2003-06-17T12:25:20Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999119#M126066</link>
      <description>Hi Morgan,&lt;BR /&gt;&lt;BR /&gt;How much swap space do you have configured?&lt;BR /&gt;Swap is not only used to page out processes, it's also needed to reserve space "in case" it needs to page out.&lt;BR /&gt;When you start that java process, it will need to reserve that much swap space.&lt;BR /&gt;&lt;BR /&gt;Post output of:&lt;BR /&gt;&lt;BR /&gt;swapinfo -tam&lt;BR /&gt;&lt;BR /&gt;Rgds,&lt;BR /&gt;Jeff</description>
      <pubDate>Tue, 17 Jun 2003 12:30:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999119#M126066</guid>
      <dc:creator>Jeff Schussele</dc:creator>
      <dc:date>2003-06-17T12:30:22Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999120#M126067</link>
      <description>Oh &amp;amp; I forgot to mention that your maxdsiz_64bit MUST be larger than 2 Gb as well.&lt;BR /&gt;You have to be able to fit this data size into BOTH swap &amp;amp; the maxdsiz_64bit space.&lt;BR /&gt;&lt;BR /&gt;Rgds,&lt;BR /&gt;Jeff</description>
      <pubDate>Tue, 17 Jun 2003 12:36:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999120#M126067</guid>
      <dc:creator>Jeff Schussele</dc:creator>
      <dc:date>2003-06-17T12:36:31Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999121#M126068</link>
      <description>Hi,&lt;BR /&gt;doing some seach i always find that thery are using&lt;BR /&gt;&lt;BR /&gt;-XmsSIZEm -XmxSIZEm&lt;BR /&gt;&lt;BR /&gt;using equal SIZE values.&lt;BR /&gt;&lt;BR /&gt;Instead i see that you specify different values (for min and max).&lt;BR /&gt;&lt;BR /&gt;Did you try specifyng the same value, just to see if it is an application error when these value differ ? Maybe with 1500m each.&lt;BR /&gt;&lt;BR /&gt;Just a try...&lt;BR /&gt;&lt;BR /&gt;HHTH,&lt;BR /&gt;  Massimo&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 17 Jun 2003 13:02:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999121#M126068</guid>
      <dc:creator>Massimo Bianchi</dc:creator>
      <dc:date>2003-06-17T13:02:03Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999122#M126069</link>
      <description>Have you seen this document yet?&lt;BR /&gt;I am not sure if it pertains to yiour case.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://www1.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&amp;amp;docId=200000066903282" target="_blank"&gt;http://www1.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&amp;amp;docId=200000066903282&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 17 Jun 2003 13:46:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999122#M126069</guid>
      <dc:creator>Elena Leontieva</dc:creator>
      <dc:date>2003-06-17T13:46:52Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999123#M126070</link>
      <description>Hi Jeff, Massimo&lt;BR /&gt;&lt;BR /&gt;Here is the output of swapinfo -tam :&lt;BR /&gt;&lt;BR /&gt;             Mb      Mb      Mb   PCT  START/      Mb&lt;BR /&gt;TYPE      AVAIL    USED    FREE  USED   LIMIT RESERVE  PRI  NAME&lt;BR /&gt;dev        1024       0    1024    0%       0       -    1  /dev/vg00/lvol2&lt;BR /&gt;dev        3000       0    3000    0%       0       -    2  /dev/vg00/lvol14&lt;BR /&gt;dev        3000       0    3000    0%       0       -    2  /dev/vg00/lvol15&lt;BR /&gt;reserve       -     337    -337&lt;BR /&gt;memory     2628      68    2560    3%&lt;BR /&gt;total      9652     405    9247    4%       -       0    -&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;and FYI, here are the current settings for the tunable kernel parameters (from /stand/system) :&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;STRMSGSZ        65535&lt;BR /&gt;create_fastlinks 1&lt;BR /&gt;dbc_max_pct     15&lt;BR /&gt;dbc_min_pct     2&lt;BR /&gt;default_disk_ir 1&lt;BR /&gt;fs_async        1&lt;BR /&gt;max_thread_proc 3000&lt;BR /&gt;maxdsiz         2063835136&lt;BR /&gt;maxdsiz_64bit   0X400000000&lt;BR /&gt;maxfiles        2048&lt;BR /&gt;maxfiles_lim    2048&lt;BR /&gt;maxssiz         0X04FB3000&lt;BR /&gt;maxssiz_64bit   0X10000000&lt;BR /&gt;maxswapchunks   4096&lt;BR /&gt;maxtsiz         0X40000000&lt;BR /&gt;maxtsiz_64bit   0X100000000&lt;BR /&gt;maxuprc         256&lt;BR /&gt;maxusers        512&lt;BR /&gt;ncallout        6000&lt;BR /&gt;nfile           30000&lt;BR /&gt;ninode          4000&lt;BR /&gt;nkthread        6000&lt;BR /&gt;nproc           2068&lt;BR /&gt;npty            200&lt;BR /&gt;nstrpty         200&lt;BR /&gt;shmmax          0X40000000&lt;BR /&gt;vps_ceiling     64&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;AFAIK, the java-out-of-the-box utility set these to high enough sensible values.&lt;BR /&gt;(maxdsiz_64bit is at 16gig)&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Do you notice any problems with these settings ?&lt;BR /&gt;&lt;BR /&gt;Do you attach any significance to the fact that the error is reporting an attempt to allocate a negative number of bytes?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Massimo:&lt;BR /&gt;&lt;BR /&gt;Changing the Xmx and Xms values to be the same does not affect the behaviour in any way.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Regards &amp;amp; thanks,&lt;BR /&gt;Morgan</description>
      <pubDate>Tue, 17 Jun 2003 13:58:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999123#M126070</guid>
      <dc:creator>Morgan Pyne</dc:creator>
      <dc:date>2003-06-17T13:58:22Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999124#M126071</link>
      <description />
      <pubDate>Tue, 17 Jun 2003 14:41:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999124#M126071</guid>
      <dc:creator>Jeff Schussele</dc:creator>
      <dc:date>2003-06-17T14:41:37Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999125#M126072</link>
      <description>Hi Jeff,&lt;BR /&gt;&lt;BR /&gt;Thanks - I have read these installation notes also, but I was under the impression that this change was only necessary if you are embedding libjvm in a native application (e.g. if linking libjvm to a user-developed program, it would be necessary to chatr the resulting binary). Or am I misreading the release  notes ?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;I have already verified the patch level requirements and appear to be compliant.&lt;BR /&gt;&lt;BR /&gt;Cheers,&lt;BR /&gt;Morgan</description>
      <pubDate>Tue, 17 Jun 2003 15:06:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999125#M126072</guid>
      <dc:creator>Morgan Pyne</dc:creator>
      <dc:date>2003-06-17T15:06:31Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999126#M126073</link>
      <description>Me again :-)&lt;BR /&gt;&lt;BR /&gt;Just re-reading this thread and thought I'd better add some further info to clarify things.&lt;BR /&gt;&lt;BR /&gt;Although in my original postings I referred to attempting to use Xmx2000m, I should note that this error is also reproduceable for me with Xmx as low as 1400m (which is even below the 1500-2000MB range discussed in the release notes above).&lt;BR /&gt;&lt;BR /&gt;Can somebody confirm what the maximum allowed heap size should be for invoking the 64bit jvm in my environment?&lt;BR /&gt;&lt;BR /&gt;Morgan&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 17 Jun 2003 15:50:56 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999126#M126073</guid>
      <dc:creator>Morgan Pyne</dc:creator>
      <dc:date>2003-06-17T15:50:56Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999127#M126074</link>
      <description>It looks like 64 bit java 1.4 has some interesting problems.  I confirmed that -Xmx values from -Xmx1605m to -Xmx4040m cause trouble.&lt;BR /&gt;Even bigger values like -Xmx5000m are OK.  That can even exceed available swap, since the jvm mmaps that really big area with a MAP_NORESERVE flag to delay allocating swap.&lt;BR /&gt;I went back to trying 'smaller' values and they sometimes worked as well.&lt;BR /&gt;There are no clearly responsible failed system calls in tusc traces of the failing cases.&lt;BR /&gt;It seems that the jvm is using some bad rule for deciding memory allocation success, perhaps related fitting regions into open address range areas determined by examining pstat_procvm results.&lt;BR /&gt;&lt;BR /&gt;By the way, the maxdsiz values do not limit the size of -Xmx settings.  The maxdsiz limits are for the malloc/sbrk heap.  The -Xmx limit is for the java's mmap based heap.  Mmap regions don't count towards maxdsiz.</description>
      <pubDate>Wed, 18 Jun 2003 17:33:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999127#M126074</guid>
      <dc:creator>Mike Stroyan</dc:creator>
      <dc:date>2003-06-18T17:33:13Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999128#M126075</link>
      <description>Looking at a few more test cases, it seems that your use of -Xincgc is more closely tied to the problem than any particular -Xmx value.  Could you just use the default generational garbage collector?</description>
      <pubDate>Wed, 18 Jun 2003 18:24:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999128#M126075</guid>
      <dc:creator>Mike Stroyan</dc:creator>
      <dc:date>2003-06-18T18:24:11Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999129#M126076</link>
      <description>Hi Mike,&lt;BR /&gt;&lt;BR /&gt;This is indeed interesting news. Unfortunately, I am not in a position to test this right now as I am at a conference and the machine in question is hosting part of the conference website.&lt;BR /&gt;&lt;BR /&gt;I will try your suggestions once the machine is free and post my results here (it will probably be next week). Meanwhile, if you find out any further information on the topic I would love to hear the details. Is this a known bug?&lt;BR /&gt;&lt;BR /&gt;Thx and regards,&lt;BR /&gt;Morgan&lt;BR /&gt;</description>
      <pubDate>Thu, 19 Jun 2003 11:23:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999129#M126076</guid>
      <dc:creator>Morgan Pyne</dc:creator>
      <dc:date>2003-06-19T11:23:22Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999130#M126077</link>
      <description>Mike,&lt;BR /&gt;&lt;BR /&gt;The conference just finished and I managed to sneak in some quick tests before the machines get shut down and shipped.&lt;BR /&gt;&lt;BR /&gt;You were absolutely spot on the ball - removing the incremental garbage collection allowed me to specify any value for the Xmx , tested all the way up to 3000m.&lt;BR /&gt;&lt;BR /&gt;Thx a lot and well spotted. Should have kept my points awards till after I tested so sorry about that. If you want to post another 1 line reply I'll award you 10 points for it!&lt;BR /&gt;&lt;BR /&gt;I guess there should be a bug report created for this?&lt;BR /&gt;&lt;BR /&gt;Cheers and all the best,&lt;BR /&gt;Morgan</description>
      <pubDate>Thu, 19 Jun 2003 14:14:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999130#M126077</guid>
      <dc:creator>Morgan Pyne</dc:creator>
      <dc:date>2003-06-19T14:14:33Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999131#M126078</link>
      <description>I already filed a defect against this.  A lab engineer is having a look at it.</description>
      <pubDate>Thu, 19 Jun 2003 16:34:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999131#M126078</guid>
      <dc:creator>Mike Stroyan</dc:creator>
      <dc:date>2003-06-19T16:34:09Z</dc:date>
    </item>
    <item>
      <title>Re: Java - JVM large heap size problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999132#M126079</link>
      <description>The lab engineer reports that this seems to be a manifestation of Javasoft bug id 4867781.</description>
      <pubDate>Wed, 25 Jun 2003 20:48:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/java-jvm-large-heap-size-problem/m-p/2999132#M126079</guid>
      <dc:creator>Mike Stroyan</dc:creator>
      <dc:date>2003-06-25T20:48:15Z</dc:date>
    </item>
  </channel>
</rss>

