...
Copy dump.sql from previous step in from Maria DB master server to Maria DB slave server.
Once copied, import it on into Maria DB slave server. If this is a new installation you may need to create kinton database.
Code Block |
---|
mysql < dump.sql |
Once database is on the slave, we should tell mysql imported, tell Maria DB slave server to start replicating the master from the frozen binlog position we set before.On the mysql prompt executefrom the status we got on previous step, using the user and pasword we created for replication. Execute the command below on slave server mysql prompt, replacing master settings as required from previous steps. Notice we set as MASTER_USER the user we grant permission with correspondent password, and also we are using as MASTER_LOG_FILE and MASTER_LOG_POS the data we got previously:
Code Block |
---|
CHANGE MASTER TO MASTER_HOST='10.60.13.25MASTER_IP', MASTER_USER='replicator', MASTER_PASSWORD='s3cr3tPASSWORD', MASTER_PORT=3306, MASTER_LOG_FILE='localhost-bin.000002', MASTER_LOG_POS=3712878, MASTER_CONNECT_RETRY=10; |
Notice we set as MASTER_USER the user we grant permission with correspondent password, and also we are using as MASTER_LOG_FILE and MASTER_LOG_POS the data we got previosly.
Start slave
Now you should start slave thread with commandStart slave replication from slave mysql prompt with the command below:
Code Block |
---|
START SLAVE; |
You can check replication status by executing on the slave:
...