cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Cassandra Wiki] Update of "Durability" by TylerHobbs
Date Sat, 20 Oct 2012 22:33:49 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Cassandra Wiki" for change notification.

The "Durability" page has been changed by TylerHobbs:
http://wiki.apache.org/cassandra/Durability?action=diff&rev1=4&rev2=5

Comment:
Update commitlog options to match current cassandra.yaml

  
  Instead, like other modern systems, Cassandra provides durability by appending writes to
a commitlog first.  This means that only the commitlog needs to be fsync'd, which, if the
commitlog is on its own volume, obviates the need for seeking since the commitlog is append-only.
 Implementation details are in ArchitectureCommitLog.
  
- Cassandra's example configuration shows !CommitLogSync set to periodic, meaning that we
sync the commitlog every CommitLogSyncPeriodInMS ms, so you can potentially lose up to that
much data in a crash.  This is decently performant even with the commitlog shared with data
directories.  You can also select "batch" mode, where Cassandra will guarantee that it syncs
before acknowledging writes, i.e., fully durable mode, in batches of CommitLogSyncBatchWindowInMS.
 To use this mode we strongly recommend splitting your commitlog onto a separate device, as
described above.
+ Cassandra's default configuration sets the `commitlog_sync` mode to `periodic`, causing
the commitlog to be synced every `commitlog_sync_period_in_ms` milliseconds, so you can potentially
lose up to that much data if all replicas crash within that window of time. This default behavior
is decently performant even when the commitlog shares a disk with data directories.  You can
also select `batch` mode, where Cassandra will guarantee that it syncs before acknowledging
writes.  To avoid syncing after every write, Cassandra groups the mutations into batches and
syncs every `commitlog_batch_window_in_ms`.  When using this mode, we strongly recommend putting
your commitlog on a separate, dedicated device, as described above.
  
- Users familiar with PostgreSQL may note that CommitLogSyncPeriodInMS and CommitLogSyncBatchWindowInMS
correspond to the [[http://www.postgresql.org/docs/8.4/static/runtime-config-wal.html|PostgreSQL
settings]] of wal_writer_delay and commit_delay, respectively.
+ Users familiar with PostgreSQL may note that `commitlog_sync_period_in_ms` and `commitlog_batch_window_in_ms`
correspond to the [[http://www.postgresql.org/docs/8.4/static/runtime-config-wal.html|PostgreSQL
settings]] of wal_writer_delay and commit_delay, respectively.
  

Mime
View raw message