I've setup a mysql replica slave a couple months ago. After a couple hickups lately, I've decide to restore it from a clean master export.
I'm trying to start my mysql instance with this command :
mysqld_safe --defaults-file=/etc/mysql/my_secondary.cnf --server-id=2 --log-bin --skip-slave-start --skip-name-resolve&
I've declared the server-id in my cnf file as the following :
server-id = 2
But when I connect with the command line client, and I check the variable, I get :
mysql> show variables like "version";
+---------------+-------------------------+
| Variable_name | Value |
+---------------+-------------------------+
| server-id | 0 |
+---------------+-------------------------+
1 row in set (0.00 sec)
I'm also getting the feeling that my instance is ignoring my "CHANGE MASTER" commands since it's complaining each time i run "start slave", but I would like to settle this server-id issue first.
I'm running two instance of Mysql 5.1.61-0ubuntu0.10.04.1 (one on port 3306, and this one on 4306)
\s
I suspect that you are changing this variable on server on 4306 and connection to server running on 3306