windows - Java goes OutOfMemory even with enough RAM -


i have app uses following jvm options:

-xmx512m -xms256m -xx:+useparnewgc -xx:+useconcmarksweepgc  -xx:maxgcpausemillis=2 -xx:maxdirectmemorysize=1g 

i run on windows 7 x64 8gb ram. , when task manager says there's 60% of ram in use, becomes impossible run program, java says "out of memory". though in theory still have 3gb of free ram left. below screenshots of profiling project in netbeans (until crashes on random spot). cause these problems? program expensive?

скриншот http://ssmaker.ru/68b30a7f.png

скриншот http://ssmaker.ru/dc9f4410.png

you should greedy-allocate minimum required overhead. is, use -xms1g -xmx1g, when app starts running, has reserved maximal heap usage.


Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -