Mysql Replication Master To Slave
Mysql Replication Master To Slave
Install MySQL yum install mysql-server mysql php-mysql Set the MySQL service to start on boot -chkconfig --levels 235 mysqld on Start the MySQL service -service mysqld start Log into MySQL -mysql -u root Set the root user password for all local domains -SET PASSWORD FOR 'root'@'localhost' = PASSWORD('new-password'); -SET PASSWORD FOR 'root'@'localhost.localdomain' = PASSWORD('new-password'); -SET PASSWORD FOR 'root'@'127.0.0.1' = PASSWORD('new-password'); Drop the Any user -DROP USER ''@'localhost'; -DROP USER ''@'localhost.localdomain'; Exit MySQL -exit
| File | Position | Binlog_Do_DB | Binlog_Ignore_DB +-------------------------+------------+---------------------+----------------------------+ | mysql-bin.000001 | 16310 | testdb | | +-------------------------+------------+---------------------+----------------------------+ 1 row in set (0.00 sec) mysql> UNLOCK TABLES; mysql>\q mysqldump u root p --opt yourDB > yourDB.sql