[
https://issues.apache.org/jira/browse/CASSANDRA-9242?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14514885#comment-14514885
]
Ariel Weisberg commented on CASSANDRA-9242:
-------------------------------------------
I looked at the JDK source for PerfDisableSharedMem and it seems low risk. The
memory is allocated as anonymous memory instead of a file, and what I read
implies that only monitoring tools use the file so there is no downside to
having it be anonymous.
If we care about this kind of hiccup we should figure out what the story is
with GC logging. At one point GC logging could actually block the JVM, but I
recall when doing some code reading recently that there is now a dedicated
victim thread for doing GC logging.
We also need to make sure that any application threads that might access
logging don't do so while holding a lock or alternatively configure logging to
be asynchronous. I like to do it semi-sync where warn and error are blocking,
but everything else is async.
> Add PerfDisableSharedMem to default JVM params
> ----------------------------------------------
>
> Key: CASSANDRA-9242
> URL: https://issues.apache.org/jira/browse/CASSANDRA-9242
> Project: Cassandra
> Issue Type: Improvement
> Components: Config
> Reporter: Matt Stump
> Assignee: Ariel Weisberg
>
> We should add PerfDisableSharedMem to default JVM params. The JVM will save
> stats to a memory mapped file when reaching a safepoint. This is performed
> synchronously and the JVM remains paused while this action takes place.
> Occasionally the OS will stall the calling thread while this happens
> resulting in significant impact to worst case JVM pauses. By disabling the
> save in the JVM these mysterious multi-second pauses disappear.
> The behavior is outlined in [this
> article|http://www.evanjones.ca/jvm-mmap-pause.html]. Another manifestation
> is significant time spent in sys during GC pauses. In [the linked
> test|http://cstar.datastax.com/graph?stats=762d9c2a-eace-11e4-8236-42010af0688f&metric=gc_max_ms&operation=1_write&smoothing=1&show_aggregates=true&xmin=0&xmax=110.77&ymin=0&ymax=10421.4]
> you'll notice multiple seconds spent in sys during the longest pauses.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)