频道直达 - 专题 - 新闻 - 技巧 - 组网 - 开发 - 安全 - web编程 - 图像 - 操作系统 - 数据库 - 教育 - 旅游 - 健康 - 时尚 - 驱动 - 软件 - 游戏 - 多媒体 - ERP - 讨论组

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

来源: 作者: 出处:巧巧读书 2007-09-02 进入讨论组

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节点中并没有指明数据节点的地址,所以它通过管理节点来与数据节点进程通信.

浏览URL http://www.qqread.com/mysql/c329173.html 更多文章 更多内容请看MySQL数据备份Linux集群技术常用软件加密宝典专题,或进入讨论组讨论。
收藏此文】【 】【打印】【关闭
相关图文阅读
频道图文推荐
健 康 咨 询
时 尚 咨 询
巧巧读书宗旨
相关专题
讨论组问题推荐
站内各频道最新更新文档
站内最新制作专题
热门关键字导读
Photoshop教 程照片处理 照片制作 PS快捷键 抠图
计 算 机 故 障XP系统修复
艺 术 与 设 计设计 流媒体 设计欣赏 边框
计 算 机 安 全ARP
站内频道文章精选
巧巧电脑频道编辑信箱  告诉我们您想看的专题或文章