Full GC real time is much more that user+sys times

后端 未结 1 1176
暖寄归人
暖寄归人 2020-12-30 07:12

We have a Web Java based application running on JBoss with allowed maximum heap size of about 1.2 GB (total machine physical memory is 2 GB). At some point the application s

相关标签:
1条回答
  • 2020-12-30 07:44

    Where does all the other time go?

    It is most likely that your application is causing virtual memory thrashing. Basically, your application needs significantly more pages of virtual memory than there are physical pages available to hold them. As a result, it is spending most of the time waiting for vm pages to be read from and written to disc.

    For more information, read this wikipedia page.

    The cure is to either reduce virtual memory usage or increase the amount of physical memory on the system. For example, you could:

    • run fewer applications on the machine,
    • reduce Java application heap sizes, or
    • if you are running in a virtual, increase the virtual's allocation of physical memory.

    (Note however that reducing the JVM heap size can be a two-edged sword. If you reduce the heap size too much the application will either die from OutOfMemoryErrors, spend too much time garbage collecting, or suffer from not being able to cache things effectively.)

    0 讨论(0)
提交回复
热议问题