Do you have to specify -XX:ParallelGCThreads along with -XX:+UseParallelOldGC for Java applications?

Solution Verified - Updated -

Environment

Java application

Issue

If I use “-XX:+UseParallelOldGC”, don’t I need to specify the “-XX:ParallelGCThreads” as well?

Resolution

UseParallelOldGC tells the JVM to use the parallel throughput collector for the old and young generations. ParallelGCThreads specifies how many threads it should use, rather than the default value (which I believe is 5/8 of the number of CPU cores plus 1).

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.