Start slave creates master.info file

Bug #1259348 reported by monty solomon
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MySQL Server
Unknown
Unknown
Percona Server moved to https://jira.percona.com/projects/PS
Status tracked in 5.7
5.1
Won't Fix
Low
Unassigned
5.5
Triaged
Low
Unassigned
5.6
Triaged
Low
Unassigned
5.7
Triaged
Low
Unassigned

Bug Description

Executing the statement "start slave" on a master server erroneously creates a master.info file.

Tags: upstream
Revision history for this message
monty solomon (monty+launchpad) wrote :

# ls
heartbeat mysql.sock performance_schema test
ibdata1 mysql_upgrade_info RPM_UPGRADE_HISTORY
mysql percona RPM_UPGRADE_MARKER-LAST

# service mysql restart ; mysql -uroot -e "start slave"
Shutting down MySQL (Percona Server)....... [ OK ]
Starting MySQL (Percona Server)........ [ OK ]
ERROR 1200 (HY000) at line 1: The server is not configured as slave; fix in config file or with CHANGE MASTER TO

# ls
heartbeat mysql percona RPM_UPGRADE_MARKER-LAST
ibdata1 mysql.sock performance_schema test
master.info mysql_upgrade_info RPM_UPGRADE_HISTORY

Revision history for this message
monty solomon (monty+launchpad) wrote :

Server version: 5.5.34-32.0-log Percona Server (GPL), Release rel32.0, Revision 591

CentOS release 6.3 (Final)

Linux 2.6.32-279.19.1.el6.x86_64 #1 SMP Wed Dec 19 07:05:20 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux

Revision history for this message
monty solomon (monty+launchpad) wrote :

my.cnf contains

binlog-format = MIXED
sync_binlog = 1
sync_master_info = 10000
sync_relay_log = 10000
sync_relay_log_info = 10000

Revision history for this message
Valerii Kravchuk (valerii-kravchuk) wrote :

First of all, the file is indeed created, this is easy to check. It's the same with upstream MySQL on Windows, for example. I do not see this explicitly documented in the manual:

http://dev.mysql.com/doc/refman/5.5/en/start-slave.html
http://dev.mysql.com/doc/refman/5.5/en/slave-logs-status.html

so I am going to create an upstream MySQL bug report for this. Stay tuned.

Revision history for this message
Valerii Kravchuk (valerii-kravchuk) wrote :

That's what happens:

[openxs@chief p5.5]$ ls data
chief.err ibdata1 ib_logfile1 performance_schema
chief.pid ib_logfile0 mysql test
[openxs@chief p5.5]$ ls -l data
total 28696
-rw-r----- 1 openxs openxs 4313 Dec 10 10:39 chief.err
-rw-rw---- 1 openxs openxs 5 Dec 10 10:39 chief.pid
-rw-rw---- 1 openxs openxs 18874368 Oct 4 13:14 ibdata1
-rw-rw---- 1 openxs openxs 5242880 Dec 10 10:39 ib_logfile0
-rw-rw---- 1 openxs openxs 5242880 Oct 2 08:40 ib_logfile1
drwx------ 2 openxs openxs 4096 Oct 2 08:39 mysql
drwx------ 2 openxs openxs 4096 Oct 2 08:39 performance_schema
drwx------ 2 openxs openxs 4096 Oct 4 13:14 test
[openxs@chief p5.5]$ bin/mysql --no-defaults -uroot test
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.5.32 MySQL Community Server (GPL)

Copyright (c) 2009-2013 Percona Ireland Ltd.
Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> start slave;
ERROR 1200 (HY000): The server is not configured as slave; fix in config file or with CHANGE MASTER TO
mysql> exit
Bye
[openxs@chief p5.5]$ ls -l data
total 28712
-rw-r----- 1 openxs openxs 4551 Dec 10 10:40 chief.err
-rw-rw---- 1 openxs openxs 5 Dec 10 10:39 chief.pid
-rw-rw---- 1 openxs openxs 107 Dec 10 10:40 chief-relay-bin.000001
-rw-rw---- 1 openxs openxs 25 Dec 10 10:40 chief-relay-bin.index
-rw-rw---- 1 openxs openxs 18874368 Oct 4 13:14 ibdata1
-rw-rw---- 1 openxs openxs 5242880 Dec 10 10:39 ib_logfile0
-rw-rw---- 1 openxs openxs 5242880 Oct 2 08:40 ib_logfile1
-rw-rw---- 1 openxs openxs 38 Dec 10 10:40 master.info
drwx------ 2 openxs openxs 4096 Oct 2 08:39 mysql
drwx------ 2 openxs openxs 4096 Oct 2 08:39 performance_schema
-rw-rw---- 1 openxs openxs 30 Dec 10 10:40 relay-log.info
drwx------ 2 openxs openxs 4096 Oct 4 13:14 test

Revision history for this message
Valerii Kravchuk (valerii-kravchuk) wrote :

Here is my upstream bug report:

http://bugs.mysql.com/bug.php?id=71123

Please, check if I missed something there.

tags: added: upstream
Revision history for this message
monty solomon (monty+launchpad) wrote :

Looks good.

Thanks.

Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PS-2051

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.