Users Guide

MySQL Replication | Database Management
OMNM 6.5.3 Installation Guide 157
log into slave mysql server (10.35.35.174) and create users: "mysql -u root --password=dorado
mysql> CREATE USER 'repluser'@'10.35.35.170' IDENTIFIED BY 'slavepass';
mysql> CREATE USER 'repluser'@'10.35.35.174' IDENTIFIED BY 'slavepass';
still on slave mysql server, grand privileges for created user:
mysql>GRANT ALL PRIVILEGES ON *.* TO 'repluser'@'10.35.35.170';
mysql>GRANT ALL PRIVILEGES ON *.* TO 'repluser'@'10.35.35.174';
setting up master configuration on slave and start replication:
mysql> CHANGE MASTER TO
-> MASTER_HOST='10.35.35.170',
-> MASTER_USER='repluser',
-> MASTER_PASSWORD='slavepass',
-> MASTER_LOG_FILE='mysql-bin.000001',
-> MASTER_LOG_POS=73;
mysql> START SLAVE;
unlock tables and restart appserver/webserver on master
log into master mysql database and execute:
mysql>UNLOCK TABLES;
restart appserver/webserver
To verify that replication is functioning execute
on master: mysql>show master status;
on slave: mysql>show slave status\G;
both instances should have file position growing and it should be identical.