| [ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
If you have followed the instructions, and your replication setup is not working, first check the following:
SHOW MASTER STATUS.
If it is, Position will be non-zero. If not, verify that you have
given the master log-bin option and have set server-id.
SHOW SLAVE STATUS and check that the
Slave_IO_Running and Slave_SQL_Running values are both
Yes.
If not, verify slave options
SHOW PROCESSLIST, find the I/O and SQL threads
(see section 6.3 Replication Implementation Details to see how they display),
and check their
State column. If it says Connecting to master, verify the
privileges for the replication user on the master, master hostname, your
DNS setup, whether the master is actually running, whether it is reachable
from the slave.
START SLAVE.
mysql> SET GLOBAL SQL_SLAVE_SKIP_COUNTER = n; mysql> START SLAVE; |
The value of n should be 1 if the query does not use
AUTO_INCREMENT or LAST_INSERT_ID(). Otherwise, the value should
be 2. The reason for using a value of 2 for
queries that use AUTO_INCREMENT or LAST_INSERT_ID()
is that they take two events in the binary log of the master.
| [ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |