Created
May 5, 2017 02:20
-
-
Save vadimtk/8535ca71bd45a5dcf7322ff0971d1960 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Percona Server template configuration | |
[mysqld] | |
# | |
# Remove leading # and set to the amount of RAM for the most important data | |
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%. | |
# | |
# Remove leading # to turn on a very important data integrity option: logging | |
# changes to the binary log between backups. | |
# log_bin | |
# | |
# Remove leading # to set options mainly useful for reporting servers. | |
# The server defaults are faster for transactions and fast SELECTs. | |
# Adjust sizes as needed, experiment to find the optimal values. | |
# join_buffer_size = 128M | |
# sort_buffer_size = 2M | |
# read_rnd_buffer_size = 2M | |
datadir=/data/mysql/sb_t12_r10m | |
socket=/tmp/mysql.sock | |
ssl=0 | |
#server_id=1 | |
#log-bin=binlog | |
plugin-load=rocksdb=ha_rocksdb.so;rocksdb_cfstats=ha_rocksdb.so;rocksdb_dbstats=ha_rocksdb.so;rocksdb_perf_context=ha_rocksdb.so;rocksdb_perf_context_global=ha_rocksdb.so;rocksdb_cf_options=ha_rocksdb.so;rocksdb_compaction_stats=ha_rocksdb.so;rocksdb_global_info=ha_rocksdb.so;rocksdb_ddl=ha_rocksdb.so;rocksdb_index_file_map=ha_rocksdb.so;rocksdb_locks=ha_rocksdb.so;rocksdb_trx=ha_rocksdb.so | |
# Disabling symbolic-links is recommended to prevent assorted security risks | |
symbolic-links=0 | |
# general | |
table_open_cache = 200000 | |
table_open_cache_instances=64 | |
back_log=1500 | |
query_cache_type=0 | |
max_connections=4000 | |
# files | |
innodb_file_per_table | |
innodb_log_file_size=15G | |
innodb_log_files_in_group=2 | |
innodb_open_files=4000 | |
# buffers | |
innodb_buffer_pool_size= 150G | |
innodb_buffer_pool_instances=8 | |
innodb_log_buffer_size=64M | |
innodb_adaptive_hash_index=0 | |
innodb_adaptive_hash_index_parts=13 | |
# tune | |
innodb_doublewrite= 1 | |
innodb_thread_concurrency=0 | |
innodb_flush_log_at_trx_commit= 1 | |
innodb_flush_method=O_DIRECT_NO_FSYNC | |
innodb_max_dirty_pages_pct=90 | |
innodb_max_dirty_pages_pct_lwm=10 | |
innodb_lru_scan_depth=4096 | |
innodb_page_cleaners=8 | |
join_buffer_size=32K | |
sort_buffer_size=32K | |
innodb_use_native_aio=1 | |
innodb_stats_persistent = 1 | |
# perf special | |
innodb_adaptive_flushing = 1 | |
innodb_flush_neighbors = 0 | |
innodb_read_io_threads = 8 | |
innodb_write_io_threads = 8 | |
innodb_io_capacity=4000 | |
innodb_io_capacity_max=6000 | |
innodb_purge_threads=4 | |
innodb_max_purge_lag_delay=10000000 | |
innodb_max_purge_lag=0 | |
# Monitoring | |
#innodb_monitor_enable = '%' | |
#performance_schema=OFF | |
#performance_schema=ON | |
#performance-schema-instrument='wait/synch/%=ON' | |
#log-error=mysqld.log | |
transaction-isolation=READ-COMMITTED | |
collation_server=latin1_bin | |
rocksdb_max_open_files=-1 | |
rocksdb_base_background_compactions=1 | |
rocksdb_max_background_compactions=8 | |
rocksdb_max_total_wal_size=4G | |
rocksdb_max_background_flushes=4 | |
rocksdb_block_size=16384 | |
rocksdb_table_cache_numshardbits=6 | |
rocksdb_bytes_per_sync=4194304 | |
rocksdb_wal_bytes_per_sync=4194304 | |
# triggering compaction if there are many sequential deletes | |
rocksdb_compaction_sequential_deletes_count_sd=1 | |
rocksdb_compaction_sequential_deletes=199999 | |
rocksdb_compaction_sequential_deletes_window=200000 | |
rocksdb_block_cache_size=150G | |
# ... to disable compression | |
rocksdb_default_cf_options=write_buffer_size=64m;target_file_size_base=32m;max_bytes_for_level_base=512m;level0_file_num_compaction_trigger=4;level0_slowdown_writes_trigger=20;level0_stop_writes_trigger=30;max_write_buffer_number=4;compression_per_level=kNoCompression:kNoCompression:kNoCompression:kNoCompression:kNoCompression:kNoCompression;bottommost_compression=kNoCompression;block_based_table_factory={cache_index_and_filter_blocks=1;filter_policy=bloomfilter:10:false;whole_key_filtering=1};level_compaction_dynamic_level_bytes=true;optimize_filters_for_hits=true | |
# | |
#rocksdb_use_direct_writes=ON | |
#rocksdb_use_direct_reads=ON |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment