tags:

views:

1810

answers:

1

How to redirect verbose garbage collection output to a file? Suns site shows an example for unix but it doesn't work for windows.

+4  A: 
Michael Myers
thank you very much for the great answer
djangofan
java --Xloggc:firstgen.log -Xloggc:secondgen.log doesn't seem to work by the way.
djangofan
Also, this doesnt increase the output, as I expected. There are no additional details after using these arguments:-Xloggc:gc.log -XX:-PrintGCDetails
djangofan
"-XX:+PrintGCDetails" seems to work fine with -Xloggc. I don't know why the Sun page has a - instead of a +.
Michael Myers
that worked. thanks! now, i use these options: set JAVA_OPTS=%JAVA_OPTS% -Xloggc:logs\gc.log -XX:+PrintGCDetails -XX:MaxPermSize=128m
djangofan