Commit 620d520d authored by Daniel Black's avatar Daniel Black Committed by GitHub

MDEV-29614 mariadb-upgrade calls mysql and mysql-check (#2279)

rather than mariadb/mariadb-check
parent fe7c95ec
...@@ -935,7 +935,7 @@ static int run_mysqlcheck_upgrade(my_bool mysql_db_only) ...@@ -935,7 +935,7 @@ static int run_mysqlcheck_upgrade(my_bool mysql_db_only)
return 0; return 0;
} }
verbose("Phase %d/%d: Checking and upgrading %s", ++phase, phases_total, what); verbose("Phase %d/%d: Checking and upgrading %s", ++phase, phases_total, what);
print_conn_args("mysqlcheck"); print_conn_args("mariadb-check");
retch= run_tool(mysqlcheck_path, retch= run_tool(mysqlcheck_path,
NULL, /* Send output from mysqlcheck directly to screen */ NULL, /* Send output from mysqlcheck directly to screen */
defaults_file, defaults_file,
...@@ -1451,7 +1451,7 @@ int main(int argc, char **argv) ...@@ -1451,7 +1451,7 @@ int main(int argc, char **argv)
} }
/* Find mysql */ /* Find mysql */
find_tool(mysql_path, IF_WIN("mysql.exe", "mysql"), self_name); find_tool(mysql_path, IF_WIN("mariadb.exe", "mariadb"), self_name);
open_mysql_upgrade_file(); open_mysql_upgrade_file();
...@@ -1459,7 +1459,7 @@ int main(int argc, char **argv) ...@@ -1459,7 +1459,7 @@ int main(int argc, char **argv)
exit(upgrade_already_done(0) == 0); exit(upgrade_already_done(0) == 0);
/* Find mysqlcheck */ /* Find mysqlcheck */
find_tool(mysqlcheck_path, IF_WIN("mysqlcheck.exe", "mysqlcheck"), self_name); find_tool(mysqlcheck_path, IF_WIN("mariadb-check.exe", "mariadb-check"), self_name);
if (opt_systables_only && !opt_silent) if (opt_systables_only && !opt_silent)
printf("The --upgrade-system-tables option was used, user tables won't be touched.\n"); printf("The --upgrade-system-tables option was used, user tables won't be touched.\n");
......
...@@ -778,18 +778,18 @@ FLUSH PRIVILEGES; ...@@ -778,18 +778,18 @@ FLUSH PRIVILEGES;
# #
This installation of MariaDB is already upgraded to MariaDB . This installation of MariaDB is already upgraded to MariaDB .
There is no need to run mysql_upgrade again for MariaDB . There is no need to run mysql_upgrade again for MariaDB .
Looking for 'mysql' as: mysql Looking for 'mariadb' as: mariadb
This installation of MariaDB is already upgraded to MariaDB . This installation of MariaDB is already upgraded to MariaDB .
There is no need to run mysql_upgrade again for MariaDB . There is no need to run mysql_upgrade again for MariaDB .
# #
# MDEV-27279: mariadb_upgrade check-if-upgrade absence is do it # MDEV-27279: mariadb_upgrade check-if-upgrade absence is do it
# #
Looking for 'mysql' as: mysql Looking for 'mariadb' as: mariadb
Empty or non existent ...mysql_upgrade_info. Assuming mysql_upgrade has to be run! Empty or non existent ...mysql_upgrade_info. Assuming mysql_upgrade has to be run!
# #
# MDEV-27279: mariadb_upgrade check-if-upgrade with minor version change # MDEV-27279: mariadb_upgrade check-if-upgrade with minor version change
# #
Looking for 'mysql' as: mysql Looking for 'mariadb' as: mariadb
This installation of MariaDB is already upgraded to MariaDB . This installation of MariaDB is already upgraded to MariaDB .
There is no need to run mysql_upgrade again for MariaDB . There is no need to run mysql_upgrade again for MariaDB .
This installation of MariaDB is already upgraded to MariaDB . This installation of MariaDB is already upgraded to MariaDB .
......
...@@ -55,7 +55,7 @@ DROP USER mysqltest1@'%'; ...@@ -55,7 +55,7 @@ DROP USER mysqltest1@'%';
--echo Run mysql_upgrade with a non existing server socket --echo Run mysql_upgrade with a non existing server socket
--replace_result $MYSQLTEST_VARDIR var --replace_result $MYSQLTEST_VARDIR var
--replace_regex /.*mysqlcheck.*: Got/mysqlcheck: Got/ /\([0-9|-]*\)/(errno)/ --replace_regex /.*mariadb-check.*: Got/mariadb-check: Got/ /\([0-9|-]*\)/(errno)/
--error 1 --error 1
# NC: Added --skip-version-check, as the version check would fail when # NC: Added --skip-version-check, as the version check would fail when
# mysql_upgrade tries to get the server version. # mysql_upgrade tries to get the server version.
...@@ -139,7 +139,7 @@ let $MYSQLD_DATADIR= `select @@datadir`; ...@@ -139,7 +139,7 @@ let $MYSQLD_DATADIR= `select @@datadir`;
--echo Run mysql_upgrade with unauthorized access --echo Run mysql_upgrade with unauthorized access
--error 1 --error 1
--exec $MYSQL_UPGRADE --skip-verbose --user=root --password=wrong_password 2>&1 --exec $MYSQL_UPGRADE --skip-verbose --user=root --password=wrong_password 2>&1
--replace_regex /.*mysqlcheck.*: Got/mysqlcheck: Got/ /\([0-9|-]*\)/(errno)/ --replace_regex /.*mariadb-check.*: Got/mariadb-check: Got/ /\([0-9|-]*\)/(errno)/
--error 1 --error 1
--exec $MYSQL_UPGRADE --skip-verbose --skip-version-check --user=root --password=wrong_password 2>&1 --exec $MYSQL_UPGRADE --skip-verbose --skip-version-check --user=root --password=wrong_password 2>&1
...@@ -290,7 +290,7 @@ FLUSH PRIVILEGES; ...@@ -290,7 +290,7 @@ FLUSH PRIVILEGES;
--replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB / --replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB /
--error 1 --error 1
--exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --exec $MYSQL_UPGRADE --check-if-upgrade-is-needed
--replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB / /'mysql.* as:[^\n]*/'mysql' as: mysql/ --replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB / /'mariadb.* as:[^\n]*/'mariadb' as: mariadb/
--error 1 --error 1
--exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --verbose --exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --verbose
...@@ -302,7 +302,7 @@ FLUSH PRIVILEGES; ...@@ -302,7 +302,7 @@ FLUSH PRIVILEGES;
--replace_regex /[^ ]*mysql_upgrade_info/...mysql_upgrade_info/ --replace_regex /[^ ]*mysql_upgrade_info/...mysql_upgrade_info/
--exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --exec $MYSQL_UPGRADE --check-if-upgrade-is-needed
--replace_regex /'mysql.* as:[^\n]*/'mysql' as: mysql/ /open .* Assuming/open XXX. Assuming/ /[^ ]*mysql_upgrade_info/...mysql_upgrade_info/ --replace_regex /'mariadb.* as:[^\n]*/'mariadb' as: mariadb/ /open .* Assuming/open XXX. Assuming/ /[^ ]*mysql_upgrade_info/...mysql_upgrade_info/
--exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --verbose --exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --verbose
--echo # --echo #
...@@ -324,7 +324,7 @@ EOF ...@@ -324,7 +324,7 @@ EOF
--error 1 --error 1
--exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --silent --exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --silent
--replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB / /'mysql.* as:[^\n]*/'mysql' as: mysql/ --replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB / /'mariadb.* as:[^\n]*/'mariadb' as: mariadb/
--error 1 --error 1
--exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --verbose --exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --verbose
--replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB / --replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB /
...@@ -351,7 +351,7 @@ EOF ...@@ -351,7 +351,7 @@ EOF
--exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --silent --exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --silent
--replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB / --replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB /
--exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --exec $MYSQL_UPGRADE --check-if-upgrade-is-needed
--replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB / /'mysql.* as:[^\n]*/'mysql' as: mysql/ --replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB / /'mariadb.* as:[^\n]*/'mysql' as: mysql/
--exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --verbose --exec $MYSQL_UPGRADE --check-if-upgrade-is-needed --verbose
--remove_file $MYSQLD_DATADIR/mysql_upgrade_info --remove_file $MYSQLD_DATADIR/mysql_upgrade_info
drop table mysql.global_priv; drop table mysql.global_priv;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment