自己经历的mysql cluter配置过程(二)配置文件 自己经历的mysql cluter配置过程

76.my.cnf

自己经历的mysql cluter配置过程(二)配置文件#mple MySQL config file for medium systems.
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# This is for a system with little memory (32M - 64M) where MySQL plays
自己经历的mysql cluter配置过程(二)配置文件# an important part
, or systems up to 128M where MySQL is used together with
自己经历的mysql cluter配置过程(二)配置文件# other programs (such as a web server)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# You can copy this file to
自己经历的mysql cluter配置过程(二)配置文件# /etc/my.cnf to set global options
,
自己经历的mysql cluter配置过程(二)配置文件# mysql-data-dir/my.cnf to set server-specific options (in this
自己经历的mysql cluter配置过程(二)配置文件# installation this directory is /var/lib/mysql) or
自己经历的mysql cluter配置过程(二)配置文件# ~/.my.cnf to set user-specific options.
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# In this file
, you can use all long options that a program supports.
自己经历的mysql cluter配置过程(二)配置文件# If you want to know which options a program supports
, run the program
自己经历的mysql cluter配置过程(二)配置文件# with the 
"--help" option.
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# The following options will be passed to all MySQL clients
自己经历的mysql cluter配置过程(二)配置文件
[client]
自己经历的mysql cluter配置过程(二)配置文件#password    
= your_password
自己经历的mysql cluter配置过程(二)配置文件port        
= 3307
自己经历的mysql cluter配置过程(二)配置文件socket        
= /var/lib/mysql/mysql.sock
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Here follows entries for some specific programs
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# The MySQL server
自己经历的mysql cluter配置过程(二)配置文件
[mysqld]
自己经历的mysql cluter配置过程(二)配置文件datadir     
= /var/lib/mysql
自己经历的mysql cluter配置过程(二)配置文件user        
= root
自己经历的mysql cluter配置过程(二)配置文件port        
= 3306
自己经历的mysql cluter配置过程(二)配置文件socket        
= /var/lib/mysql/mysql.sock
自己经历的mysql cluter配置过程(二)配置文件skip-locking
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 16M
自己经历的mysql cluter配置过程(二)配置文件max_allowed_packet 
= 1M
自己经历的mysql cluter配置过程(二)配置文件table_cache 
= 64
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 512K
自己经历的mysql cluter配置过程(二)配置文件net_buffer_length 
= 8K
自己经历的mysql cluter配置过程(二)配置文件read_buffer_size 
= 256K
自己经历的mysql cluter配置过程(二)配置文件read_rnd_buffer_size 
= 512K
自己经历的mysql cluter配置过程(二)配置文件myisam_sort_buffer_size 
= 8M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件#datadir        
= /mysqldata
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Don't listen on a TCP/IP port at all. This can be a security enhancement
,
自己经历的mysql cluter配置过程(二)配置文件# if all processes that need to connect to mysqld run on the same host.
自己经历的mysql cluter配置过程(二)配置文件# All interaction with mysqld must be made via Unix sockets or named pipes.
自己经历的mysql cluter配置过程(二)配置文件# Note that using this option without enabling named pipes on Windows
自己经历的mysql cluter配置过程(二)配置文件# (via the 
"enable-named-pipe" option) will render mysqld useless!
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件#skip-networking
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Replication Master Server (default)
自己经历的mysql cluter配置过程(二)配置文件# binary logging is required for replication
自己经历的mysql cluter配置过程(二)配置文件log-bin
=mysql-bin
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# required unique id between 
1 and 2^32 - 1
自己经历的mysql cluter配置过程(二)配置文件# defaults to 
1 if master-host is not set
自己经历的mysql cluter配置过程(二)配置文件# but will not function as a master if omitted
自己经历的mysql cluter配置过程(二)配置文件server-id    
= 1
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Replication Slave (comment out master section to use this)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# To configure this host as a replication slave
, you can choose between
自己经历的mysql cluter配置过程(二)配置文件# two methods :
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件
1) Use the CHANGE MASTER TO command (fully described in our manual) -
自己经历的mysql cluter配置过程(二)配置文件#    the syntax is:
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    CHANGE MASTER TO MASTER_HOST
=<host>, MASTER_PORT=<port>,
自己经历的mysql cluter配置过程(二)配置文件#    MASTER_USER
=<user>, MASTER_PASSWORD=<password> ;
自己经历的mysql cluter配置过程(二)配置文件
#
自己经历的mysql cluter配置过程(二)配置文件#    where you replace <host>
, <user>, <password> by quoted strings and
自己经历的mysql cluter配置过程(二)配置文件#    <port> by the master's port number (
3306 by default).
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    Example:
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    CHANGE MASTER TO MASTER_HOST
='125.564.12.1', MASTER_PORT=3306,
自己经历的mysql cluter配置过程(二)配置文件#    MASTER_USER
='joe', MASTER_PASSWORD='secret';
自己经历的mysql cluter配置过程(二)配置文件
#
自己经历的mysql cluter配置过程(二)配置文件# OR
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件
2) Set the variables below. However, in case you choose this method, then
自己经历的mysql cluter配置过程(二)配置文件#    start replication for the first time (even unsuccessfully
, for example
自己经历的mysql cluter配置过程(二)配置文件#    if you mistyped the password in master-password and the slave fails to
自己经历的mysql cluter配置过程(二)配置文件#    connect)
, the slave will create a master.info file, and any later
自己经历的mysql cluter配置过程(二)配置文件#    change in this file to the variables' values below will be ignored and
自己经历的mysql cluter配置过程(二)配置文件#    overridden by the content of the master.info file
, unless you shutdown
自己经历的mysql cluter配置过程(二)配置文件#    the slave server
, delete master.info and restart the slaver server.
自己经历的mysql cluter配置过程(二)配置文件#    For that reason
, you may want to leave the lines below untouched
自己经历的mysql cluter配置过程(二)配置文件#    (commented) and instead use CHANGE MASTER TO (see above)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# required unique id between 
2 and 2^32 - 1
自己经历的mysql cluter配置过程(二)配置文件# (and different from the master)
自己经历的mysql cluter配置过程(二)配置文件# defaults to 
2 if master-host is set
自己经历的mysql cluter配置过程(二)配置文件# but will not function as a slave if omitted
自己经历的mysql cluter配置过程(二)配置文件#server-id       
= 2
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The replication master for this slave - required
自己经历的mysql cluter配置过程(二)配置文件#master-host     
=   <hostname>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The username the slave will use for authentication when connecting
自己经历的mysql cluter配置过程(二)配置文件# to the master - required
自己经历的mysql cluter配置过程(二)配置文件#master-user     
=   <username>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The password the slave will authenticate with when connecting to
自己经历的mysql cluter配置过程(二)配置文件# the master - required
自己经历的mysql cluter配置过程(二)配置文件#master-password 
=   <password>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The port the master is listening on.
自己经历的mysql cluter配置过程(二)配置文件# optional - defaults to 
3306
自己经历的mysql cluter配置过程(二)配置文件#master-port     
=  <port>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# binary logging - not required for slaves
, but recommended
自己经历的mysql cluter配置过程(二)配置文件#log-bin
=mysql-bin
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Point the following paths to different dedicated disks
自己经历的mysql cluter配置过程(二)配置文件#tmpdir        
= /tmp/        
自己经历的mysql cluter配置过程(二)配置文件#log-update     
= /path-to-dedicated-directory/hostname
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Uncomment the following if you are using BDB tables
自己经历的mysql cluter配置过程(二)配置文件#bdb_cache_size 
= 4M
自己经历的mysql cluter配置过程(二)配置文件#bdb_max_lock 
= 10000
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Uncomment the following if you are using InnoDB tables
自己经历的mysql cluter配置过程(二)配置文件innodb_data_home_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件innodb_data_file_path 
= ibdata1:10M:autoextend
自己经历的mysql cluter配置过程(二)配置文件innodb_log_group_home_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_arch_dir 
= /var/lib/mysql
自己经历的mysql cluter配置过程(二)配置文件# You can set .._buffer_pool_size up to 
50 - 80 %
自己经历的mysql cluter配置过程(二)配置文件# of RAM but beware of setting memory usage too high
自己经历的mysql cluter配置过程(二)配置文件innodb_buffer_pool_size 
= 16M
自己经历的mysql cluter配置过程(二)配置文件innodb_additional_mem_pool_size 
= 2M
自己经历的mysql cluter配置过程(二)配置文件# Set .._log_file_size to 
25 % of buffer pool size
自己经历的mysql cluter配置过程(二)配置文件innodb_log_file_size 
= 5M
自己经历的mysql cluter配置过程(二)配置文件innodb_log_buffer_size 
= 8M
自己经历的mysql cluter配置过程(二)配置文件innodb_flush_log_at_trx_commit 
= 1
自己经历的mysql cluter配置过程(二)配置文件innodb_lock_wait_timeout 
= 50
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件ndbcluster                      # run NDB storage engine
自己经历的mysql cluter配置过程(二)配置文件ndb-connectstring
=192.168.1.79  # location of management server
自己经历的mysql cluter配置过程(二)配置文件
[mysqldump]
自己经历的mysql cluter配置过程(二)配置文件quick
自己经历的mysql cluter配置过程(二)配置文件max_allowed_packet 
= 16M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysql]
自己经历的mysql cluter配置过程(二)配置文件no-auto-rehash
自己经历的mysql cluter配置过程(二)配置文件# Remove the next comment character if you are not familiar with SQL
自己经历的mysql cluter配置过程(二)配置文件#safe-updates
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[isamchk]
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 20M
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 20M
自己经历的mysql cluter配置过程(二)配置文件read_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件write_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[myisamchk]
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 20M
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 20M
自己经历的mysql cluter配置过程(二)配置文件read_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件write_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysqlhotcopy]
自己经历的mysql cluter配置过程(二)配置文件interactive-timeout
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[MYSQL_CLUSTER]
自己经历的mysql cluter配置过程(二)配置文件ndb-connectstring
=192.168.1.79  # location of management server
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件

 

16.my.cnf

 

自己经历的mysql cluter配置过程(二)配置文件# Example MySQL config file for medium systems.
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# This is for a system with little memory (32M - 64M) where MySQL plays
自己经历的mysql cluter配置过程(二)配置文件# an important part
, or systems up to 128M where MySQL is used together with
自己经历的mysql cluter配置过程(二)配置文件# other programs (such as a web server)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# You can copy this file to
自己经历的mysql cluter配置过程(二)配置文件# /etc/my.cnf to set global options
,
自己经历的mysql cluter配置过程(二)配置文件# mysql-data-dir/my.cnf to set server-specific options (in this
自己经历的mysql cluter配置过程(二)配置文件# installation this directory is /var/lib/mysql) or
自己经历的mysql cluter配置过程(二)配置文件# ~/.my.cnf to set user-specific options.
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# In this file
, you can use all long options that a program supports.
自己经历的mysql cluter配置过程(二)配置文件# If you want to know which options a program supports
, run the program
自己经历的mysql cluter配置过程(二)配置文件# with the 
"--help" option.
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# The following options will be passed to all MySQL clients
自己经历的mysql cluter配置过程(二)配置文件
[client]
自己经历的mysql cluter配置过程(二)配置文件#password    
= your_password
自己经历的mysql cluter配置过程(二)配置文件port        
= 3306
自己经历的mysql cluter配置过程(二)配置文件socket        
= /var/lib/mysql/mysql.sock
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Here follows entries for some specific programs
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# The MySQL server
自己经历的mysql cluter配置过程(二)配置文件
[mysqld]
自己经历的mysql cluter配置过程(二)配置文件port        
= 3306
自己经历的mysql cluter配置过程(二)配置文件socket        
= /var/lib/mysql/mysql.sock
自己经历的mysql cluter配置过程(二)配置文件skip-locking
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 16M
自己经历的mysql cluter配置过程(二)配置文件max_allowed_packet 
= 1M
自己经历的mysql cluter配置过程(二)配置文件table_cache 
= 64
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 512K
自己经历的mysql cluter配置过程(二)配置文件net_buffer_length 
= 8K
自己经历的mysql cluter配置过程(二)配置文件read_buffer_size 
= 256K
自己经历的mysql cluter配置过程(二)配置文件read_rnd_buffer_size 
= 512K
自己经历的mysql cluter配置过程(二)配置文件myisam_sort_buffer_size 
= 8M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件ndbcluster                      # run NDB storage engine
自己经历的mysql cluter配置过程(二)配置文件ndb-connectstring
=192.168.1.79  # location of management server
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Don't listen on a TCP/IP port at all. This can be a security enhancement
,
自己经历的mysql cluter配置过程(二)配置文件# if all processes that need to connect to mysqld run on the same host.
自己经历的mysql cluter配置过程(二)配置文件# All interaction with mysqld must be made via Unix sockets or named pipes.
自己经历的mysql cluter配置过程(二)配置文件# Note that using this option without enabling named pipes on Windows
自己经历的mysql cluter配置过程(二)配置文件# (via the 
"enable-named-pipe" option) will render mysqld useless!
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件#skip-networking
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Replication Master Server (default)
自己经历的mysql cluter配置过程(二)配置文件# binary logging is required for replication
自己经历的mysql cluter配置过程(二)配置文件log-bin
=mysql-bin
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# required unique id between 
1 and 2^32 - 1
自己经历的mysql cluter配置过程(二)配置文件# defaults to 
1 if master-host is not set
自己经历的mysql cluter配置过程(二)配置文件# but will not function as a master if omitted
自己经历的mysql cluter配置过程(二)配置文件server-id    
= 1
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Replication Slave (comment out master section to use this)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# To configure this host as a replication slave
, you can choose between
自己经历的mysql cluter配置过程(二)配置文件# two methods :
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件
1) Use the CHANGE MASTER TO command (fully described in our manual) -
自己经历的mysql cluter配置过程(二)配置文件#    the syntax is:
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    CHANGE MASTER TO MASTER_HOST
=<host>, MASTER_PORT=<port>,
自己经历的mysql cluter配置过程(二)配置文件#    MASTER_USER
=<user>, MASTER_PASSWORD=<password> ;
自己经历的mysql cluter配置过程(二)配置文件
#
自己经历的mysql cluter配置过程(二)配置文件#    where you replace <host>
, <user>, <password> by quoted strings and
自己经历的mysql cluter配置过程(二)配置文件#    <port> by the master's port number (
3306 by default).
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    Example:
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    CHANGE MASTER TO MASTER_HOST
='125.564.12.1', MASTER_PORT=3306,
自己经历的mysql cluter配置过程(二)配置文件#    MASTER_USER
='joe', MASTER_PASSWORD='secret';
自己经历的mysql cluter配置过程(二)配置文件
#
自己经历的mysql cluter配置过程(二)配置文件# OR
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件
2) Set the variables below. However, in case you choose this method, then
自己经历的mysql cluter配置过程(二)配置文件#    start replication for the first time (even unsuccessfully
, for example
自己经历的mysql cluter配置过程(二)配置文件#    if you mistyped the password in master-password and the slave fails to
自己经历的mysql cluter配置过程(二)配置文件#    connect)
, the slave will create a master.info file, and any later
自己经历的mysql cluter配置过程(二)配置文件#    change in this file to the variables' values below will be ignored and
自己经历的mysql cluter配置过程(二)配置文件#    overridden by the content of the master.info file
, unless you shutdown
自己经历的mysql cluter配置过程(二)配置文件#    the slave server
, delete master.info and restart the slaver server.
自己经历的mysql cluter配置过程(二)配置文件#    For that reason
, you may want to leave the lines below untouched
自己经历的mysql cluter配置过程(二)配置文件#    (commented) and instead use CHANGE MASTER TO (see above)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# required unique id between 
2 and 2^32 - 1
自己经历的mysql cluter配置过程(二)配置文件# (and different from the master)
自己经历的mysql cluter配置过程(二)配置文件# defaults to 
2 if master-host is set
自己经历的mysql cluter配置过程(二)配置文件# but will not function as a slave if omitted
自己经历的mysql cluter配置过程(二)配置文件#server-id       
= 2
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The replication master for this slave - required
自己经历的mysql cluter配置过程(二)配置文件#master-host     
=   <hostname>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The username the slave will use for authentication when connecting
自己经历的mysql cluter配置过程(二)配置文件# to the master - required
自己经历的mysql cluter配置过程(二)配置文件#master-user     
=   <username>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The password the slave will authenticate with when connecting to
自己经历的mysql cluter配置过程(二)配置文件# the master - required
自己经历的mysql cluter配置过程(二)配置文件#master-password 
=   <password>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The port the master is listening on.
自己经历的mysql cluter配置过程(二)配置文件# optional - defaults to 
3306
自己经历的mysql cluter配置过程(二)配置文件#master-port     
=  <port>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# binary logging - not required for slaves
, but recommended
自己经历的mysql cluter配置过程(二)配置文件#log-bin
=mysql-bin
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Point the following paths to different dedicated disks
自己经历的mysql cluter配置过程(二)配置文件#tmpdir        
= /tmp/        
自己经历的mysql cluter配置过程(二)配置文件#log-update     
= /path-to-dedicated-directory/hostname
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Uncomment the following if you are using BDB tables
自己经历的mysql cluter配置过程(二)配置文件#bdb_cache_size 
= 4M
自己经历的mysql cluter配置过程(二)配置文件#bdb_max_lock 
= 10000
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Uncomment the following if you are using InnoDB tables
自己经历的mysql cluter配置过程(二)配置文件#innodb_data_home_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件#innodb_data_file_path 
= ibdata1:10M:autoextend
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_group_home_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_arch_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件# You can set .._buffer_pool_size up to 
50 - 80 %
自己经历的mysql cluter配置过程(二)配置文件# of RAM but beware of setting memory usage too high
自己经历的mysql cluter配置过程(二)配置文件#innodb_buffer_pool_size 
= 16M
自己经历的mysql cluter配置过程(二)配置文件#innodb_additional_mem_pool_size 
= 2M
自己经历的mysql cluter配置过程(二)配置文件# Set .._log_file_size to 
25 % of buffer pool size
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_file_size 
= 5M
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_buffer_size 
= 8M
自己经历的mysql cluter配置过程(二)配置文件#innodb_flush_log_at_trx_commit 
= 1
自己经历的mysql cluter配置过程(二)配置文件#innodb_lock_wait_timeout 
= 50
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysqldump]
自己经历的mysql cluter配置过程(二)配置文件quick
自己经历的mysql cluter配置过程(二)配置文件max_allowed_packet 
= 16M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysql]
自己经历的mysql cluter配置过程(二)配置文件no-auto-rehash
自己经历的mysql cluter配置过程(二)配置文件# Remove the next comment character if you are not familiar with SQL
自己经历的mysql cluter配置过程(二)配置文件#safe-updates
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[isamchk]
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 20M
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 20M
自己经历的mysql cluter配置过程(二)配置文件read_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件write_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[myisamchk]
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 20M
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 20M
自己经历的mysql cluter配置过程(二)配置文件read_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件write_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysqlhotcopy]
自己经历的mysql cluter配置过程(二)配置文件interactive-timeout
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[MYSQL_CLUSTER]
自己经历的mysql cluter配置过程(二)配置文件ndb-connectstring
=192.168.1.79  # location of management server
自己经历的mysql cluter配置过程(二)配置文件

19.my.cnf

自己经历的mysql cluter配置过程(二)配置文件# Example MySQL config file for medium systems.
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# This is for a system with little memory (32M - 64M) where MySQL plays
自己经历的mysql cluter配置过程(二)配置文件# an important part
, or systems up to 128M where MySQL is used together with
自己经历的mysql cluter配置过程(二)配置文件# other programs (such as a web server)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# You can copy this file to
自己经历的mysql cluter配置过程(二)配置文件# /etc/my.cnf to set global options
,
自己经历的mysql cluter配置过程(二)配置文件# mysql-data-dir/my.cnf to set server-specific options (in this
自己经历的mysql cluter配置过程(二)配置文件# installation this directory is /var/lib/mysql) or
自己经历的mysql cluter配置过程(二)配置文件# ~/.my.cnf to set user-specific options.
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# In this file
, you can use all long options that a program supports.
自己经历的mysql cluter配置过程(二)配置文件# If you want to know which options a program supports
, run the program
自己经历的mysql cluter配置过程(二)配置文件# with the 
"--help" option.
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# The following options will be passed to all MySQL clients
自己经历的mysql cluter配置过程(二)配置文件
[client]
自己经历的mysql cluter配置过程(二)配置文件#password    
= your_password
自己经历的mysql cluter配置过程(二)配置文件port        
= 3306
自己经历的mysql cluter配置过程(二)配置文件socket        
= /var/lib/mysql/mysql.sock
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Here follows entries for some specific programs
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# The MySQL server
自己经历的mysql cluter配置过程(二)配置文件
[mysqld]
自己经历的mysql cluter配置过程(二)配置文件port        
= 3306
自己经历的mysql cluter配置过程(二)配置文件socket        
= /var/lib/mysql/mysql.sock
自己经历的mysql cluter配置过程(二)配置文件skip-locking
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 16M
自己经历的mysql cluter配置过程(二)配置文件max_allowed_packet 
= 1M
自己经历的mysql cluter配置过程(二)配置文件table_cache 
= 64
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 512K
自己经历的mysql cluter配置过程(二)配置文件net_buffer_length 
= 8K
自己经历的mysql cluter配置过程(二)配置文件read_buffer_size 
= 256K
自己经历的mysql cluter配置过程(二)配置文件read_rnd_buffer_size 
= 512K
自己经历的mysql cluter配置过程(二)配置文件myisam_sort_buffer_size 
= 8M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件ndbcluster                      # run NDB storage engine
自己经历的mysql cluter配置过程(二)配置文件ndb-connectstring
=192.168.1.79  # location of management server
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Don't listen on a TCP/IP port at all. This can be a security enhancement
,
自己经历的mysql cluter配置过程(二)配置文件# if all processes that need to connect to mysqld run on the same host.
自己经历的mysql cluter配置过程(二)配置文件# All interaction with mysqld must be made via Unix sockets or named pipes.
自己经历的mysql cluter配置过程(二)配置文件# Note that using this option without enabling named pipes on Windows
自己经历的mysql cluter配置过程(二)配置文件# (via the 
"enable-named-pipe" option) will render mysqld useless!
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件#skip-networking
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Replication Master Server (default)
自己经历的mysql cluter配置过程(二)配置文件# binary logging is required for replication
自己经历的mysql cluter配置过程(二)配置文件log-bin
=mysql-bin
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# required unique id between 
1 and 2^32 - 1
自己经历的mysql cluter配置过程(二)配置文件# defaults to 
1 if master-host is not set
自己经历的mysql cluter配置过程(二)配置文件# but will not function as a master if omitted
自己经历的mysql cluter配置过程(二)配置文件server-id    
= 1
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Replication Slave (comment out master section to use this)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# To configure this host as a replication slave
, you can choose between
自己经历的mysql cluter配置过程(二)配置文件# two methods :
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件
1) Use the CHANGE MASTER TO command (fully described in our manual) -
自己经历的mysql cluter配置过程(二)配置文件#    the syntax is:
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    CHANGE MASTER TO MASTER_HOST
=<host>, MASTER_PORT=<port>,
自己经历的mysql cluter配置过程(二)配置文件#    MASTER_USER
=<user>, MASTER_PASSWORD=<password> ;
自己经历的mysql cluter配置过程(二)配置文件
#
自己经历的mysql cluter配置过程(二)配置文件#    where you replace <host>
, <user>, <password> by quoted strings and
自己经历的mysql cluter配置过程(二)配置文件#    <port> by the master's port number (
3306 by default).
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    Example:
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    CHANGE MASTER TO MASTER_HOST
='125.564.12.1', MASTER_PORT=3306,
自己经历的mysql cluter配置过程(二)配置文件#    MASTER_USER
='joe', MASTER_PASSWORD='secret';
自己经历的mysql cluter配置过程(二)配置文件
#
自己经历的mysql cluter配置过程(二)配置文件# OR
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件
2) Set the variables below. However, in case you choose this method, then
自己经历的mysql cluter配置过程(二)配置文件#    start replication for the first time (even unsuccessfully
, for example
自己经历的mysql cluter配置过程(二)配置文件#    if you mistyped the password in master-password and the slave fails to
自己经历的mysql cluter配置过程(二)配置文件#    connect)
, the slave will create a master.info file, and any later
自己经历的mysql cluter配置过程(二)配置文件#    change in this file to the variables' values below will be ignored and
自己经历的mysql cluter配置过程(二)配置文件#    overridden by the content of the master.info file
, unless you shutdown
自己经历的mysql cluter配置过程(二)配置文件#    the slave server
, delete master.info and restart the slaver server.
自己经历的mysql cluter配置过程(二)配置文件#    For that reason
, you may want to leave the lines below untouched
自己经历的mysql cluter配置过程(二)配置文件#    (commented) and instead use CHANGE MASTER TO (see above)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# required unique id between 
2 and 2^32 - 1
自己经历的mysql cluter配置过程(二)配置文件# (and different from the master)
自己经历的mysql cluter配置过程(二)配置文件# defaults to 
2 if master-host is set
自己经历的mysql cluter配置过程(二)配置文件# but will not function as a slave if omitted
自己经历的mysql cluter配置过程(二)配置文件#server-id       
= 2
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The replication master for this slave - required
自己经历的mysql cluter配置过程(二)配置文件#master-host     
=   <hostname>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The username the slave will use for authentication when connecting
自己经历的mysql cluter配置过程(二)配置文件# to the master - required
自己经历的mysql cluter配置过程(二)配置文件#master-user     
=   <username>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The password the slave will authenticate with when connecting to
自己经历的mysql cluter配置过程(二)配置文件# the master - required
自己经历的mysql cluter配置过程(二)配置文件#master-password 
=   <password>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The port the master is listening on.
自己经历的mysql cluter配置过程(二)配置文件# optional - defaults to 
3306
自己经历的mysql cluter配置过程(二)配置文件#master-port     
=  <port>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# binary logging - not required for slaves
, but recommended
自己经历的mysql cluter配置过程(二)配置文件#log-bin
=mysql-bin
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Point the following paths to different dedicated disks
自己经历的mysql cluter配置过程(二)配置文件#tmpdir        
= /tmp/        
自己经历的mysql cluter配置过程(二)配置文件#log-update     
= /path-to-dedicated-directory/hostname
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Uncomment the following if you are using BDB tables
自己经历的mysql cluter配置过程(二)配置文件#bdb_cache_size 
= 4M
自己经历的mysql cluter配置过程(二)配置文件#bdb_max_lock 
= 10000
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Uncomment the following if you are using InnoDB tables
自己经历的mysql cluter配置过程(二)配置文件#innodb_data_home_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件#innodb_data_file_path 
= ibdata1:10M:autoextend
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_group_home_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_arch_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件# You can set .._buffer_pool_size up to 
50 - 80 %
自己经历的mysql cluter配置过程(二)配置文件# of RAM but beware of setting memory usage too high
自己经历的mysql cluter配置过程(二)配置文件#innodb_buffer_pool_size 
= 16M
自己经历的mysql cluter配置过程(二)配置文件#innodb_additional_mem_pool_size 
= 2M
自己经历的mysql cluter配置过程(二)配置文件# Set .._log_file_size to 
25 % of buffer pool size
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_file_size 
= 5M
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_buffer_size 
= 8M
自己经历的mysql cluter配置过程(二)配置文件#innodb_flush_log_at_trx_commit 
= 1
自己经历的mysql cluter配置过程(二)配置文件#innodb_lock_wait_timeout 
= 50
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysqldump]
自己经历的mysql cluter配置过程(二)配置文件quick
自己经历的mysql cluter配置过程(二)配置文件max_allowed_packet 
= 16M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysql]
自己经历的mysql cluter配置过程(二)配置文件no-auto-rehash
自己经历的mysql cluter配置过程(二)配置文件# Remove the next comment character if you are not familiar with SQL
自己经历的mysql cluter配置过程(二)配置文件#safe-updates
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[isamchk]
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 20M
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 20M
自己经历的mysql cluter配置过程(二)配置文件read_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件write_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[myisamchk]
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 20M
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 20M
自己经历的mysql cluter配置过程(二)配置文件read_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件write_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysqlhotcopy]
自己经历的mysql cluter配置过程(二)配置文件interactive-timeout
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[MYSQL_CLUSTER]
自己经历的mysql cluter配置过程(二)配置文件ndb-connectstring
=192.168.1.79  # location of management server
自己经历的mysql cluter配置过程(二)配置文件

 

79.my.cnf

 

自己经历的mysql cluter配置过程(二)配置文件#Omple MySQL config file for medium systems.
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# This is for a system with little memory (32M - 64M) where MySQL plays
自己经历的mysql cluter配置过程(二)配置文件# an important part
, or systems up to 128M where MySQL is used together with
自己经历的mysql cluter配置过程(二)配置文件# other programs (such as a web server)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# You can copy this file to
自己经历的mysql cluter配置过程(二)配置文件# /etc/my.cnf to set global options
,
自己经历的mysql cluter配置过程(二)配置文件# mysql-data-dir/my.cnf to set server-specific options (in this
自己经历的mysql cluter配置过程(二)配置文件# installation this directory is /var/lib/mysql) or
自己经历的mysql cluter配置过程(二)配置文件# ~/.my.cnf to set user-specific options.
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# In this file
, you can use all long options that a program supports.
自己经历的mysql cluter配置过程(二)配置文件# If you want to know which options a program supports
, run the program
自己经历的mysql cluter配置过程(二)配置文件# with the 
"--help" option.
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# The following options will be passed to all MySQL clients
自己经历的mysql cluter配置过程(二)配置文件
[client]
自己经历的mysql cluter配置过程(二)配置文件#password    
= your_password
自己经历的mysql cluter配置过程(二)配置文件port        
= 3307
自己经历的mysql cluter配置过程(二)配置文件socket        
= /var/lib/mysql/mysql.sock
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Here follows entries for some specific programs
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# The MySQL server
自己经历的mysql cluter配置过程(二)配置文件
[mysqld]
自己经历的mysql cluter配置过程(二)配置文件datadir     
= /var/lib/mysql
自己经历的mysql cluter配置过程(二)配置文件user        
= root
自己经历的mysql cluter配置过程(二)配置文件port        
= 3306
自己经历的mysql cluter配置过程(二)配置文件socket        
= /var/lib/mysql/mysql.sock
自己经历的mysql cluter配置过程(二)配置文件skip-locking
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 16M
自己经历的mysql cluter配置过程(二)配置文件max_allowed_packet 
= 1M
自己经历的mysql cluter配置过程(二)配置文件table_cache 
= 64
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 512K
自己经历的mysql cluter配置过程(二)配置文件net_buffer_length 
= 8K
自己经历的mysql cluter配置过程(二)配置文件read_buffer_size 
= 256K
自己经历的mysql cluter配置过程(二)配置文件read_rnd_buffer_size 
= 512K
自己经历的mysql cluter配置过程(二)配置文件myisam_sort_buffer_size 
= 8M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件#datadir        
= /mysqldata
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Don't listen on a TCP/IP port at all. This can be a security enhancement
,
自己经历的mysql cluter配置过程(二)配置文件# if all processes that need to connect to mysqld run on the same host.
自己经历的mysql cluter配置过程(二)配置文件# All interaction with mysqld must be made via Unix sockets or named pipes.
自己经历的mysql cluter配置过程(二)配置文件# Note that using this option without enabling named pipes on Windows
自己经历的mysql cluter配置过程(二)配置文件# (via the 
"enable-named-pipe" option) will render mysqld useless!
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件#skip-networking
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Replication Master Server (default)
自己经历的mysql cluter配置过程(二)配置文件# binary logging is required for replication
自己经历的mysql cluter配置过程(二)配置文件log-bin
=mysql-bin
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# required unique id between 
1 and 2^32 - 1
自己经历的mysql cluter配置过程(二)配置文件# defaults to 
1 if master-host is not set
自己经历的mysql cluter配置过程(二)配置文件# but will not function as a master if omitted
自己经历的mysql cluter配置过程(二)配置文件server-id    
= 1
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Replication Slave (comment out master section to use this)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# To configure this host as a replication slave
, you can choose between
自己经历的mysql cluter配置过程(二)配置文件# two methods :
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件
1) Use the CHANGE MASTER TO command (fully described in our manual) -
自己经历的mysql cluter配置过程(二)配置文件#    the syntax is:
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    CHANGE MASTER TO MASTER_HOST
=<host>, MASTER_PORT=<port>,
自己经历的mysql cluter配置过程(二)配置文件#    MASTER_USER
=<user>, MASTER_PASSWORD=<password> ;
自己经历的mysql cluter配置过程(二)配置文件
#
自己经历的mysql cluter配置过程(二)配置文件#    where you replace <host>
, <user>, <password> by quoted strings and
自己经历的mysql cluter配置过程(二)配置文件#    <port> by the master's port number (
3306 by default).
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    Example:
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件#    CHANGE MASTER TO MASTER_HOST
='125.564.12.1', MASTER_PORT=3306,
自己经历的mysql cluter配置过程(二)配置文件#    MASTER_USER
='joe', MASTER_PASSWORD='secret';
自己经历的mysql cluter配置过程(二)配置文件
#
自己经历的mysql cluter配置过程(二)配置文件# OR
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件
2) Set the variables below. However, in case you choose this method, then
自己经历的mysql cluter配置过程(二)配置文件#    start replication for the first time (even unsuccessfully
, for example
自己经历的mysql cluter配置过程(二)配置文件#    if you mistyped the password in master-password and the slave fails to
自己经历的mysql cluter配置过程(二)配置文件#    connect)
, the slave will create a master.info file, and any later
自己经历的mysql cluter配置过程(二)配置文件#    change in this file to the variables' values below will be ignored and
自己经历的mysql cluter配置过程(二)配置文件#    overridden by the content of the master.info file
, unless you shutdown
自己经历的mysql cluter配置过程(二)配置文件#    the slave server
, delete master.info and restart the slaver server.
自己经历的mysql cluter配置过程(二)配置文件#    For that reason
, you may want to leave the lines below untouched
自己经历的mysql cluter配置过程(二)配置文件#    (commented) and instead use CHANGE MASTER TO (see above)
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# required unique id between 
2 and 2^32 - 1
自己经历的mysql cluter配置过程(二)配置文件# (and different from the master)
自己经历的mysql cluter配置过程(二)配置文件# defaults to 
2 if master-host is set
自己经历的mysql cluter配置过程(二)配置文件# but will not function as a slave if omitted
自己经历的mysql cluter配置过程(二)配置文件#server-id       
= 2
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The replication master for this slave - required
自己经历的mysql cluter配置过程(二)配置文件#master-host     
=   <hostname>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The username the slave will use for authentication when connecting
自己经历的mysql cluter配置过程(二)配置文件# to the master - required
自己经历的mysql cluter配置过程(二)配置文件#master-user     
=   <username>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The password the slave will authenticate with when connecting to
自己经历的mysql cluter配置过程(二)配置文件# the master - required
自己经历的mysql cluter配置过程(二)配置文件#master-password 
=   <password>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# The port the master is listening on.
自己经历的mysql cluter配置过程(二)配置文件# optional - defaults to 
3306
自己经历的mysql cluter配置过程(二)配置文件#master-port     
=  <port>
自己经历的mysql cluter配置过程(二)配置文件#
自己经历的mysql cluter配置过程(二)配置文件# binary logging - not required for slaves
, but recommended
自己经历的mysql cluter配置过程(二)配置文件#log-bin
=mysql-bin
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Point the following paths to different dedicated disks
自己经历的mysql cluter配置过程(二)配置文件#tmpdir        
= /tmp/        
自己经历的mysql cluter配置过程(二)配置文件#log-update     
= /path-to-dedicated-directory/hostname
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Uncomment the following if you are using BDB tables
自己经历的mysql cluter配置过程(二)配置文件#bdb_cache_size 
= 4M
自己经历的mysql cluter配置过程(二)配置文件#bdb_max_lock 
= 10000
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Uncomment the following if you are using InnoDB tables
自己经历的mysql cluter配置过程(二)配置文件#innodb_data_home_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件#innodb_data_file_path 
= ibdata1:10M:autoextend
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_group_home_dir 
= /var/lib/mysql/
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_arch_dir 
= /var/lib/mysql
自己经历的mysql cluter配置过程(二)配置文件# You can set .._buffer_pool_size up to 
50 - 80 %
自己经历的mysql cluter配置过程(二)配置文件# of RAM but beware of setting memory usage too high
自己经历的mysql cluter配置过程(二)配置文件#innodb_buffer_pool_size 
= 16M
自己经历的mysql cluter配置过程(二)配置文件#innodb_additional_mem_pool_size 
= 2M
自己经历的mysql cluter配置过程(二)配置文件# Set .._log_file_size to 
25 % of buffer pool size
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_file_size 
= 5M
自己经历的mysql cluter配置过程(二)配置文件#innodb_log_buffer_size 
= 8M
自己经历的mysql cluter配置过程(二)配置文件#innodb_flush_log_at_trx_commit 
= 1
自己经历的mysql cluter配置过程(二)配置文件#innodb_lock_wait_timeout 
= 50
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件#ndbcluster                      # run NDB storage engine
自己经历的mysql cluter配置过程(二)配置文件#ndb-connectstring
=192.168.1.76  # location of management server
自己经历的mysql cluter配置过程(二)配置文件
[mysqldump]
自己经历的mysql cluter配置过程(二)配置文件quick
自己经历的mysql cluter配置过程(二)配置文件max_allowed_packet 
= 16M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysql]
自己经历的mysql cluter配置过程(二)配置文件no-auto-rehash
自己经历的mysql cluter配置过程(二)配置文件# Remove the next comment character if you are not familiar with SQL
自己经历的mysql cluter配置过程(二)配置文件#safe-updates
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[isamchk]
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 20M
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 20M
自己经历的mysql cluter配置过程(二)配置文件read_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件write_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[myisamchk]
自己经历的mysql cluter配置过程(二)配置文件key_buffer 
= 20M
自己经历的mysql cluter配置过程(二)配置文件sort_buffer_size 
= 20M
自己经历的mysql cluter配置过程(二)配置文件read_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件write_buffer 
= 2M
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
[mysqlhotcopy]
自己经历的mysql cluter配置过程(二)配置文件interactive-timeout
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件#
[MYSQL_CLUSTER]
自己经历的mysql cluter配置过程(二)配置文件#ndb-connectstring
=192.168.1.76  # location of management server
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件

 

79.config.ini

 

自己经历的mysql cluter配置过程(二)配置文件#ptions affecting ndbd processes on all data nodes:
自己经历的mysql cluter配置过程(二)配置文件
[NDBD DEFAULT]    
自己经历的mysql cluter配置过程(二)配置文件NoOfReplicas
=2    # Number of replicas
自己经历的mysql cluter配置过程(二)配置文件DataMemory
=400M    # How much memory to allocate for data storage
自己经历的mysql cluter配置过程(二)配置文件IndexMemory
=200M   # How much memory to allocate for index storage
自己经历的mysql cluter配置过程(二)配置文件                  # For DataMemory and IndexMemory
, we have used the
自己经历的mysql cluter配置过程(二)配置文件                  # default values. Since the 
"world" database takes up
自己经历的mysql cluter配置过程(二)配置文件                  # only about 500KB
, this should be more than enough for
自己经历的mysql cluter配置过程(二)配置文件                  # this example Cluster setup.
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# TCP/IP options:
自己经历的mysql cluter配置过程(二)配置文件
[TCP DEFAULT]     
自己经历的mysql cluter配置过程(二)配置文件portnumber
=2202   # This the default; however, you can use any
自己经历的mysql cluter配置过程(二)配置文件
                               # port that is free for all the hosts in the cluster
自己经历的mysql cluter配置过程(二)配置文件                               # Note: It is recommended that you do not specify the 
自己经历的mysql cluter配置过程(二)配置文件                               # portnumber at all and allow the default value to be 
自己经历的mysql cluter配置过程(二)配置文件                               # used instead
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Management process options:
自己经历的mysql cluter配置过程(二)配置文件
[NDB_MGMD]                      
自己经历的mysql cluter配置过程(二)配置文件hostname
=192.168.1.79           # Hostname or IP address of MGM node
自己经历的mysql cluter配置过程(二)配置文件datadir
=/mysqldata  # Directory for MGM node log files
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Options for data node 
"A":
自己经历的mysql cluter配置过程(二)配置文件
[NDBD]                          
自己经历的mysql cluter配置过程(二)配置文件                                # (one 
[NDBD] section per data node)
自己经历的mysql cluter配置过程(二)配置文件hostname
=192.168.1.16           # Hostname or IP address
自己经历的mysql cluter配置过程(二)配置文件datadir
=/mysqldata   # Directory for this data node's data files
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# Options for data node 
"B":
自己经历的mysql cluter配置过程(二)配置文件
[NDBD]                          
自己经历的mysql cluter配置过程(二)配置文件hostname
=192.168.1.19           # Hostname or IP address
自己经历的mysql cluter配置过程(二)配置文件datadir
=/mysqldata   # Directory for this data node's data files
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件# SQL node options:
自己经历的mysql cluter配置过程(二)配置文件
[MYSQLD]                        
自己经历的mysql cluter配置过程(二)配置文件hostname
=192.168.1.76           # Hostname or IP address
自己经历的mysql cluter配置过程(二)配置文件                                # (additional mysqld connections can be
自己经历的mysql cluter配置过程(二)配置文件                                # specified for this node for various
自己经历的mysql cluter配置过程(二)配置文件                                # purposes such as running ndb_restore)
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件
自己经历的mysql cluter配置过程(二)配置文件

相关文章:

  • 2022-02-04
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-12
  • 2022-02-07
猜你喜欢
  • 2022-12-23
  • 2021-11-04
  • 2022-12-23
  • 2021-08-08
  • 2022-12-23
  • 2022-12-23
  • 2021-04-17
相关资源
相似解决方案