You can enable both sets of options. But -XX:+DisableExplicitGC prevent any SystemGC calls coming from RMI sessions.
The recommended use is to either disable SystemGC alltogether using -XX:+DisableExplicitGC , or at least use the sun.rmi.dgc.*.gcInterval to control the frequency of System GC calls (so that the SystemGC system does not appear too often).
I would suggest using -XX:+DisableExplicitGC and see if the number of "dead" RMI objects is growing, if so, then you need to start the configuration using the sun.rmi.dgc.*.gcInterval .
Itβs all stipulated that you really want to avoid Full GC, perhaps take a short pause. Full GC will not be such a bad idea, as you will need to clean up RMI objects.
source share