# Template my.cnf for PXC # Edit to your requirements. [mysqld] report-host = mphdb21 server-id = 1 character_set_server = utf8 collation_server = utf8_general_ci event-scheduler = ON sql_mode = "NO_AUTO_VALUE_ON_ZERO,STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION" secure_auth = 1 datadir = /data/mysql socket = /var/run/mysqld/mysqld.sock #log-error = /var/log/mysqld.log pid-file = /var/run/mysqld/mysqld.pid log-bin log_slave_updates expire_logs_days = 10 user = mysql innodb_tmpdir = /data/tmp tmpdir = /data/tmp group_concat_max_len = 100000 max_sp_recursion_depth = 10 log-timestamps = SYSTEM federated safe_to_bootstrap = 1 # Disabling symbolic-links is recommended to prevent assorted security risks symbolic-links=0 # Path to Galera library wsrep_provider=/usr/lib/libgalera_smm.so # Cluster name wsrep_cluster_name=pxc-cluster # Cluster connection URL contains the IPs of node#1, node#2 and node#3 wsrep_cluster_address=gcomm:// #wsrep_cluster_address=gcomm://172.20.5.41,172.20.5.42,172.20.5.43 # Node #1 address wsrep_node_name=mphdb21 wsrep_node_address=172.20.5.41 # SST method wsrep_sst_method=xtrabackup-v2 # Authentication for SST method wsrep_sst_auth=sstuser:Passw0rd # replicate MyISAM tables wsrep_replicate_myisam=ON pxc_strict_mode=ENFORCING # In order for Galera to work correctly binlog format should be ROW binlog_format=ROW # MyISAM storage engine has only experimental support default_storage_engine=InnoDB # This InnoDB autoincrement locking mode is a requirement for Galera innodb_autoinc_lock_mode=2 # # * Fine Tuning # join_buffer_size = 256K key_buffer_size = 8G max_allowed_packet = 1G thread_stack = 256K thread_cache_size = 8 max_connections = 512 # # * Table Cache Configuration # table_definition_cache = 912 table_open_cache = 1024 # # * Query Cache Configuration # query_cache_size = 0 query_cache_type = 0 # # * Logging and Replication # # Both location gets rotated by the cronjob. # Be aware that this log type is a performance killer. # As of 5.1 you can enable the log at runtime! general_log_file = /var/log/mysql/mysql.log general_log = 0 # # Error log - should be very few entries. # log-error = /var/log/mysql/error.log log_warnings = 2 # # Here you can see queries with especially long duration slow_query_log_file = /var/log/mysql/mysql-slow.log long_query_time = 10 log-queries-not-using-indexes # # The following can be used as easy to replay backup logs or for replication. # note: if you are setting up a replication slave, see README.Debian about # other settings you may need to change. #log_bin = mysql-bin #log_bin_index = mysql-bin.index log_bin = /data/logs/binlogs/mysql-bin log_bin_index = /data/logs/binlogs/mysql-bin.index max_binlog_size = 1G sync_binlog = 1 # # * InnoDB # # InnoDB is enabled by default with a 10MB datafile in /var/lib/mysql/. # Read the manual for more InnoDB related options. There are many! innodb_log_buffer_size = 768M innodb_log_files_in_group = 2 innodb_log_file_size = 1G innodb_file_per_table = 1 innodb_buffer_pool_size = 80G innodb_buffer_pool_instances = 64 innodb_flush_log_at_trx_commit = 1 innodb_page_cleaners = 8