I want to configure java PermGen option for jenkins.
in search web, I found article which write:
set java_opts JAVA_OPTS="-server -XX:PermSize=128M -XX:MaxPermSize=256m"
other article says:
set java args JAVA_ARGS="-XX:MaxPermSize=512m -Xms512m -Xmx1024m"
Are each options valid? if not, what is the difference?
Java applications are usually called by a startup script with a command like java $JAVA_ARGS $JAVA_OPTS -jar application.jar
Both variables are JVM options and they're both given to the application.
It is (unfortunately) not uncommon to have a list of 10 general options + 10 optimizations options so they're split across 2 variables for readability.
PermGen settings are considered garbage collector optimizations. They go in JAVA_OPTS. You should check that the jenkins script is using both variables as expected.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With