高性价比开源软件集群(2)--MySQL集群

来源: 作者: 2007-09-02 出处:pcdog.com

mysql  集群  
上一页 1 2 3 4 下一页 

my.cnf

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

注意.config.ini中指明了所有的数据节点和SQL节点,它将管理这些地址,数据节点和SQL节点中都指明了管理节点的地址,它们通过它进行与管理节点的通信,但SQL节点中并没有指明数据节点的地址,所以它通过管理节点来与数据节点进程通信.


更多内容请看PCdog.com--Linux集群高级技巧  MySQL数据备份专题
上一页 1 2 3 4 下一页 
上一篇:如何对MySQL 服务器进行调优
下一篇:送给新手---MySQL使用的前奏