diff options
author | unknown <guilhem@mysql.com> | 2003-10-09 17:40:38 +0200 |
---|---|---|
committer | unknown <guilhem@mysql.com> | 2003-10-09 17:40:38 +0200 |
commit | 7e1a1032e826e867e41cdd3361b40fac33956543 (patch) | |
tree | 00cc9585b4e7a5c3ba44355557f658861da6ceea /sql | |
parent | 654d266c8bca6ef770e4a592b32696e920ce0e98 (diff) | |
download | mariadb-git-7e1a1032e826e867e41cdd3361b40fac33956543.tar.gz |
Make the slave die if master is 5.0. Indeed, 5.0 masters send
a Format_description_log_event (or maybe it will be named
Description_log_event) which is not recognized by 4.0, so
a 4.0 can't be a slave of 5.0. We detect it early to produce
a helpful message instead of "corrupted relay log" later.
sql/slave.cc:
Make the slave die if master is 5.0.
Diffstat (limited to 'sql')
-rw-r--r-- | sql/slave.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sql/slave.cc b/sql/slave.cc index 10d451a88bc..12698c8eda4 100644 --- a/sql/slave.cc +++ b/sql/slave.cc @@ -1017,11 +1017,12 @@ static int check_master_version(MYSQL* mysql, MASTER_INFO* mi) BINLOG_FORMAT_323_GEQ_57 ; break; case '4': - case '5': mi->old_format = BINLOG_FORMAT_CURRENT; break; default: - errmsg = "Master reported unrecognized MySQL version"; + /* 5.0 is not supported */ + errmsg = "Master reported an unrecognized MySQL version. Note that 4.0 \ +slaves can't replicate a 5.0 or newer master."; break; } |