mysql多实例,mysqld_multi

mysql单机多实例
[mysqld_multi]
mysqld=/usr/local/mysql/bin/mysqld_safe
mysqladmin=/usr/local/mysql/bin/mysqldadmin
log=/usr/local/mysql/mysqld_multi.log
[mysqld1]
port=3307
datadir = /data_3307
socket= /tmp/mysql_3307.sock
[mysqld2]
port=3308
datadir = /data_3308
socket= /tmp/mysql_3308.sock
初始化
mysqld --initialize-insecure --datadir=/data_3307
mysqld --initialize-insecure --datadir=/data_3308
shell终端命令
mysqld_multi start 1
mysqld_multi  report
mysqld_multi stop 1
mysql -S /tmp/mysql_3307.sock

mysql多实例,mysqld_multi

上一篇:mysql数据库入门、进阶和提升(续二)


下一篇:本地创建mongodb服务(安装mongodb、创建数据库和密码、创建用户和密码、本地配置连接测试)