×

Loading...

Topic

This topic has been archived. It cannot be replied.
  • 工作学习 / IT杂谈 / help! could anybody know how to increase heap size when you start Java applicaton? (like java -Xmx<size>)
    the default initial and maximum heap sizes are 1048576 and 67108864 bytes.
    I don't know how to increase that.

    help!!!
    • Java stand application or web application run on some application server?why you do that?
      • I need a program to keep updating data into DB. but when it's over 2000 cycles. it throws a exception below:
        java.lang.OutOfMemoryError [JMX RMI Adaptor] <<no stack trace available>>
        i was told to increase the Mem size when you run the application. but i don't know how.

        thanks for your reply.
        • you can read this article. url is below. explain how to manage memory. But In my opinion. this is a design problem, not a memory problem.
          • thank you
            • Does your program work well?
              • your information is very helpful. thanks. but I did not get chance to test it. will let's you know when i finish testing.
              • To all DX. my program is working now. sometimes i think java garbage collection does not work effectively.
                • Java gc has minor problem if you are not careful while using 'collection'. You have to make sure no references are being held when you expect java gc to work.
        • classic memory leak problem
          • any tips to avoid that error.
            • need more infomation and thinking. im new at java
        • try this way: java -Xms128m -Xmx128m .......
          • thanks