Advertisement
OberstKlink01

cassandra.yaml

Jul 21st, 2015
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 35.63 KB | None | 0 0
  1. # NOTE:
  2. # See http://wiki.apache.org/cassandra/StorageConfiguration for
  3. # full explanations of configuration directives
  4. # /NOTE
  5.  
  6. # The name of the cluster. This is mainly used to prevent machines in
  7. # one logical cluster from joining another.
  8. cluster_name: 'Test Cluster'
  9.  
  10. # This defines the number of tokens randomly assigned to this node on the ring
  11. # The more tokens, relative to other nodes, the larger the proportion of data
  12. # that this node will store. You probably want all nodes to have the same number
  13. # of tokens assuming they have equal hardware capability.
  14. #
  15. #
  16. # If you leave this unspecified, Cassandra will use the default of 1 token for legacy compatibility,
  17. # and will use the initial_token as described below.
  18. #
  19. # Specifying initial_token will override this setting on the node's initial start,
  20. # on subsequent starts, this setting will apply even if initial token is set.
  21. #
  22. # If you already have a cluster with 1 token per node, and wish to migrate to
  23. # multiple tokens per node, see http://wiki.apache.org/cassandra/Operations
  24. num_tokens: 256
  25.  
  26. # initial_token allows you to specify tokens manually. While you can use # it with
  27. # vnodes (num_tokens > 1, above) -- in which case you should provide a
  28. # comma-separated list -- it's primarily used when adding nodes # to legacy clusters
  29. # that do not have vnodes enabled.
  30. initial_token: -9223372036854775808
  31.  
  32. # See http://wiki.apache.org/cassandra/HintedHandoff
  33. # May either be "true" or "false" to enable globally, or contain a list
  34. # of data centers to enable per-datacenter.
  35. # hinted_handoff_enabled: DC1,DC2
  36. hinted_handoff_enabled: true
  37. # this defines the maximum amount of time a dead host will have hints
  38. # generated. After it has been dead this long, new hints for it will not be
  39. # created until it has been seen alive and gone down again.
  40. max_hint_window_in_ms: 10800000 # 3 hours
  41. # Maximum throttle in KBs per second, per delivery thread. This will be
  42. # reduced proportionally to the number of nodes in the cluster. (If there
  43. # are two nodes in the cluster, each delivery thread will use the maximum
  44. # rate; if there are three, each will throttle to half of the maximum,
  45. # since we expect two nodes to be delivering hints simultaneously.)
  46. hinted_handoff_throttle_in_kb: 1024
  47. # Number of threads with which to deliver hints;
  48. # Consider increasing this number when you have multi-dc deployments, since
  49. # cross-dc handoff tends to be slower
  50. max_hints_delivery_threads: 2
  51.  
  52. # Maximum throttle in KBs per second, total. This will be
  53. # reduced proportionally to the number of nodes in the cluster.
  54. batchlog_replay_throttle_in_kb: 1024
  55.  
  56. # Authentication backend, implementing IAuthenticator; used to identify users
  57. # Out of the box, Cassandra provides org.apache.cassandra.auth.{AllowAllAuthenticator,
  58. # PasswordAuthenticator}.
  59. #
  60. # - AllowAllAuthenticator performs no checks - set it to disable authentication.
  61. # - PasswordAuthenticator relies on username/password pairs to authenticate
  62. # users. It keeps usernames and hashed passwords in system_auth.credentials table.
  63. # Please increase system_auth keyspace replication factor if you use this authenticator.
  64. authenticator: AllowAllAuthenticator
  65.  
  66. # Authorization backend, implementing IAuthorizer; used to limit access/provide permissions
  67. # Out of the box, Cassandra provides org.apache.cassandra.auth.{AllowAllAuthorizer,
  68. # CassandraAuthorizer}.
  69. #
  70. # - AllowAllAuthorizer allows any action to any user - set it to disable authorization.
  71. # - CassandraAuthorizer stores permissions in system_auth.permissions table. Please
  72. # increase system_auth keyspace replication factor if you use this authorizer.
  73. authorizer: AllowAllAuthorizer
  74.  
  75. # Validity period for permissions cache (fetching permissions can be an
  76. # expensive operation depending on the authorizer, CassandraAuthorizer is
  77. # one example). Defaults to 2000, set to 0 to disable.
  78. # Will be disabled automatically for AllowAllAuthorizer.
  79. permissions_validity_in_ms: 2000
  80.  
  81. # Refresh interval for permissions cache (if enabled).
  82. # After this interval, cache entries become eligible for refresh. Upon next
  83. # access, an async reload is scheduled and the old value returned until it
  84. # completes. If permissions_validity_in_ms is non-zero, then this must be
  85. # also.
  86. # Defaults to the same value as permissions_validity_in_ms.
  87. # permissions_update_interval_in_ms: 1000
  88.  
  89. # The partitioner is responsible for distributing groups of rows (by
  90. # partition key) across nodes in the cluster. You should leave this
  91. # alone for new clusters. The partitioner can NOT be changed without
  92. # reloading all data, so when upgrading you should set this to the
  93. # same partitioner you were already using.
  94. #
  95. # Besides Murmur3Partitioner, partitioners included for backwards
  96. # compatibility include RandomPartitioner, ByteOrderedPartitioner, and
  97. # OrderPreservingPartitioner.
  98. #
  99. partitioner: org.apache.cassandra.dht.Murmur3Partitioner
  100.  
  101. # Directories where Cassandra should store data on disk. Cassandra
  102. # will spread data evenly across them, subject to the granularity of
  103. # the configured compaction strategy.
  104. # If not set, the default directory is $CASSANDRA_HOME/data/data.
  105. # data_file_directories:
  106. # - /var/lib/cassandra/data
  107.  
  108. # commit log. when running on magnetic HDD, this should be a
  109. # separate spindle than the data directories.
  110. # If not set, the default directory is $CASSANDRA_HOME/data/commitlog.
  111. # commitlog_directory: /var/lib/cassandra/commitlog
  112.  
  113. # policy for data disk failures:
  114. # die: shut down gossip and Thrift and kill the JVM for any fs errors or
  115. # single-sstable errors, so the node can be replaced.
  116. # stop_paranoid: shut down gossip and Thrift even for single-sstable errors.
  117. # stop: shut down gossip and Thrift, leaving the node effectively dead, but
  118. # can still be inspected via JMX.
  119. # best_effort: stop using the failed disk and respond to requests based on
  120. # remaining available sstables. This means you WILL see obsolete
  121. # data at CL.ONE!
  122. # ignore: ignore fatal errors and let requests fail, as in pre-1.2 Cassandra
  123. disk_failure_policy: stop
  124.  
  125. # policy for commit disk failures:
  126. # die: shut down gossip and Thrift and kill the JVM, so the node can be replaced.
  127. # stop: shut down gossip and Thrift, leaving the node effectively dead, but
  128. # can still be inspected via JMX.
  129. # stop_commit: shutdown the commit log, letting writes collect but
  130. # continuing to service reads, as in pre-2.0.5 Cassandra
  131. # ignore: ignore fatal errors and let the batches fail
  132. commit_failure_policy: stop
  133.  
  134. # Maximum size of the key cache in memory.
  135. #
  136. # Each key cache hit saves 1 seek and each row cache hit saves 2 seeks at the
  137. # minimum, sometimes more. The key cache is fairly tiny for the amount of
  138. # time it saves, so it's worthwhile to use it at large numbers.
  139. # The row cache saves even more time, but must contain the entire row,
  140. # so it is extremely space-intensive. It's best to only use the
  141. # row cache if you have hot rows or static rows.
  142. #
  143. # NOTE: if you reduce the size, you may not get you hottest keys loaded on startup.
  144. #
  145. # Default value is empty to make it "auto" (min(5% of Heap (in MB), 100MB)). Set to 0 to disable key cache.
  146. key_cache_size_in_mb:
  147.  
  148. # Duration in seconds after which Cassandra should
  149. # save the key cache. Caches are saved to saved_caches_directory as
  150. # specified in this configuration file.
  151. #
  152. # Saved caches greatly improve cold-start speeds, and is relatively cheap in
  153. # terms of I/O for the key cache. Row cache saving is much more expensive and
  154. # has limited use.
  155. #
  156. # Default is 14400 or 4 hours.
  157. key_cache_save_period: 14400
  158.  
  159. # Number of keys from the key cache to save
  160. # Disabled by default, meaning all keys are going to be saved
  161. # key_cache_keys_to_save: 100
  162.  
  163. # Maximum size of the row cache in memory.
  164. # NOTE: if you reduce the size, you may not get you hottest keys loaded on startup.
  165. #
  166. # Default value is 0, to disable row caching.
  167. row_cache_size_in_mb: 0
  168.  
  169. # Duration in seconds after which Cassandra should
  170. # save the row cache. Caches are saved to saved_caches_directory as specified
  171. # in this configuration file.
  172. #
  173. # Saved caches greatly improve cold-start speeds, and is relatively cheap in
  174. # terms of I/O for the key cache. Row cache saving is much more expensive and
  175. # has limited use.
  176. #
  177. # Default is 0 to disable saving the row cache.
  178. row_cache_save_period: 0
  179.  
  180. # Number of keys from the row cache to save
  181. # Disabled by default, meaning all keys are going to be saved
  182. # row_cache_keys_to_save: 100
  183.  
  184. # Maximum size of the counter cache in memory.
  185. #
  186. # Counter cache helps to reduce counter locks' contention for hot counter cells.
  187. # In case of RF = 1 a counter cache hit will cause Cassandra to skip the read before
  188. # write entirely. With RF > 1 a counter cache hit will still help to reduce the duration
  189. # of the lock hold, helping with hot counter cell updates, but will not allow skipping
  190. # the read entirely. Only the local (clock, count) tuple of a counter cell is kept
  191. # in memory, not the whole counter, so it's relatively cheap.
  192. #
  193. # NOTE: if you reduce the size, you may not get you hottest keys loaded on startup.
  194. #
  195. # Default value is empty to make it "auto" (min(2.5% of Heap (in MB), 50MB)). Set to 0 to disable counter cache.
  196. # NOTE: if you perform counter deletes and rely on low gcgs, you should disable the counter cache.
  197. counter_cache_size_in_mb:
  198.  
  199. # Duration in seconds after which Cassandra should
  200. # save the counter cache (keys only). Caches are saved to saved_caches_directory as
  201. # specified in this configuration file.
  202. #
  203. # Default is 7200 or 2 hours.
  204. counter_cache_save_period: 7200
  205.  
  206. # Number of keys from the counter cache to save
  207. # Disabled by default, meaning all keys are going to be saved
  208. # counter_cache_keys_to_save: 100
  209.  
  210. # The off-heap memory allocator. Affects storage engine metadata as
  211. # well as caches. Experiments show that JEMAlloc saves some memory
  212. # than the native GCC allocator (i.e., JEMalloc is more
  213. # fragmentation-resistant).
  214. #
  215. # Supported values are: NativeAllocator, JEMallocAllocator
  216. #
  217. # If you intend to use JEMallocAllocator you have to install JEMalloc as library and
  218. # modify cassandra-env.sh as directed in the file.
  219. #
  220. # Defaults to NativeAllocator
  221. # memory_allocator: NativeAllocator
  222.  
  223. # saved caches
  224. # If not set, the default directory is $CASSANDRA_HOME/data/saved_caches.
  225. # saved_caches_directory: /var/lib/cassandra/saved_caches
  226.  
  227.  
  228.  
  229. # commitlog_sync may be either "periodic" or "batch."
  230. # When in batch mode, Cassandra won't ack writes until the commit log
  231. # has been fsynced to disk. It will wait up to
  232. # commitlog_sync_batch_window_in_ms milliseconds for other writes, before
  233. # performing the sync.
  234. #
  235. # commitlog_sync: batch
  236. # commitlog_sync_batch_window_in_ms: 50
  237. #
  238. # the other option is "periodic" where writes may be acked immediately
  239. # and the CommitLog is simply synced every commitlog_sync_period_in_ms
  240. # milliseconds.
  241. commitlog_sync: periodic
  242. commitlog_sync_period_in_ms: 10000
  243.  
  244. # The size of the individual commitlog file segments. A commitlog
  245. # segment may be archived, deleted, or recycled once all the data
  246. # in it (potentially from each columnfamily in the system) has been
  247. # flushed to sstables.
  248. #
  249. # The default size is 32, which is almost always fine, but if you are
  250. # archiving commitlog segments (see commitlog_archiving.properties),
  251. # then you probably want a finer granularity of archiving; 8 or 16 MB
  252. # is reasonable.
  253. commitlog_segment_size_in_mb: 32
  254.  
  255. # any class that implements the SeedProvider interface and has a
  256. # constructor that takes a Map<String, String> of parameters will do.
  257. seed_provider:
  258. # Addresses of hosts that are deemed contact points.
  259. # Cassandra nodes use this list of hosts to find each other and learn
  260. # the topology of the ring. You must change this if you are running
  261. # multiple nodes!
  262. - class_name: org.apache.cassandra.locator.SimpleSeedProvider
  263. parameters:
  264. # seeds is actually a comma-delimited list of addresses.
  265. # Ex: "<ip1>,<ip2>,<ip3>"
  266. - seeds: "192.168.178.51"
  267.  
  268. # For workloads with more data than can fit in memory, Cassandra's
  269. # bottleneck will be reads that need to fetch data from
  270. # disk. "concurrent_reads" should be set to (16 * number_of_drives) in
  271. # order to allow the operations to enqueue low enough in the stack
  272. # that the OS and drives can reorder them. Same applies to
  273. # "concurrent_counter_writes", since counter writes read the current
  274. # values before incrementing and writing them back.
  275. #
  276. # On the other hand, since writes are almost never IO bound, the ideal
  277. # number of "concurrent_writes" is dependent on the number of cores in
  278. # your system; (8 * number_of_cores) is a good rule of thumb.
  279. concurrent_reads: 32
  280. concurrent_writes: 32
  281. concurrent_counter_writes: 32
  282. # Total memory to use for sstable-reading buffers. Defaults to
  283. # the smaller of 1/4 of heap or 512MB.
  284. # file_cache_size_in_mb: 512
  285.  
  286. # Total permitted memory to use for memtables. Cassandra will stop
  287. # accepting writes when the limit is exceeded until a flush completes,
  288. # and will trigger a flush based on memtable_cleanup_threshold
  289. # If omitted, Cassandra will set both to 1/4 the size of the heap.
  290. # memtable_heap_space_in_mb: 2048
  291. # memtable_offheap_space_in_mb: 2048
  292.  
  293. # Ratio of occupied non-flushing memtable size to total permitted size
  294. # that will trigger a flush of the largest memtable. Lager mct will
  295. # mean larger flushes and hence less compaction, but also less concurrent
  296. # flush activity which can make it difficult to keep your disks fed
  297. # under heavy write load.
  298. #
  299. # memtable_cleanup_threshold defaults to 1 / (memtable_flush_writers + 1)
  300. # memtable_cleanup_threshold: 0.11
  301.  
  302. # Specify the way Cassandra allocates and manages memtable memory.
  303. # Options are:
  304. # heap_buffers: on heap nio buffers
  305. # offheap_buffers: off heap (direct) nio buffers
  306. # offheap_objects: native memory, eliminating nio buffer heap overhead
  307. memtable_allocation_type: heap_buffers
  308.  
  309. # Total space to use for commitlogs. Since commitlog segments are
  310. # mmapped, and hence use up address space, the default size is 32
  311. # on 32-bit JVMs, and 8192 on 64-bit JVMs.
  312. #
  313. # If space gets above this value (it will round up to the next nearest
  314. # segment multiple), Cassandra will flush every dirty CF in the oldest
  315. # segment and remove it. So a small total commitlog space will tend
  316. # to cause more flush activity on less-active columnfamilies.
  317. # commitlog_total_space_in_mb: 8192
  318.  
  319. # This sets the amount of memtable flush writer threads. These will
  320. # be blocked by disk io, and each one will hold a memtable in memory
  321. # while blocked.
  322. #
  323. # memtable_flush_writers defaults to the smaller of (number of disks,
  324. # number of cores), with a minimum of 2 and a maximum of 8.
  325. #
  326. # If your data directories are backed by SSD, you should increase this
  327. # to the number of cores.
  328. #memtable_flush_writers: 8
  329.  
  330. # A fixed memory pool size in MB for for SSTable index summaries. If left
  331. # empty, this will default to 5% of the heap size. If the memory usage of
  332. # all index summaries exceeds this limit, SSTables with low read rates will
  333. # shrink their index summaries in order to meet this limit. However, this
  334. # is a best-effort process. In extreme conditions Cassandra may need to use
  335. # more than this amount of memory.
  336. index_summary_capacity_in_mb:
  337.  
  338. # How frequently index summaries should be resampled. This is done
  339. # periodically to redistribute memory from the fixed-size pool to sstables
  340. # proportional their recent read rates. Setting to -1 will disable this
  341. # process, leaving existing index summaries at their current sampling level.
  342. index_summary_resize_interval_in_minutes: 60
  343.  
  344. # Whether to, when doing sequential writing, fsync() at intervals in
  345. # order to force the operating system to flush the dirty
  346. # buffers. Enable this to avoid sudden dirty buffer flushing from
  347. # impacting read latencies. Almost always a good idea on SSDs; not
  348. # necessarily on platters.
  349. trickle_fsync: false
  350. trickle_fsync_interval_in_kb: 10240
  351.  
  352. # TCP port, for commands and data
  353. storage_port: 7000
  354.  
  355. # SSL port, for encrypted communication. Unused unless enabled in
  356. # encryption_options
  357. ssl_storage_port: 7001
  358.  
  359. # Address or interface to bind to and tell other Cassandra nodes to connect to.
  360. # You _must_ change this if you want multiple nodes to be able to communicate!
  361. #
  362. # Set listen_address OR listen_interface, not both. Interfaces must correspond
  363. # to a single address, IP aliasing is not supported.
  364. #
  365. # Leaving it blank leaves it up to InetAddress.getLocalHost(). This
  366. # will always do the Right Thing _if_ the node is properly configured
  367. # (hostname, name resolution, etc), and the Right Thing is to use the
  368. # address associated with the hostname (it might not be).
  369. #
  370. # Setting listen_address to 0.0.0.0 is always wrong.
  371. listen_address: 192.168.178.51
  372. # listen_interface: eth0
  373.  
  374. # Address to broadcast to other Cassandra nodes
  375. # Leaving this blank will set it to the same value as listen_address
  376. # broadcast_address: 1.2.3.4
  377.  
  378. # Internode authentication backend, implementing IInternodeAuthenticator;
  379. # used to allow/disallow connections from peer nodes.
  380. # internode_authenticator: org.apache.cassandra.auth.AllowAllInternodeAuthenticator
  381.  
  382. # Whether to start the native transport server.
  383. # Please note that the address on which the native transport is bound is the
  384. # same as the rpc_address. The port however is different and specified below.
  385. start_native_transport: true
  386. # port for the CQL native transport to listen for clients on
  387. native_transport_port: 9042
  388. # The maximum threads for handling requests when the native transport is used.
  389. # This is similar to rpc_max_threads though the default differs slightly (and
  390. # there is no native_transport_min_threads, idle threads will always be stopped
  391. # after 30 seconds).
  392. # native_transport_max_threads: 128
  393. #
  394. # The maximum size of allowed frame. Frame (requests) larger than this will
  395. # be rejected as invalid. The default is 256MB.
  396. # native_transport_max_frame_size_in_mb: 256
  397.  
  398. # Whether to start the thrift rpc server.
  399. start_rpc: true
  400.  
  401. # The address or interface to bind the Thrift RPC service and native transport
  402. # server to.
  403. #
  404. # Set rpc_address OR rpc_interface, not both. Interfaces must correspond
  405. # to a single address, IP aliasing is not supported.
  406. #
  407. # Leaving rpc_address blank has the same effect as on listen_address
  408. # (i.e. it will be based on the configured hostname of the node).
  409. #
  410. # Note that unlike listen_address, you can specify 0.0.0.0, but you must also
  411. # set broadcast_rpc_address to a value other than 0.0.0.0.
  412. rpc_address: 0.0.0.0
  413. # rpc_interface: eth1
  414.  
  415. # port for Thrift to listen for clients on
  416. rpc_port: 9160
  417.  
  418. # RPC address to broadcast to drivers and other Cassandra nodes. This cannot
  419. # be set to 0.0.0.0. If left blank, this will be set to the value of
  420. # rpc_address. If rpc_address is set to 0.0.0.0, broadcast_rpc_address must
  421. # be set.
  422. broadcast_rpc_address: 1.2.3.4
  423.  
  424. # enable or disable keepalive on rpc/native connections
  425. rpc_keepalive: true
  426.  
  427. # Cassandra provides two out-of-the-box options for the RPC Server:
  428. #
  429. # sync -> One thread per thrift connection. For a very large number of clients, memory
  430. # will be your limiting factor. On a 64 bit JVM, 180KB is the minimum stack size
  431. # per thread, and that will correspond to your use of virtual memory (but physical memory
  432. # may be limited depending on use of stack space).
  433. #
  434. # hsha -> Stands for "half synchronous, half asynchronous." All thrift clients are handled
  435. # asynchronously using a small number of threads that does not vary with the amount
  436. # of thrift clients (and thus scales well to many clients). The rpc requests are still
  437. # synchronous (one thread per active request). If hsha is selected then it is essential
  438. # that rpc_max_threads is changed from the default value of unlimited.
  439. #
  440. # The default is sync because on Windows hsha is about 30% slower. On Linux,
  441. # sync/hsha performance is about the same, with hsha of course using less memory.
  442. #
  443. # Alternatively, can provide your own RPC server by providing the fully-qualified class name
  444. # of an o.a.c.t.TServerFactory that can create an instance of it.
  445. rpc_server_type: sync
  446.  
  447. # Uncomment rpc_min|max_thread to set request pool size limits.
  448. #
  449. # Regardless of your choice of RPC server (see above), the number of maximum requests in the
  450. # RPC thread pool dictates how many concurrent requests are possible (but if you are using the sync
  451. # RPC server, it also dictates the number of clients that can be connected at all).
  452. #
  453. # The default is unlimited and thus provides no protection against clients overwhelming the server. You are
  454. # encouraged to set a maximum that makes sense for you in production, but do keep in mind that
  455. # rpc_max_threads represents the maximum number of client requests this server may execute concurrently.
  456. #
  457. # rpc_min_threads: 16
  458. # rpc_max_threads: 2048
  459.  
  460. # uncomment to set socket buffer sizes on rpc connections
  461. # rpc_send_buff_size_in_bytes:
  462. # rpc_recv_buff_size_in_bytes:
  463.  
  464. # Uncomment to set socket buffer size for internode communication
  465. # Note that when setting this, the buffer size is limited by net.core.wmem_max
  466. # and when not setting it it is defined by net.ipv4.tcp_wmem
  467. # See:
  468. # /proc/sys/net/core/wmem_max
  469. # /proc/sys/net/core/rmem_max
  470. # /proc/sys/net/ipv4/tcp_wmem
  471. # /proc/sys/net/ipv4/tcp_wmem
  472. # and: man tcp
  473. # internode_send_buff_size_in_bytes:
  474. # internode_recv_buff_size_in_bytes:
  475.  
  476. # Frame size for thrift (maximum message length).
  477. thrift_framed_transport_size_in_mb: 15
  478.  
  479. # Set to true to have Cassandra create a hard link to each sstable
  480. # flushed or streamed locally in a backups/ subdirectory of the
  481. # keyspace data. Removing these links is the operator's
  482. # responsibility.
  483. incremental_backups: false
  484.  
  485. # Whether or not to take a snapshot before each compaction. Be
  486. # careful using this option, since Cassandra won't clean up the
  487. # snapshots for you. Mostly useful if you're paranoid when there
  488. # is a data format change.
  489. snapshot_before_compaction: false
  490.  
  491. # Whether or not a snapshot is taken of the data before keyspace truncation
  492. # or dropping of column families. The STRONGLY advised default of true
  493. # should be used to provide data safety. If you set this flag to false, you will
  494. # lose data on truncation or drop.
  495. auto_snapshot: true
  496.  
  497. # When executing a scan, within or across a partition, we need to keep the
  498. # tombstones seen in memory so we can return them to the coordinator, which
  499. # will use them to make sure other replicas also know about the deleted rows.
  500. # With workloads that generate a lot of tombstones, this can cause performance
  501. # problems and even exaust the server heap.
  502. # (http://www.datastax.com/dev/blog/cassandra-anti-patterns-queues-and-queue-like-datasets)
  503. # Adjust the thresholds here if you understand the dangers and want to
  504. # scan more tombstones anyway. These thresholds may also be adjusted at runtime
  505. # using the StorageService mbean.
  506. tombstone_warn_threshold: 1000
  507. tombstone_failure_threshold: 100000
  508.  
  509. # Granularity of the collation index of rows within a partition.
  510. # Increase if your rows are large, or if you have a very large
  511. # number of rows per partition. The competing goals are these:
  512. # 1) a smaller granularity means more index entries are generated
  513. # and looking up rows withing the partition by collation column
  514. # is faster
  515. # 2) but, Cassandra will keep the collation index in memory for hot
  516. # rows (as part of the key cache), so a larger granularity means
  517. # you can cache more hot rows
  518. column_index_size_in_kb: 64
  519.  
  520.  
  521. # Log WARN on any batch size exceeding this value. 5kb per batch by default.
  522. # Caution should be taken on increasing the size of this threshold as it can lead to node instability.
  523. batch_size_warn_threshold_in_kb: 5
  524.  
  525. # Number of simultaneous compactions to allow, NOT including
  526. # validation "compactions" for anti-entropy repair. Simultaneous
  527. # compactions can help preserve read performance in a mixed read/write
  528. # workload, by mitigating the tendency of small sstables to accumulate
  529. # during a single long running compactions. The default is usually
  530. # fine and if you experience problems with compaction running too
  531. # slowly or too fast, you should look at
  532. # compaction_throughput_mb_per_sec first.
  533. #
  534. # concurrent_compactors defaults to the smaller of (number of disks,
  535. # number of cores), with a minimum of 2 and a maximum of 8.
  536. #
  537. # If your data directories are backed by SSD, you should increase this
  538. # to the number of cores.
  539. #concurrent_compactors: 1
  540.  
  541. # Throttles compaction to the given total throughput across the entire
  542. # system. The faster you insert data, the faster you need to compact in
  543. # order to keep the sstable count down, but in general, setting this to
  544. # 16 to 32 times the rate you are inserting data is more than sufficient.
  545. # Setting this to 0 disables throttling. Note that this account for all types
  546. # of compaction, including validation compaction.
  547. compaction_throughput_mb_per_sec: 16
  548.  
  549. # When compacting, the replacement sstable(s) can be opened before they
  550. # are completely written, and used in place of the prior sstables for
  551. # any range that has been written. This helps to smoothly transfer reads
  552. # between the sstables, reducing page cache churn and keeping hot rows hot
  553. sstable_preemptive_open_interval_in_mb: 50
  554.  
  555. # Throttles all outbound streaming file transfers on this node to the
  556. # given total throughput in Mbps. This is necessary because Cassandra does
  557. # mostly sequential IO when streaming data during bootstrap or repair, which
  558. # can lead to saturating the network connection and degrading rpc performance.
  559. # When unset, the default is 200 Mbps or 25 MB/s.
  560. # stream_throughput_outbound_megabits_per_sec: 200
  561.  
  562. # Throttles all streaming file transfer between the datacenters,
  563. # this setting allows users to throttle inter dc stream throughput in addition
  564. # to throttling all network stream traffic as configured with
  565. # stream_throughput_outbound_megabits_per_sec
  566. # inter_dc_stream_throughput_outbound_megabits_per_sec:
  567.  
  568. # How long the coordinator should wait for read operations to complete
  569. read_request_timeout_in_ms: 5000
  570. # How long the coordinator should wait for seq or index scans to complete
  571. range_request_timeout_in_ms: 10000
  572. # How long the coordinator should wait for writes to complete
  573. write_request_timeout_in_ms: 2000
  574. # How long the coordinator should wait for counter writes to complete
  575. counter_write_request_timeout_in_ms: 5000
  576. # How long a coordinator should continue to retry a CAS operation
  577. # that contends with other proposals for the same row
  578. cas_contention_timeout_in_ms: 1000
  579. # How long the coordinator should wait for truncates to complete
  580. # (This can be much longer, because unless auto_snapshot is disabled
  581. # we need to flush first so we can snapshot before removing the data.)
  582. truncate_request_timeout_in_ms: 60000
  583. # The default timeout for other, miscellaneous operations
  584. request_timeout_in_ms: 10000
  585.  
  586. # Enable operation timeout information exchange between nodes to accurately
  587. # measure request timeouts. If disabled, replicas will assume that requests
  588. # were forwarded to them instantly by the coordinator, which means that
  589. # under overload conditions we will waste that much extra time processing
  590. # already-timed-out requests.
  591. #
  592. # Warning: before enabling this property make sure to ntp is installed
  593. # and the times are synchronized between the nodes.
  594. cross_node_timeout: false
  595.  
  596. # Enable socket timeout for streaming operation.
  597. # When a timeout occurs during streaming, streaming is retried from the start
  598. # of the current file. This _can_ involve re-streaming an important amount of
  599. # data, so you should avoid setting the value too low.
  600. # Default value is 0, which never timeout streams.
  601. # streaming_socket_timeout_in_ms: 0
  602.  
  603. # phi value that must be reached for a host to be marked down.
  604. # most users should never need to adjust this.
  605. # phi_convict_threshold: 8
  606.  
  607. # endpoint_snitch -- Set this to a class that implements
  608. # IEndpointSnitch. The snitch has two functions:
  609. # - it teaches Cassandra enough about your network topology to route
  610. # requests efficiently
  611. # - it allows Cassandra to spread replicas around your cluster to avoid
  612. # correlated failures. It does this by grouping machines into
  613. # "datacenters" and "racks." Cassandra will do its best not to have
  614. # more than one replica on the same "rack" (which may not actually
  615. # be a physical location)
  616. #
  617. # IF YOU CHANGE THE SNITCH AFTER DATA IS INSERTED INTO THE CLUSTER,
  618. # YOU MUST RUN A FULL REPAIR, SINCE THE SNITCH AFFECTS WHERE REPLICAS
  619. # ARE PLACED.
  620. #
  621. # Out of the box, Cassandra provides
  622. # - SimpleSnitch:
  623. # Treats Strategy order as proximity. This can improve cache
  624. # locality when disabling read repair. Only appropriate for
  625. # single-datacenter deployments.
  626. # - GossipingPropertyFileSnitch
  627. # This should be your go-to snitch for production use. The rack
  628. # and datacenter for the local node are defined in
  629. # cassandra-rackdc.properties and propagated to other nodes via
  630. # gossip. If cassandra-topology.properties exists, it is used as a
  631. # fallback, allowing migration from the PropertyFileSnitch.
  632. # - PropertyFileSnitch:
  633. # Proximity is determined by rack and data center, which are
  634. # explicitly configured in cassandra-topology.properties.
  635. # - Ec2Snitch:
  636. # Appropriate for EC2 deployments in a single Region. Loads Region
  637. # and Availability Zone information from the EC2 API. The Region is
  638. # treated as the datacenter, and the Availability Zone as the rack.
  639. # Only private IPs are used, so this will not work across multiple
  640. # Regions.
  641. # - Ec2MultiRegionSnitch:
  642. # Uses public IPs as broadcast_address to allow cross-region
  643. # connectivity. (Thus, you should set seed addresses to the public
  644. # IP as well.) You will need to open the storage_port or
  645. # ssl_storage_port on the public IP firewall. (For intra-Region
  646. # traffic, Cassandra will switch to the private IP after
  647. # establishing a connection.)
  648. # - RackInferringSnitch:
  649. # Proximity is determined by rack and data center, which are
  650. # assumed to correspond to the 3rd and 2nd octet of each node's IP
  651. # address, respectively. Unless this happens to match your
  652. # deployment conventions, this is best used as an example of
  653. # writing a custom Snitch class and is provided in that spirit.
  654. #
  655. # You can use a custom Snitch by setting this to the full class name
  656. # of the snitch, which will be assumed to be on your classpath.
  657. endpoint_snitch: RackInferringSnitch
  658.  
  659. # controls how often to perform the more expensive part of host score
  660. # calculation
  661. dynamic_snitch_update_interval_in_ms: 100
  662. # controls how often to reset all host scores, allowing a bad host to
  663. # possibly recover
  664. dynamic_snitch_reset_interval_in_ms: 600000
  665. # if set greater than zero and read_repair_chance is < 1.0, this will allow
  666. # 'pinning' of replicas to hosts in order to increase cache capacity.
  667. # The badness threshold will control how much worse the pinned host has to be
  668. # before the dynamic snitch will prefer other replicas over it. This is
  669. # expressed as a double which represents a percentage. Thus, a value of
  670. # 0.2 means Cassandra would continue to prefer the static snitch values
  671. # until the pinned host was 20% worse than the fastest.
  672. dynamic_snitch_badness_threshold: 0.1
  673.  
  674. # request_scheduler -- Set this to a class that implements
  675. # RequestScheduler, which will schedule incoming client requests
  676. # according to the specific policy. This is useful for multi-tenancy
  677. # with a single Cassandra cluster.
  678. # NOTE: This is specifically for requests from the client and does
  679. # not affect inter node communication.
  680. # org.apache.cassandra.scheduler.NoScheduler - No scheduling takes place
  681. # org.apache.cassandra.scheduler.RoundRobinScheduler - Round robin of
  682. # client requests to a node with a separate queue for each
  683. # request_scheduler_id. The scheduler is further customized by
  684. # request_scheduler_options as described below.
  685. request_scheduler: org.apache.cassandra.scheduler.NoScheduler
  686.  
  687. # Scheduler Options vary based on the type of scheduler
  688. # NoScheduler - Has no options
  689. # RoundRobin
  690. # - throttle_limit -- The throttle_limit is the number of in-flight
  691. # requests per client. Requests beyond
  692. # that limit are queued up until
  693. # running requests can complete.
  694. # The value of 80 here is twice the number of
  695. # concurrent_reads + concurrent_writes.
  696. # - default_weight -- default_weight is optional and allows for
  697. # overriding the default which is 1.
  698. # - weights -- Weights are optional and will default to 1 or the
  699. # overridden default_weight. The weight translates into how
  700. # many requests are handled during each turn of the
  701. # RoundRobin, based on the scheduler id.
  702. #
  703. # request_scheduler_options:
  704. # throttle_limit: 80
  705. # default_weight: 5
  706. # weights:
  707. # Keyspace1: 1
  708. # Keyspace2: 5
  709.  
  710. # request_scheduler_id -- An identifier based on which to perform
  711. # the request scheduling. Currently the only valid option is keyspace.
  712. # request_scheduler_id: keyspace
  713.  
  714. # Enable or disable inter-node encryption
  715. # Default settings are TLS v1, RSA 1024-bit keys (it is imperative that
  716. # users generate their own keys) TLS_RSA_WITH_AES_128_CBC_SHA as the cipher
  717. # suite for authentication, key exchange and encryption of the actual data transfers.
  718. # Use the DHE/ECDHE ciphers if running in FIPS 140 compliant mode.
  719. # NOTE: No custom encryption options are enabled at the moment
  720. # The available internode options are : all, none, dc, rack
  721. #
  722. # If set to dc cassandra will encrypt the traffic between the DCs
  723. # If set to rack cassandra will encrypt the traffic between the racks
  724. #
  725. # The passwords used in these options must match the passwords used when generating
  726. # the keystore and truststore. For instructions on generating these files, see:
  727. # http://download.oracle.com/javase/6/docs/technotes/guides/security/jsse/JSSERefGuide.html#CreateKeystore
  728. #
  729. server_encryption_options:
  730. internode_encryption: none
  731. keystore: conf/.keystore
  732. keystore_password: cassandra
  733. truststore: conf/.truststore
  734. truststore_password: cassandra
  735. # More advanced defaults below:
  736. # protocol: TLS
  737. # algorithm: SunX509
  738. # store_type: JKS
  739. # cipher_suites: [TLS_RSA_WITH_AES_128_CBC_SHA,TLS_RSA_WITH_AES_256_CBC_SHA,TLS_DHE_RSA_WITH_AES_128_CBC_SHA,TLS_DHE_RSA_WITH_AES_256_CBC_SHA,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA]
  740. # require_client_auth: false
  741.  
  742. # enable or disable client/server encryption.
  743. client_encryption_options:
  744. enabled: false
  745. keystore: conf/.keystore
  746. keystore_password: cassandra
  747. # require_client_auth: false
  748. # Set trustore and truststore_password if require_client_auth is true
  749. # truststore: conf/.truststore
  750. # truststore_password: cassandra
  751. # More advanced defaults below:
  752. # protocol: TLS
  753. # algorithm: SunX509
  754. # store_type: JKS
  755. # cipher_suites: [TLS_RSA_WITH_AES_128_CBC_SHA,TLS_RSA_WITH_AES_256_CBC_SHA,TLS_DHE_RSA_WITH_AES_128_CBC_SHA,TLS_DHE_RSA_WITH_AES_256_CBC_SHA,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA]
  756.  
  757. # internode_compression controls whether traffic between nodes is
  758. # compressed.
  759. # can be: all - all traffic is compressed
  760. # dc - traffic between different datacenters is compressed
  761. # none - nothing is compressed.
  762. internode_compression: all
  763.  
  764. # Enable or disable tcp_nodelay for inter-dc communication.
  765. # Disabling it will result in larger (but fewer) network packets being sent,
  766. # reducing overhead from the TCP protocol itself, at the cost of increasing
  767. # latency if you block for cross-datacenter responses.
  768. inter_dc_tcp_nodelay: false
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement