linux mysql 解压缩安装配置_linux下安装mysql——解压缩版

02

shell>cat my3309.cnf

#/usr/local/mysql3309下新建my3309.cnf配置文件,内容复制my3308.cnf

shell>mkdir /usr/local/mysql3309/logs

shell>mkdir /usr/local/mysql3309/bin-log

shell>chown -R mysql.mysql .

shell> scripts/mysql_install_db --user=mysql  --defaults-file=/usr/local/mysql3309/my3309.cnf

-----------------------my3309.cnf内容--------------------------------------

[client]

#password = your_password

port = 3307

socket = /tmp/mysql3307.sock

[mysql]

socket = /tmp/mysql3307.sock

# The MySQL server

[mysqld]

port = 3309

socket = /tmp/mysql3307.sock

basedir =/usr/local/mysql3307

datadir =/usr/local/mysql3307/data

skip-external-locking

skip-host-cache

skip-name-resolve

max_connection =1000

key_buffer_size = 600M

max_allowed_packet = 10M

table_open_cache = 1024

sort_buffer_size = 6M

read_buffer_size = 6M

read_rnd_buffer_size = 8M

myisam_sort_buffer_size = 64M

thread_cache_size = 64

query_cache_size = 32M

# Try number of CPU's*2 for thread_concurrency

thread_concurrency = 8

log-error=/usr/local/mysql3307/logs/mysqld3307.log

server-id         = 1

log_slave_updates = 1

auto_increment_increment=2

auto_increment_offset=2

read-only

log_bin              =/usr/local/mysql3307/binlog/mysql-bin.log

#log-bin-index            = mysql-bin.index

max_binlog_size =1G

max_relay_log_size =1G

expire_logs_days         = 30 #超过30天的binlog删除

replicate-do-db =test #只复制某个库

replicate-do-db =fab

replicate-do-db =fat

replicate-do-db =thca

replicate-do-db =fab_innodb

replicate-ignore-db=mysql #不复制某个库

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值