I have successfully set up the master- slave replication on my 2 database servers. I have also set up the master to replicate on the slave and when the master is down, the slave to master replication also works. However, i am unable to set up the time interval for this to take place. I tried using master_delay as well as master_heartbeat_period. None of these seem to be working.
mysql> change master to master_host='192.168.0.2',
-> master_user='master',
-> master_password='masterpass',
-> master_log_file='mysql-bin.000008',
-> master_log_pos=3733
-> master_delay=30; //to set the time limit for the interval
mysql> change master to master_host='192.168.0.2',
-> master_user='master',
-> master_password='masterpass',
-> master_log_file='mysql-bin.000008',
-> master_log_pos=3733
-> master_heartbeat_period=30; //to set the time limit for the interval
The replication still happens instantly.. Any idea what i am doing wrong?