mirror of
https://github.com/MariaDB/server.git
synced 2025-03-23 15:38:41 +01:00
Fixed some errors & warnings when running mariadb-upgrade on MySQL instance
- Moved view checks after privilege tables are fixed. This is to avoid warnings about wrongly defined mysql.proc when checking views. - Don't use stat tables before they have been fixed. - Don't run mysql_fix_view() if 'FOR MYSQL' is used if the view is already a MariaDB view. - Added 'FOR UPGRADE' as an option for 'REPAIR VIEW' to be able to detect if the REPAIR command comes from mariadb_upgrade. In this case we get a warning, instead of an error, if a definer of a view does not exists.
This commit is contained in:
parent
324d8a6036
commit
d671fec431
28 changed files with 371 additions and 737 deletions
client
mysql-test/main
ctype_upgrade.resultlog_tables_upgrade.resultlowercase_fs_off.resultmysql_json_mysql_upgrade.resultmysql_json_mysql_upgrade_with_plugin_loaded.resultmysql_upgrade-20228.resultmysql_upgrade-6984.resultmysql_upgrade.resultmysql_upgrade_mysql_json_datatype.resultmysql_upgrade_no_innodb.resultmysql_upgrade_noengine.resultmysql_upgrade_noengine.testmysql_upgrade_ssl.resultmysql_upgrade_view.resultupgrade_MDEV-19650.resultupgrade_MDEV-23102-1.resultupgrade_MDEV-23102-2.resultupgrade_geometrycolumn_procedure_definer.resultupgrade_mdev_24363.result
scripts
sql
|
@ -22,7 +22,7 @@
|
|||
|
||||
#include <welcome_copyright_notice.h> /* ORACLE_WELCOME_COPYRIGHT_NOTICE */
|
||||
|
||||
#define VER "2.0"
|
||||
#define VER "2.1"
|
||||
|
||||
#ifdef HAVE_SYS_WAIT_H
|
||||
#include <sys/wait.h>
|
||||
|
@ -38,7 +38,7 @@
|
|||
|
||||
static int phase = 0;
|
||||
static int info_file= -1;
|
||||
static const int phases_total = 7;
|
||||
static const int phases_total = 8;
|
||||
static char mysql_path[FN_REFLEN];
|
||||
static char mysqlcheck_path[FN_REFLEN];
|
||||
|
||||
|
@ -982,7 +982,7 @@ static my_bool is_mysql()
|
|||
|
||||
static int run_mysqlcheck_views(void)
|
||||
{
|
||||
const char *upgrade_views="--process-views=YES";
|
||||
const char *upgrade_views="--process-views=UPGRADE";
|
||||
if (upgrade_from_mysql)
|
||||
{
|
||||
/*
|
||||
|
@ -1122,8 +1122,9 @@ static my_bool from_before_10_1()
|
|||
}
|
||||
|
||||
|
||||
static void uninstall_plugins(void)
|
||||
static int uninstall_plugins(void)
|
||||
{
|
||||
verbose("Phase %d/%d: uninstalling plugins", ++phase, phases_total);
|
||||
if (ds_plugin_data_types.length)
|
||||
{
|
||||
char *plugins= ds_plugin_data_types.str;
|
||||
|
@ -1140,7 +1141,10 @@ static void uninstall_plugins(void)
|
|||
next= get_line(next);
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
@brief Install plugins for missing data types
|
||||
@details Check for entries with "Unknown data type" in I_S.TABLES,
|
||||
|
@ -1189,6 +1193,8 @@ static int install_used_plugin_data_types(void)
|
|||
dynstr_free(&ds_result);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
Check for entries with "Unknown storage engine" in I_S.TABLES,
|
||||
try to load plugins for these tables if available (MDEV-11942)
|
||||
|
@ -1239,6 +1245,7 @@ static int install_used_engines(void)
|
|||
return 0;
|
||||
}
|
||||
|
||||
|
||||
static int check_slave_repositories(void)
|
||||
{
|
||||
DYNAMIC_STRING ds_result;
|
||||
|
@ -1366,6 +1373,13 @@ static int run_sql_fix_privilege_tables(void)
|
|||
}
|
||||
|
||||
|
||||
static int flush_privileges(void)
|
||||
{
|
||||
verbose("Phase %d/%d: Running 'FLUSH PRIVILEGES'", ++phase, phases_total);
|
||||
return run_query("FLUSH PRIVILEGES", NULL, TRUE);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
Check if the server version matches with the server version mysql_upgrade
|
||||
was compiled with.
|
||||
|
@ -1395,10 +1409,11 @@ static int check_version_match(void)
|
|||
|
||||
if (calc_server_version((char *) version_str) != MYSQL_VERSION_ID)
|
||||
{
|
||||
fprintf(stderr, "Error: Server version (%s) does not match with the "
|
||||
"version of\nthe server (%s) with which this program was built/"
|
||||
"distributed. You can\nuse --skip-version-check to skip this "
|
||||
"check.\n", version_str, MYSQL_SERVER_VERSION);
|
||||
fprintf(stderr, "Error: Server version (%s)\n"
|
||||
"does not match the version of the server (%s)\n"
|
||||
"with which this program was built/distributed. You can\n"
|
||||
"use --skip-version-check to skip this check.\n",
|
||||
version_str, MYSQL_SERVER_VERSION);
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
|
@ -1486,18 +1501,14 @@ int main(int argc, char **argv)
|
|||
if (run_mysqlcheck_upgrade(TRUE) ||
|
||||
install_used_engines() ||
|
||||
install_used_plugin_data_types() ||
|
||||
run_mysqlcheck_views() ||
|
||||
run_sql_fix_privilege_tables() ||
|
||||
run_mysqlcheck_views() ||
|
||||
run_mysqlcheck_fixnames() ||
|
||||
run_mysqlcheck_upgrade(FALSE) ||
|
||||
check_slave_repositories())
|
||||
check_slave_repositories() ||
|
||||
uninstall_plugins() ||
|
||||
flush_privileges())
|
||||
die("Upgrade failed" );
|
||||
|
||||
uninstall_plugins();
|
||||
verbose("Phase %d/%d: Running 'FLUSH PRIVILEGES'", ++phase, phases_total);
|
||||
if (run_query("FLUSH PRIVILEGES", NULL, TRUE))
|
||||
die("Upgrade failed" );
|
||||
|
||||
verbose("OK");
|
||||
|
||||
/* Finish writing indicating upgrade has been performed */
|
||||
|
|
|
@ -63,8 +63,9 @@ const char *operation_name[]=
|
|||
"???", "check", "repair", "analyze", "optimize", "fix names"
|
||||
};
|
||||
|
||||
typedef enum { DO_VIEWS_NO, DO_VIEWS_YES, DO_VIEWS_FROM_MYSQL } enum_do_views;
|
||||
const char *do_views_opts[]= {"NO", "YES", "UPGRADE_FROM_MYSQL", NullS};
|
||||
typedef enum { DO_VIEWS_NO, DO_VIEWS_YES, DO_UPGRADE, DO_VIEWS_FROM_MYSQL } enum_do_views;
|
||||
const char *do_views_opts[]= {"NO", "YES", "UPGRADE", "UPGRADE_FROM_MYSQL",
|
||||
NullS};
|
||||
TYPELIB do_views_typelib= { array_elements(do_views_opts) - 1, "",
|
||||
do_views_opts, NULL };
|
||||
static ulong opt_do_views= DO_VIEWS_NO;
|
||||
|
@ -213,8 +214,9 @@ static struct my_option my_long_options[] =
|
|||
{"process-views", 0,
|
||||
"Perform the requested operation (check or repair) on views. "
|
||||
"One of: NO, YES (correct the checksum, if necessary, add the "
|
||||
"mariadb-version field), UPGRADE_FROM_MYSQL (same as YES and toggle "
|
||||
"the algorithm MERGE<->TEMPTABLE.", &opt_do_views, &opt_do_views,
|
||||
"mariadb-version field), UPGRADE (run from mariadb-upgrade), "
|
||||
"UPGRADE_FROM_MYSQL (same as YES and toggle the algorithm "
|
||||
"MERGE<->TEMPTABLE.", &opt_do_views, &opt_do_views,
|
||||
&do_views_typelib, GET_ENUM, OPT_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"process-tables", 0, "Perform the requested operation on tables.",
|
||||
&opt_do_tables, &opt_do_tables, 0, GET_BOOL, NO_ARG, 1, 0, 0, 0, 0, 0},
|
||||
|
@ -922,7 +924,10 @@ static int handle_request_for_tables(char *tables, size_t length,
|
|||
op= opt_write_binlog ? "REPAIR" : "REPAIR NO_WRITE_TO_BINLOG";
|
||||
if (view)
|
||||
{
|
||||
if (opt_do_views == DO_VIEWS_FROM_MYSQL) end = strmov(end, " FROM MYSQL");
|
||||
if (opt_do_views == DO_VIEWS_FROM_MYSQL)
|
||||
end = strmov(end, " FROM MYSQL");
|
||||
else if (opt_do_views == DO_UPGRADE)
|
||||
end = strmov(end, " FOR UPGRADE");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -227,7 +227,7 @@ DROP TABLE mysql050614_xxx_croatian_ci;
|
|||
# Checking mysql_upgrade
|
||||
#
|
||||
# Running mysql_upgrade
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -258,8 +258,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -361,9 +362,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -384,11 +384,12 @@ test.maria050313_ucs2_croatian_ci_def OK
|
|||
test.maria050313_utf8_croatian_ci OK
|
||||
test.maria050533_xxx_croatian_ci OK
|
||||
test.maria100004_xxx_croatian_ci OK
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
# Running mysql_upgrade for the second time
|
||||
# This should report OK for all tables
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -419,8 +420,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -522,9 +524,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -539,7 +540,8 @@ test.maria050313_utf8_croatian_ci OK
|
|||
test.maria050533_xxx_croatian_ci OK
|
||||
test.maria100004_xxx_croatian_ci OK
|
||||
test.mysql050614_xxx_croatian_ci OK
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
SHOW CREATE TABLE maria050313_ucs2_croatian_ci_def;
|
||||
Table Create Table
|
||||
|
|
|
@ -11,7 +11,7 @@ Table Op Msg_type Msg_text
|
|||
test.bug49823 repair status OK
|
||||
RENAME TABLE general_log TO renamed_general_log;
|
||||
RENAME TABLE test.bug49823 TO general_log;
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -43,8 +43,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -146,9 +147,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -158,7 +158,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
DROP TABLE general_log;
|
||||
RENAME TABLE renamed_general_log TO general_log;
|
||||
|
|
|
@ -86,7 +86,7 @@ DROP TABLE t1;
|
|||
create database TEST;
|
||||
create procedure TEST.pr() begin end;
|
||||
create procedure test.pr() begin end;
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -134,8 +134,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -237,9 +238,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
TEST
|
||||
information_schema
|
||||
|
@ -250,7 +250,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
drop procedure test.pr;
|
||||
drop database TEST;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
SET NAMES utf8;
|
||||
show create table mysql_json_test;
|
||||
ERROR HY000: Unknown data type: 'MYSQL_JSON'
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -53,9 +53,10 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
installing plugin for MYSQL_JSON data type
|
||||
Phase 3/7: Fixing views
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -157,9 +158,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -175,8 +175,9 @@ test.mysql_json_test_big Needs upgrade
|
|||
Repairing tables
|
||||
test.mysql_json_test OK
|
||||
test.mysql_json_test_big OK
|
||||
Phase 7/8: uninstalling plugins
|
||||
uninstalling plugin for 'type_mysql_json' data type
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
show create table mysql_json_test;
|
||||
Table Create Table
|
||||
|
|
|
@ -6,7 +6,7 @@ SET NAMES utf8;
|
|||
call mtr.add_suppression("Table rebuild required");
|
||||
show create table mysql_json_test;
|
||||
ERROR HY000: Table rebuild required. Please do "ALTER TABLE `test.mysql_json_test` FORCE" or dump/reload to fix it!
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -54,8 +54,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -157,9 +158,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -175,7 +175,8 @@ test.mysql_json_test_big Needs upgrade
|
|||
Repairing tables
|
||||
test.mysql_json_test OK
|
||||
test.mysql_json_test_big OK
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
show create table mysql_json_test;
|
||||
Table Create Table
|
||||
|
|
|
@ -16,7 +16,7 @@ WHERE TABLE_SCHEMA='mysql' AND TABLE_NAME='user';
|
|||
CHARACTER_SET_CLIENT COLLATION_CONNECTION
|
||||
utf8mb4 utf8mb4_unicode_ci
|
||||
# Running mysql_upgrade
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -47,8 +47,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -150,9 +151,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -162,7 +162,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
#
|
||||
# Restoring character_set_client and collation_connection back
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
update mysql.global_priv set priv=json_set(priv, '$.plugin', 'mysql_native_password', '$.authentication_string', password('foo')) where user='root';
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -47,8 +47,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -150,9 +151,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -162,7 +162,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
connect con1,localhost,root,foo,,,;
|
||||
update mysql.global_priv set priv=json_compact(json_remove(priv, '$.plugin', '$.authentication_string')) where user='root';
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
set sql_mode="";
|
||||
Run mysql_upgrade once
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -31,8 +31,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -134,9 +135,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -146,13 +146,14 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
Run it again - should say already completed
|
||||
This installation of MariaDB is already upgraded to VERSION.There is no need to run mysql_upgrade again for VERSION.
|
||||
You can use --force if you still want to run mysql_upgrade
|
||||
Force should run it regardless of whether it has been run before
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -183,8 +184,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -286,9 +288,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -298,12 +299,13 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
CREATE USER mysqltest1@'%' IDENTIFIED by 'sakila';
|
||||
GRANT ALL ON *.* TO mysqltest1@'%';
|
||||
Run mysql_upgrade with password protected account
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -334,8 +336,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -437,9 +440,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -449,7 +451,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
DROP USER mysqltest1@'%';
|
||||
Reading datadir from the MariaDB server failed. Got the following error when executing the 'mysql' command line client
|
||||
|
@ -460,7 +463,7 @@ Reading datadir from the MariaDB server failed. Got the following error when exe
|
|||
ERROR 2005 (HY000): Unknown server host 'not_existing_host' (errno)
|
||||
FATAL ERROR: Upgrade failed
|
||||
set GLOBAL sql_mode='STRICT_ALL_TABLES,ANSI_QUOTES,NO_ZERO_DATE';
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -491,8 +494,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -594,9 +598,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -606,7 +609,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
set GLOBAL sql_mode=default;
|
||||
#
|
||||
|
@ -617,7 +621,7 @@ CREATE PROCEDURE testproc() BEGIN END;
|
|||
UPDATE mysql.proc SET character_set_client = NULL WHERE name LIKE 'testproc';
|
||||
UPDATE mysql.proc SET collation_connection = NULL WHERE name LIKE 'testproc';
|
||||
UPDATE mysql.proc SET db_collation = NULL WHERE name LIKE 'testproc';
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -648,8 +652,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -751,9 +756,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -763,7 +767,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
CALL testproc();
|
||||
DROP PROCEDURE testproc;
|
||||
|
@ -777,7 +782,7 @@ WARNING: NULL values of the 'db_collation' column ('mysql.proc' table) have been
|
|||
GRANT USAGE ON *.* TO 'user3'@'%';
|
||||
GRANT ALL PRIVILEGES ON `roelt`.`test2` TO 'user3'@'%';
|
||||
Run mysql_upgrade with all privileges on a user
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -808,8 +813,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -911,9 +917,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -923,7 +928,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
SHOW GRANTS FOR 'user3'@'%';
|
||||
Grants for user3@%
|
||||
|
@ -932,7 +938,7 @@ GRANT ALL PRIVILEGES ON `roelt`.`test2` TO `user3`@`%`
|
|||
DROP USER 'user3'@'%';
|
||||
# End of 5.1 tests
|
||||
The --upgrade-system-tables option was used, user tables won't be touched.
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -963,12 +969,13 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views... Skipped
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names ... Skipped
|
||||
Phase 6/7: Checking and upgrading tables... Skipped
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views... Skipped
|
||||
Phase 5/8: Fixing table and database names ... Skipped
|
||||
Phase 6/8: Checking and upgrading tables... Skipped
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
#
|
||||
# Bug#11827359 60223: MYSQL_UPGRADE PROBLEM WITH OPTION
|
||||
|
@ -976,7 +983,7 @@ OK
|
|||
#
|
||||
# Droping the previously created mysql_upgrade_info file..
|
||||
# Running mysql_upgrade with --skip-write-binlog..
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -1007,8 +1014,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -1110,9 +1118,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -1122,7 +1129,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
#
|
||||
# Bug #21489398: MYSQL_UPGRADE: FATAL ERROR: UPGRADE FAILED - IMPROVE ERROR
|
||||
|
@ -1147,7 +1155,7 @@ GRANT INSERT ON mysql.user TO very_long_user_name_number_2;
|
|||
GRANT UPDATE (User) ON mysql.db TO very_long_user_name_number_1;
|
||||
GRANT UPDATE (User) ON mysql.db TO very_long_user_name_number_2;
|
||||
CREATE PROCEDURE test.pr() BEGIN END;
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -1178,8 +1186,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -1281,9 +1290,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -1293,7 +1301,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
SELECT definer FROM mysql.proc WHERE db = 'test' AND name = 'pr';
|
||||
definer
|
||||
|
@ -1326,7 +1335,7 @@ set sql_mode=default;
|
|||
create table test.t1(a int) engine=MyISAM;
|
||||
# Trying to enforce InnoDB for all tables
|
||||
SET GLOBAL enforce_storage_engine=InnoDB;
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -1357,8 +1366,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -1460,9 +1470,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -1473,7 +1482,8 @@ sys
|
|||
sys.sys_config OK
|
||||
test
|
||||
test.t1 OK
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
# Should return 2
|
||||
SELECT count(*) FROM information_schema.tables where ENGINE="InnoDB";
|
||||
|
@ -1544,7 +1554,7 @@ user CREATE TABLE `user` (
|
|||
`account_locked` enum('N','Y') CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL DEFAULT 'N',
|
||||
PRIMARY KEY (`Host`,`User`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_bin COMMENT='Users and global privileges'
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -1577,9 +1587,11 @@ mysql.time_zone_transition_type OK
|
|||
mysql.transaction_registry OK
|
||||
mysql.user OK
|
||||
Upgrading from a version before MariaDB-10.1
|
||||
Phase 2/7: Installing used storage engines
|
||||
Phase 2/8: Installing used storage engines
|
||||
Checking for tables with unknown storage engine
|
||||
Phase 3/7: Fixing views
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
sys.host_summary_by_file_io_type OK
|
||||
|
@ -1680,9 +1692,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -1692,7 +1703,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
SHOW CREATE TABLE mysql.user;
|
||||
View Create View character_set_client collation_connection
|
||||
|
@ -1722,7 +1734,7 @@ ALTER TABLE mysql.user ADD is_role enum('N', 'Y') COLLATE utf8_general_ci DEFAUL
|
|||
ALTER TABLE mysql.user ADD default_role char(80) binary DEFAULT '' NOT NULL;
|
||||
ALTER TABLE mysql.user ADD max_statement_time decimal(12,6) DEFAULT 0 NOT NULL;
|
||||
FLUSH PRIVILEGES;
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -1754,8 +1766,12 @@ mysql.time_zone_transition OK
|
|||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
mysql.user OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user
|
||||
Warning : The user specified as a definer ('mariadb.sys'@'localhost') does not exist
|
||||
status : OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
sys.host_summary_by_file_io_type OK
|
||||
|
@ -1856,9 +1872,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -1868,7 +1883,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
SHOW CREATE TABLE mysql.user;
|
||||
View Create View character_set_client collation_connection
|
||||
|
@ -1953,7 +1969,7 @@ SET GLOBAL alter_algorithm='INPLACE';
|
|||
SHOW GLOBAL VARIABLES LIKE 'alter_algorithm';
|
||||
Variable_name Value
|
||||
alter_algorithm INPLACE
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -1984,8 +2000,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -2087,9 +2104,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -2099,7 +2115,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
SET GLOBAL alter_algorithm=DEFAULT;
|
||||
SHOW GLOBAL VARIABLES LIKE 'alter_algorithm';
|
||||
|
@ -2167,7 +2184,7 @@ FLUSH PRIVILEGES;
|
|||
CREATE USER mariadb_102;
|
||||
UPDATE mysql.user SET password_last_changed=0 WHERE user='mariadb_102';
|
||||
FLUSH PRIVILEGES;
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -2200,9 +2217,13 @@ mysql.time_zone_transition_type OK
|
|||
mysql.transaction_registry OK
|
||||
mysql.user OK
|
||||
Upgrading from a version before MariaDB-10.1
|
||||
Phase 2/7: Installing used storage engines
|
||||
Phase 2/8: Installing used storage engines
|
||||
Checking for tables with unknown storage engine
|
||||
Phase 3/7: Fixing views
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user
|
||||
Warning : The user specified as a definer ('mariadb.sys'@'localhost') does not exist
|
||||
status : OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
sys.host_summary_by_file_io_type OK
|
||||
|
@ -2303,9 +2324,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -2315,7 +2335,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
SHOW CREATE USER mariadb_102;
|
||||
CREATE USER for mariadb_102@%
|
||||
|
|
|
@ -10,7 +10,7 @@ ERROR HY000: Table rebuild required. Please do "ALTER TABLE `test.mysql_json_tes
|
|||
show create table mysql_json_test_big;
|
||||
ERROR HY000: Table rebuild required. Please do "ALTER TABLE `test.mysql_json_test_big` FORCE" or dump/reload to fix it!
|
||||
# Run mysql_upgrade to fix the tables containing JSON.
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -41,8 +41,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -144,9 +145,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -164,7 +164,8 @@ Repairing tables
|
|||
test.mysql_json_test OK
|
||||
test.mysql_json_test_big OK
|
||||
test.tempty OK
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
#
|
||||
# Now check if the table structure is correct and that the data
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
The --upgrade-system-tables option was used, user tables won't be touched.
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -47,10 +47,11 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views... Skipped
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names ... Skipped
|
||||
Phase 6/7: Checking and upgrading tables... Skipped
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views... Skipped
|
||||
Phase 5/8: Fixing table and database names ... Skipped
|
||||
Phase 6/8: Checking and upgrading tables... Skipped
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
|
|
|
@ -56,168 +56,18 @@ Level Warning
|
|||
Code 1286
|
||||
Message Unknown storage engine 'ARCHIVE'
|
||||
# upgrade from 10.1 - engines aren't enabled
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
mysql.columns_priv OK
|
||||
mysql.db OK
|
||||
mysql.event OK
|
||||
mysql.func OK
|
||||
mysql.global_priv_bak OK
|
||||
mysql.gtid_slave_pos OK
|
||||
mysql.help_category OK
|
||||
mysql.help_keyword OK
|
||||
mysql.help_relation OK
|
||||
mysql.help_topic OK
|
||||
mysql.index_stats OK
|
||||
mysql.innodb_index_stats OK
|
||||
mysql.innodb_table_stats OK
|
||||
mysql.plugin OK
|
||||
mysql.proc OK
|
||||
mysql.procs_priv OK
|
||||
mysql.proxies_priv OK
|
||||
mysql.roles_mapping OK
|
||||
mysql.servers OK
|
||||
mysql.table_stats OK
|
||||
mysql.tables_priv OK
|
||||
mysql.time_zone OK
|
||||
mysql.time_zone_leap_second OK
|
||||
mysql.time_zone_name OK
|
||||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
mysql.user OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
sys.host_summary_by_file_io_type OK
|
||||
sys.host_summary_by_stages OK
|
||||
sys.host_summary_by_statement_latency OK
|
||||
sys.host_summary_by_statement_type OK
|
||||
sys.innodb_buffer_stats_by_schema OK
|
||||
sys.innodb_buffer_stats_by_table OK
|
||||
sys.innodb_lock_waits OK
|
||||
sys.io_by_thread_by_latency OK
|
||||
sys.io_global_by_file_by_bytes OK
|
||||
sys.io_global_by_file_by_latency OK
|
||||
sys.io_global_by_wait_by_bytes OK
|
||||
sys.io_global_by_wait_by_latency OK
|
||||
sys.latest_file_io OK
|
||||
sys.memory_by_host_by_current_bytes OK
|
||||
sys.memory_by_thread_by_current_bytes OK
|
||||
sys.memory_by_user_by_current_bytes OK
|
||||
sys.memory_global_by_current_bytes OK
|
||||
sys.memory_global_total OK
|
||||
sys.metrics OK
|
||||
sys.processlist OK
|
||||
sys.ps_check_lost_instrumentation OK
|
||||
sys.schema_auto_increment_columns OK
|
||||
sys.schema_index_statistics OK
|
||||
sys.schema_object_overview OK
|
||||
sys.schema_redundant_indexes OK
|
||||
sys.schema_table_lock_waits OK
|
||||
sys.schema_table_statistics OK
|
||||
sys.schema_table_statistics_with_buffer OK
|
||||
sys.schema_tables_with_full_table_scans OK
|
||||
sys.schema_unused_indexes OK
|
||||
sys.session OK
|
||||
sys.session_ssl_status OK
|
||||
sys.statement_analysis OK
|
||||
sys.statements_with_errors_or_warnings OK
|
||||
sys.statements_with_full_table_scans OK
|
||||
sys.statements_with_runtimes_in_95th_percentile OK
|
||||
sys.statements_with_sorting OK
|
||||
sys.statements_with_temp_tables OK
|
||||
sys.user_summary OK
|
||||
sys.user_summary_by_file_io OK
|
||||
sys.user_summary_by_file_io_type OK
|
||||
sys.user_summary_by_stages OK
|
||||
sys.user_summary_by_statement_latency OK
|
||||
sys.user_summary_by_statement_type OK
|
||||
sys.version OK
|
||||
sys.wait_classes_global_by_avg_latency OK
|
||||
sys.wait_classes_global_by_latency OK
|
||||
sys.waits_by_host_by_latency OK
|
||||
sys.waits_by_user_by_latency OK
|
||||
sys.waits_global_by_latency OK
|
||||
sys.x$host_summary OK
|
||||
sys.x$host_summary_by_file_io OK
|
||||
sys.x$host_summary_by_file_io_type OK
|
||||
sys.x$host_summary_by_stages OK
|
||||
sys.x$host_summary_by_statement_latency OK
|
||||
sys.x$host_summary_by_statement_type OK
|
||||
sys.x$innodb_buffer_stats_by_schema OK
|
||||
sys.x$innodb_buffer_stats_by_table OK
|
||||
sys.x$innodb_lock_waits OK
|
||||
sys.x$io_by_thread_by_latency OK
|
||||
sys.x$io_global_by_file_by_bytes OK
|
||||
sys.x$io_global_by_file_by_latency OK
|
||||
sys.x$io_global_by_wait_by_bytes OK
|
||||
sys.x$io_global_by_wait_by_latency OK
|
||||
sys.x$latest_file_io OK
|
||||
sys.x$memory_by_host_by_current_bytes OK
|
||||
sys.x$memory_by_thread_by_current_bytes OK
|
||||
sys.x$memory_by_user_by_current_bytes OK
|
||||
sys.x$memory_global_by_current_bytes OK
|
||||
sys.x$memory_global_total OK
|
||||
sys.x$processlist OK
|
||||
sys.x$ps_digest_95th_percentile_by_avg_us OK
|
||||
sys.x$ps_digest_avg_latency_distribution OK
|
||||
sys.x$ps_schema_table_statistics_io OK
|
||||
sys.x$schema_flattened_keys OK
|
||||
sys.x$schema_index_statistics OK
|
||||
sys.x$schema_table_lock_waits OK
|
||||
sys.x$schema_table_statistics OK
|
||||
sys.x$schema_table_statistics_with_buffer OK
|
||||
sys.x$schema_tables_with_full_table_scans OK
|
||||
sys.x$session OK
|
||||
sys.x$statement_analysis OK
|
||||
sys.x$statements_with_errors_or_warnings OK
|
||||
sys.x$statements_with_full_table_scans OK
|
||||
sys.x$statements_with_runtimes_in_95th_percentile OK
|
||||
sys.x$statements_with_sorting OK
|
||||
sys.x$statements_with_temp_tables OK
|
||||
sys.x$user_summary OK
|
||||
sys.x$user_summary_by_file_io OK
|
||||
sys.x$user_summary_by_file_io_type OK
|
||||
sys.x$user_summary_by_stages OK
|
||||
sys.x$user_summary_by_statement_latency OK
|
||||
sys.x$user_summary_by_statement_type OK
|
||||
sys.x$wait_classes_global_by_avg_latency OK
|
||||
sys.x$wait_classes_global_by_latency OK
|
||||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
mtr.global_suppressions OK
|
||||
mtr.test_suppressions OK
|
||||
performance_schema
|
||||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
test.t1
|
||||
Error : Unknown storage engine 'BLACKHOLE'
|
||||
error : Corrupt
|
||||
test.t2
|
||||
Error : Unknown storage engine 'ARCHIVE'
|
||||
error : Corrupt
|
||||
|
||||
Repairing tables
|
||||
test.t1
|
||||
Error : Unknown storage engine 'BLACKHOLE'
|
||||
error : Corrupt
|
||||
test.t2
|
||||
Error : Unknown storage engine 'ARCHIVE'
|
||||
error : Corrupt
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
select table_catalog, table_schema, table_name, table_type, engine, row_format, table_rows, data_length, table_comment from information_schema.tables where table_schema='test' and table_name='t1';
|
||||
table_catalog def
|
||||
table_schema test
|
||||
|
@ -252,169 +102,18 @@ rename table mysql.global_priv_bak to mysql.global_priv;
|
|||
drop view mysql.user_bak;
|
||||
alter table mysql.user drop column default_role, drop column max_statement_time;
|
||||
# still upgrade from 10.1
|
||||
Major version upgrade detected from MariaDB to MariaDB . Check required!
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
mysql.columns_priv OK
|
||||
mysql.db OK
|
||||
mysql.event OK
|
||||
mysql.func OK
|
||||
mysql.global_priv_bak OK
|
||||
mysql.gtid_slave_pos OK
|
||||
mysql.help_category OK
|
||||
mysql.help_keyword OK
|
||||
mysql.help_relation OK
|
||||
mysql.help_topic OK
|
||||
mysql.index_stats OK
|
||||
mysql.innodb_index_stats OK
|
||||
mysql.innodb_table_stats OK
|
||||
mysql.plugin OK
|
||||
mysql.proc OK
|
||||
mysql.procs_priv OK
|
||||
mysql.proxies_priv OK
|
||||
mysql.roles_mapping OK
|
||||
mysql.servers OK
|
||||
mysql.table_stats OK
|
||||
mysql.tables_priv OK
|
||||
mysql.time_zone OK
|
||||
mysql.time_zone_leap_second OK
|
||||
mysql.time_zone_name OK
|
||||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
mysql.user OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
sys.host_summary_by_file_io_type OK
|
||||
sys.host_summary_by_stages OK
|
||||
sys.host_summary_by_statement_latency OK
|
||||
sys.host_summary_by_statement_type OK
|
||||
sys.innodb_buffer_stats_by_schema OK
|
||||
sys.innodb_buffer_stats_by_table OK
|
||||
sys.innodb_lock_waits OK
|
||||
sys.io_by_thread_by_latency OK
|
||||
sys.io_global_by_file_by_bytes OK
|
||||
sys.io_global_by_file_by_latency OK
|
||||
sys.io_global_by_wait_by_bytes OK
|
||||
sys.io_global_by_wait_by_latency OK
|
||||
sys.latest_file_io OK
|
||||
sys.memory_by_host_by_current_bytes OK
|
||||
sys.memory_by_thread_by_current_bytes OK
|
||||
sys.memory_by_user_by_current_bytes OK
|
||||
sys.memory_global_by_current_bytes OK
|
||||
sys.memory_global_total OK
|
||||
sys.metrics OK
|
||||
sys.processlist OK
|
||||
sys.ps_check_lost_instrumentation OK
|
||||
sys.schema_auto_increment_columns OK
|
||||
sys.schema_index_statistics OK
|
||||
sys.schema_object_overview OK
|
||||
sys.schema_redundant_indexes OK
|
||||
sys.schema_table_lock_waits OK
|
||||
sys.schema_table_statistics OK
|
||||
sys.schema_table_statistics_with_buffer OK
|
||||
sys.schema_tables_with_full_table_scans OK
|
||||
sys.schema_unused_indexes OK
|
||||
sys.session OK
|
||||
sys.session_ssl_status OK
|
||||
sys.statement_analysis OK
|
||||
sys.statements_with_errors_or_warnings OK
|
||||
sys.statements_with_full_table_scans OK
|
||||
sys.statements_with_runtimes_in_95th_percentile OK
|
||||
sys.statements_with_sorting OK
|
||||
sys.statements_with_temp_tables OK
|
||||
sys.user_summary OK
|
||||
sys.user_summary_by_file_io OK
|
||||
sys.user_summary_by_file_io_type OK
|
||||
sys.user_summary_by_stages OK
|
||||
sys.user_summary_by_statement_latency OK
|
||||
sys.user_summary_by_statement_type OK
|
||||
sys.version OK
|
||||
sys.wait_classes_global_by_avg_latency OK
|
||||
sys.wait_classes_global_by_latency OK
|
||||
sys.waits_by_host_by_latency OK
|
||||
sys.waits_by_user_by_latency OK
|
||||
sys.waits_global_by_latency OK
|
||||
sys.x$host_summary OK
|
||||
sys.x$host_summary_by_file_io OK
|
||||
sys.x$host_summary_by_file_io_type OK
|
||||
sys.x$host_summary_by_stages OK
|
||||
sys.x$host_summary_by_statement_latency OK
|
||||
sys.x$host_summary_by_statement_type OK
|
||||
sys.x$innodb_buffer_stats_by_schema OK
|
||||
sys.x$innodb_buffer_stats_by_table OK
|
||||
sys.x$innodb_lock_waits OK
|
||||
sys.x$io_by_thread_by_latency OK
|
||||
sys.x$io_global_by_file_by_bytes OK
|
||||
sys.x$io_global_by_file_by_latency OK
|
||||
sys.x$io_global_by_wait_by_bytes OK
|
||||
sys.x$io_global_by_wait_by_latency OK
|
||||
sys.x$latest_file_io OK
|
||||
sys.x$memory_by_host_by_current_bytes OK
|
||||
sys.x$memory_by_thread_by_current_bytes OK
|
||||
sys.x$memory_by_user_by_current_bytes OK
|
||||
sys.x$memory_global_by_current_bytes OK
|
||||
sys.x$memory_global_total OK
|
||||
sys.x$processlist OK
|
||||
sys.x$ps_digest_95th_percentile_by_avg_us OK
|
||||
sys.x$ps_digest_avg_latency_distribution OK
|
||||
sys.x$ps_schema_table_statistics_io OK
|
||||
sys.x$schema_flattened_keys OK
|
||||
sys.x$schema_index_statistics OK
|
||||
sys.x$schema_table_lock_waits OK
|
||||
sys.x$schema_table_statistics OK
|
||||
sys.x$schema_table_statistics_with_buffer OK
|
||||
sys.x$schema_tables_with_full_table_scans OK
|
||||
sys.x$session OK
|
||||
sys.x$statement_analysis OK
|
||||
sys.x$statements_with_errors_or_warnings OK
|
||||
sys.x$statements_with_full_table_scans OK
|
||||
sys.x$statements_with_runtimes_in_95th_percentile OK
|
||||
sys.x$statements_with_sorting OK
|
||||
sys.x$statements_with_temp_tables OK
|
||||
sys.x$user_summary OK
|
||||
sys.x$user_summary_by_file_io OK
|
||||
sys.x$user_summary_by_file_io_type OK
|
||||
sys.x$user_summary_by_stages OK
|
||||
sys.x$user_summary_by_statement_latency OK
|
||||
sys.x$user_summary_by_statement_type OK
|
||||
sys.x$wait_classes_global_by_avg_latency OK
|
||||
sys.x$wait_classes_global_by_latency OK
|
||||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
mtr.global_suppressions OK
|
||||
mtr.test_suppressions OK
|
||||
performance_schema
|
||||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
test.t1
|
||||
Error : Unknown storage engine 'BLACKHOLE'
|
||||
error : Corrupt
|
||||
test.t2
|
||||
Error : Unknown storage engine 'ARCHIVE'
|
||||
error : Corrupt
|
||||
|
||||
Repairing tables
|
||||
test.t1
|
||||
Error : Unknown storage engine 'BLACKHOLE'
|
||||
error : Corrupt
|
||||
test.t2
|
||||
Error : Unknown storage engine 'ARCHIVE'
|
||||
error : Corrupt
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
select table_catalog, table_schema, table_name, table_type, engine, row_format, table_rows, data_length, table_comment from information_schema.tables where table_schema='test' and table_name='t1';
|
||||
table_catalog def
|
||||
table_schema test
|
||||
|
@ -449,160 +148,6 @@ rename table mysql.global_priv_bak to mysql.global_priv;
|
|||
drop view mysql.user_bak;
|
||||
alter table mysql.user drop column default_role, drop column max_statement_time;
|
||||
# upgrade from 10.0 - engines are enabled
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
mysql.columns_priv OK
|
||||
mysql.db OK
|
||||
mysql.event OK
|
||||
mysql.func OK
|
||||
mysql.global_priv_bak OK
|
||||
mysql.gtid_slave_pos OK
|
||||
mysql.help_category OK
|
||||
mysql.help_keyword OK
|
||||
mysql.help_relation OK
|
||||
mysql.help_topic OK
|
||||
mysql.index_stats OK
|
||||
mysql.innodb_index_stats OK
|
||||
mysql.innodb_table_stats OK
|
||||
mysql.plugin OK
|
||||
mysql.proc OK
|
||||
mysql.procs_priv OK
|
||||
mysql.proxies_priv OK
|
||||
mysql.roles_mapping OK
|
||||
mysql.servers OK
|
||||
mysql.table_stats OK
|
||||
mysql.tables_priv OK
|
||||
mysql.time_zone OK
|
||||
mysql.time_zone_leap_second OK
|
||||
mysql.time_zone_name OK
|
||||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
mysql.user OK
|
||||
Upgrading from a version before MariaDB-10.1
|
||||
Phase 2/7: Installing used storage engines
|
||||
Checking for tables with unknown storage engine
|
||||
installing plugin for 'archive' storage engine
|
||||
installing plugin for 'blackhole' storage engine
|
||||
Phase 3/7: Fixing views
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
sys.host_summary_by_file_io_type OK
|
||||
sys.host_summary_by_stages OK
|
||||
sys.host_summary_by_statement_latency OK
|
||||
sys.host_summary_by_statement_type OK
|
||||
sys.innodb_buffer_stats_by_schema OK
|
||||
sys.innodb_buffer_stats_by_table OK
|
||||
sys.innodb_lock_waits OK
|
||||
sys.io_by_thread_by_latency OK
|
||||
sys.io_global_by_file_by_bytes OK
|
||||
sys.io_global_by_file_by_latency OK
|
||||
sys.io_global_by_wait_by_bytes OK
|
||||
sys.io_global_by_wait_by_latency OK
|
||||
sys.latest_file_io OK
|
||||
sys.memory_by_host_by_current_bytes OK
|
||||
sys.memory_by_thread_by_current_bytes OK
|
||||
sys.memory_by_user_by_current_bytes OK
|
||||
sys.memory_global_by_current_bytes OK
|
||||
sys.memory_global_total OK
|
||||
sys.metrics OK
|
||||
sys.processlist OK
|
||||
sys.ps_check_lost_instrumentation OK
|
||||
sys.schema_auto_increment_columns OK
|
||||
sys.schema_index_statistics OK
|
||||
sys.schema_object_overview OK
|
||||
sys.schema_redundant_indexes OK
|
||||
sys.schema_table_lock_waits OK
|
||||
sys.schema_table_statistics OK
|
||||
sys.schema_table_statistics_with_buffer OK
|
||||
sys.schema_tables_with_full_table_scans OK
|
||||
sys.schema_unused_indexes OK
|
||||
sys.session OK
|
||||
sys.session_ssl_status OK
|
||||
sys.statement_analysis OK
|
||||
sys.statements_with_errors_or_warnings OK
|
||||
sys.statements_with_full_table_scans OK
|
||||
sys.statements_with_runtimes_in_95th_percentile OK
|
||||
sys.statements_with_sorting OK
|
||||
sys.statements_with_temp_tables OK
|
||||
sys.user_summary OK
|
||||
sys.user_summary_by_file_io OK
|
||||
sys.user_summary_by_file_io_type OK
|
||||
sys.user_summary_by_stages OK
|
||||
sys.user_summary_by_statement_latency OK
|
||||
sys.user_summary_by_statement_type OK
|
||||
sys.version OK
|
||||
sys.wait_classes_global_by_avg_latency OK
|
||||
sys.wait_classes_global_by_latency OK
|
||||
sys.waits_by_host_by_latency OK
|
||||
sys.waits_by_user_by_latency OK
|
||||
sys.waits_global_by_latency OK
|
||||
sys.x$host_summary OK
|
||||
sys.x$host_summary_by_file_io OK
|
||||
sys.x$host_summary_by_file_io_type OK
|
||||
sys.x$host_summary_by_stages OK
|
||||
sys.x$host_summary_by_statement_latency OK
|
||||
sys.x$host_summary_by_statement_type OK
|
||||
sys.x$innodb_buffer_stats_by_schema OK
|
||||
sys.x$innodb_buffer_stats_by_table OK
|
||||
sys.x$innodb_lock_waits OK
|
||||
sys.x$io_by_thread_by_latency OK
|
||||
sys.x$io_global_by_file_by_bytes OK
|
||||
sys.x$io_global_by_file_by_latency OK
|
||||
sys.x$io_global_by_wait_by_bytes OK
|
||||
sys.x$io_global_by_wait_by_latency OK
|
||||
sys.x$latest_file_io OK
|
||||
sys.x$memory_by_host_by_current_bytes OK
|
||||
sys.x$memory_by_thread_by_current_bytes OK
|
||||
sys.x$memory_by_user_by_current_bytes OK
|
||||
sys.x$memory_global_by_current_bytes OK
|
||||
sys.x$memory_global_total OK
|
||||
sys.x$processlist OK
|
||||
sys.x$ps_digest_95th_percentile_by_avg_us OK
|
||||
sys.x$ps_digest_avg_latency_distribution OK
|
||||
sys.x$ps_schema_table_statistics_io OK
|
||||
sys.x$schema_flattened_keys OK
|
||||
sys.x$schema_index_statistics OK
|
||||
sys.x$schema_table_lock_waits OK
|
||||
sys.x$schema_table_statistics OK
|
||||
sys.x$schema_table_statistics_with_buffer OK
|
||||
sys.x$schema_tables_with_full_table_scans OK
|
||||
sys.x$session OK
|
||||
sys.x$statement_analysis OK
|
||||
sys.x$statements_with_errors_or_warnings OK
|
||||
sys.x$statements_with_full_table_scans OK
|
||||
sys.x$statements_with_runtimes_in_95th_percentile OK
|
||||
sys.x$statements_with_sorting OK
|
||||
sys.x$statements_with_temp_tables OK
|
||||
sys.x$user_summary OK
|
||||
sys.x$user_summary_by_file_io OK
|
||||
sys.x$user_summary_by_file_io_type OK
|
||||
sys.x$user_summary_by_stages OK
|
||||
sys.x$user_summary_by_statement_latency OK
|
||||
sys.x$user_summary_by_statement_type OK
|
||||
sys.x$wait_classes_global_by_avg_latency OK
|
||||
sys.x$wait_classes_global_by_latency OK
|
||||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
mtr.global_suppressions OK
|
||||
mtr.test_suppressions OK
|
||||
performance_schema
|
||||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
test.t1 OK
|
||||
test.t2 OK
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
select table_catalog, table_schema, table_name, table_type, engine, row_format, table_rows, data_length, table_comment from information_schema.tables where table_schema='test' and table_name='t1';
|
||||
table_catalog def
|
||||
table_schema test
|
||||
|
|
|
@ -34,7 +34,7 @@ select table_catalog, table_schema, table_name, table_type, engine, row_format,
|
|||
|
||||
--echo # upgrade from 10.1 - engines aren't enabled
|
||||
--replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB /
|
||||
exec $MYSQL_UPGRADE 2>&1;
|
||||
exec $MYSQL_UPGRADE --silent 2>&1;
|
||||
select table_catalog, table_schema, table_name, table_type, engine, row_format, table_rows, data_length, table_comment from information_schema.tables where table_schema='test' and table_name='t1';
|
||||
select table_catalog, table_schema, table_name, table_type, engine, row_format, table_rows, data_length, table_comment from information_schema.tables where table_schema='test' and table_name='t2';
|
||||
|
||||
|
@ -54,7 +54,7 @@ EOF
|
|||
|
||||
--echo # still upgrade from 10.1
|
||||
--replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB /
|
||||
exec $MYSQL_UPGRADE 2>&1;
|
||||
exec $MYSQL_UPGRADE --silent 2>&1;
|
||||
select table_catalog, table_schema, table_name, table_type, engine, row_format, table_rows, data_length, table_comment from information_schema.tables where table_schema='test' and table_name='t1';
|
||||
select table_catalog, table_schema, table_name, table_type, engine, row_format, table_rows, data_length, table_comment from information_schema.tables where table_schema='test' and table_name='t2';
|
||||
|
||||
|
@ -68,13 +68,14 @@ remove_file $datadir/mysql_upgrade_info;
|
|||
|
||||
--echo # upgrade from 10.0 - engines are enabled
|
||||
--replace_regex /\d\d\.\d*\.\d*[^ .\n]*/MariaDB /
|
||||
exec $MYSQL_UPGRADE 2>&1;
|
||||
exec $MYSQL_UPGRADE --silent 2>&1;
|
||||
select table_catalog, table_schema, table_name, table_type, engine, row_format, table_rows, data_length, table_comment from information_schema.tables where table_schema='test' and table_name='t1';
|
||||
select table_catalog, table_schema, table_name, table_type, engine, row_format, table_rows, data_length, table_comment from information_schema.tables where table_schema='test' and table_name='t2';
|
||||
|
||||
drop table t1, t2;
|
||||
|
||||
remove_file $datadir/mysql_upgrade_info;
|
||||
# This is needed as mysql_upgrade can load the plugins
|
||||
uninstall plugin blackhole;
|
||||
uninstall plugin archive;
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#
|
||||
# Bug#55672 mysql_upgrade dies with internal error
|
||||
#
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -32,8 +32,9 @@ mysql.time_zone_name OK
|
|||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.transaction_registry OK
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -135,9 +136,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -147,5 +147,6 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
|
|
|
@ -64,7 +64,7 @@ test.v2 check error Upgrade required. Please do "REPAIR VIEW `v2`" or dump/reloa
|
|||
check view v3 for upgrade;
|
||||
Table Op Msg_type Msg_text
|
||||
test.v3 check error Upgrade required. Please do "REPAIR VIEW `v3`" or dump/reload to fix it!
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -112,8 +112,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -219,9 +220,8 @@ test.v1 OK
|
|||
test.v1badcheck OK
|
||||
test.v2 OK
|
||||
test.v3 OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -233,7 +233,8 @@ sys.sys_config OK
|
|||
test
|
||||
test.kv OK
|
||||
test.t1 OK
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
show create view v1;
|
||||
View Create View character_set_client collation_connection
|
||||
|
@ -315,7 +316,7 @@ show create view v4;
|
|||
View Create View character_set_client collation_connection
|
||||
v4 CREATE ALGORITHM=TEMPTABLE DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v4` AS select `t1`.`a` AS `a` from `t1` latin1 latin1_swedish_ci
|
||||
MariaDB upgrade detected
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -364,8 +365,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views from mysql
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views from mysql
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -471,9 +473,8 @@ test.v1 OK
|
|||
test.v2 OK
|
||||
test.v3 OK
|
||||
test.v4 OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -485,7 +486,8 @@ sys.sys_config OK
|
|||
test
|
||||
test.kv OK
|
||||
test.t1 OK
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
flush tables;
|
||||
show create view v1;
|
||||
|
@ -542,7 +544,7 @@ rename table mysql.event to mysql.ev_bk;
|
|||
flush tables;
|
||||
The --upgrade-system-tables option was used, user tables won't be touched.
|
||||
MariaDB upgrade detected
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -591,8 +593,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views from mysql
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views from mysql
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -697,10 +700,10 @@ sys.x$waits_global_by_latency OK
|
|||
test.v1 OK
|
||||
test.v2 OK
|
||||
test.v3 OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names ... Skipped
|
||||
Phase 6/7: Checking and upgrading tables... Skipped
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 5/8: Fixing table and database names ... Skipped
|
||||
Phase 6/8: Checking and upgrading tables... Skipped
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
drop table mysql.event;
|
||||
rename table mysql.ev_bk to mysql.event;
|
||||
|
|
|
@ -84,7 +84,7 @@ GRANTEE TABLE_CATALOG PRIVILEGE_TYPE IS_GRANTABLE
|
|||
SELECT * FROM information_schema.TABLE_PRIVILEGES WHERE GRANTEE="'mariadb.sys'@'localhost'";
|
||||
GRANTEE TABLE_CATALOG TABLE_SCHEMA TABLE_NAME PRIVILEGE_TYPE IS_GRANTABLE
|
||||
# Run mysql_upgrade
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -133,9 +133,12 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
mysql.user OK
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user
|
||||
Warning : The user specified as a definer ('mariadb.sys'@'localhost') does not exist
|
||||
status : OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
sys.host_summary_by_file_io_type OK
|
||||
|
@ -236,9 +239,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -252,7 +254,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
# check new definitions mysql_upgrade
|
||||
SELECT count(*) FROM information_schema.VIEWS WHERE TABLE_CATALOG = 'def' and TABLE_SCHEMA = 'mysql' and TABLE_NAME='user' and DEFINER = 'root@localhost';
|
||||
|
|
|
@ -104,7 +104,7 @@ GRANTEE TABLE_CATALOG PRIVILEGE_TYPE IS_GRANTABLE
|
|||
SELECT * FROM information_schema.TABLE_PRIVILEGES WHERE GRANTEE="'mariadb.sys'@'localhost'";
|
||||
GRANTEE TABLE_CATALOG TABLE_SCHEMA TABLE_NAME PRIVILEGE_TYPE IS_GRANTABLE
|
||||
# Run mysql_upgrade
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -153,8 +153,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -256,9 +257,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -272,7 +272,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
# check new definitions mysql_upgrade
|
||||
SELECT count(*) FROM information_schema.VIEWS WHERE TABLE_CATALOG = 'def'
|
||||
|
@ -303,7 +304,7 @@ DROP USER 'superuser'@'localhost';
|
|||
DROP VIEW mysql.user;
|
||||
DROP PROCEDURE AddGeometryColumn;
|
||||
DROP PROCEDURE DropGeometryColumn;
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -352,8 +353,12 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user
|
||||
Warning : The user specified as a definer ('mariadb.sys'@'localhost') does not exist
|
||||
status : OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
sys.host_summary_by_file_io_type OK
|
||||
|
@ -454,9 +459,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -470,7 +474,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
delete from global_priv;
|
||||
delete from tables_priv;
|
||||
|
|
|
@ -88,7 +88,7 @@ GRANTEE TABLE_CATALOG PRIVILEGE_TYPE IS_GRANTABLE
|
|||
SELECT * FROM information_schema.TABLE_PRIVILEGES WHERE GRANTEE="'mariadb.sys'@'localhost'";
|
||||
GRANTEE TABLE_CATALOG TABLE_SCHEMA TABLE_NAME PRIVILEGE_TYPE IS_GRANTABLE
|
||||
# Run mysql_upgrade
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -137,8 +137,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -240,9 +241,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -256,7 +256,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
# check new definitions mysql_upgrade
|
||||
SELECT count(*) FROM information_schema.VIEWS WHERE TABLE_CATALOG = 'def'
|
||||
|
@ -279,7 +280,7 @@ count(*)
|
|||
# restore environment
|
||||
DROP USER 'superuser'@'localhost';
|
||||
DROP VIEW mysql.user;
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -328,8 +329,12 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user
|
||||
Warning : The user specified as a definer ('mariadb.sys'@'localhost') does not exist
|
||||
status : OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
sys.host_summary_by_file_io_type OK
|
||||
|
@ -430,9 +435,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -446,7 +450,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
delete from global_priv;
|
||||
delete from tables_priv;
|
||||
|
|
|
@ -34,7 +34,7 @@ count(*)
|
|||
#
|
||||
# Run mysql_upgrade
|
||||
#
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -83,8 +83,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -186,9 +187,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -198,7 +198,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
#
|
||||
# check new definers of Add/DropGeometryColumn
|
||||
|
|
|
@ -49,7 +49,7 @@ password_expired
|
|||
N
|
||||
drop user gigi@localhost;
|
||||
# Run mysql_upgrade
|
||||
Phase 1/7: Checking and upgrading mysql database
|
||||
Phase 1/8: Checking and upgrading mysql database
|
||||
Processing databases
|
||||
mysql
|
||||
mysql.column_stats OK
|
||||
|
@ -97,8 +97,9 @@ error : Corrupt
|
|||
mysql.transaction_registry
|
||||
Error : Unknown storage engine 'InnoDB'
|
||||
error : Corrupt
|
||||
Phase 2/7: Installing used storage engines... Skipped
|
||||
Phase 3/7: Fixing views
|
||||
Phase 2/8: Installing used storage engines... Skipped
|
||||
Phase 3/8: Running 'mysql_fix_privilege_tables'
|
||||
Phase 4/8: Fixing views
|
||||
mysql.user OK
|
||||
sys.host_summary OK
|
||||
sys.host_summary_by_file_io OK
|
||||
|
@ -200,9 +201,8 @@ sys.x$wait_classes_global_by_latency OK
|
|||
sys.x$waits_by_host_by_latency OK
|
||||
sys.x$waits_by_user_by_latency OK
|
||||
sys.x$waits_global_by_latency OK
|
||||
Phase 4/7: Running 'mysql_fix_privilege_tables'
|
||||
Phase 5/7: Fixing table and database names
|
||||
Phase 6/7: Checking and upgrading tables
|
||||
Phase 5/8: Fixing table and database names
|
||||
Phase 6/8: Checking and upgrading tables
|
||||
Processing databases
|
||||
information_schema
|
||||
mtr
|
||||
|
@ -212,7 +212,8 @@ performance_schema
|
|||
sys
|
||||
sys.sys_config OK
|
||||
test
|
||||
Phase 7/7: Running 'FLUSH PRIVILEGES'
|
||||
Phase 7/8: uninstalling plugins
|
||||
Phase 8/8: Running 'FLUSH PRIVILEGES'
|
||||
OK
|
||||
create user gigi@localhost;
|
||||
show create user gigi@localhost;
|
||||
|
|
|
@ -46,7 +46,6 @@ INSERT INTO tmp_user_sys (Host,User,Priv) VALUES ('localhost','mariadb.sys','{"a
|
|||
INSERT IGNORE INTO global_priv SELECT * FROM tmp_user_sys WHERE 0 <> @need_sys_user_creation;
|
||||
DROP TABLE tmp_user_sys;
|
||||
|
||||
|
||||
CREATE DEFINER='mariadb.sys'@'localhost' SQL SECURITY DEFINER VIEW IF NOT EXISTS user AS SELECT
|
||||
Host,
|
||||
User,
|
||||
|
|
|
@ -28,7 +28,6 @@ SELECT LOWER( REPLACE((SELECT REPLACE(@@hostname,'_','\_')),'%','\%') )INTO @cur
|
|||
SELECT '{"access":18446744073709551615}' INTO @all_privileges;
|
||||
SELECT '{"access":18446744073709551615,"plugin":"mysql_native_password","authentication_string":"invalid","auth_or":[{},{"plugin":"unix_socket"}]}' into @all_with_auth;
|
||||
|
||||
|
||||
-- Fill "global_priv" table with default users allowing root access
|
||||
-- from local machine if "global_priv" table didn't exist before
|
||||
CREATE TEMPORARY TABLE tmp_user_nopasswd LIKE global_priv;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
-- Copyright (C) 2003, 2013 Oracle and/or its affiliates.
|
||||
-- Copyright (C) 2010, 2022, MariaDB Corporation
|
||||
-- Copyright (C) 2010, 2023, MariaDB Corporation
|
||||
--
|
||||
-- This program is free software; you can redistribute it and/or modify
|
||||
-- it under the terms of the GNU General Public License as published by
|
||||
|
@ -15,7 +15,7 @@
|
|||
-- Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA
|
||||
|
||||
# This part converts any old privilege tables to privilege tables suitable
|
||||
# for current version of MySQL
|
||||
# for current version of MariaDB
|
||||
|
||||
# You can safely ignore all 'Duplicate column' and 'Unknown column' errors
|
||||
# because these just mean that your tables are already up to date.
|
||||
|
@ -28,6 +28,7 @@ set sql_mode='';
|
|||
set default_storage_engine=Aria;
|
||||
set enforce_storage_engine=NULL;
|
||||
set alter_algorithm='DEFAULT';
|
||||
set use_stat_tables='NEVER';
|
||||
|
||||
set @have_innodb= (select count(engine) from information_schema.engines where engine='INNODB' and support != 'NO');
|
||||
|
||||
|
|
|
@ -2301,7 +2301,7 @@ int view_repair(THD *thd, TABLE_LIST *view, HA_CHECK_OPT *check_opt)
|
|||
bool swap_alg= (check_opt->sql_flags & TT_FROM_MYSQL);
|
||||
bool wrong_checksum= view_checksum(thd, view) != HA_ADMIN_OK;
|
||||
int ret;
|
||||
if (wrong_checksum || swap_alg || (!view->mariadb_version))
|
||||
if (wrong_checksum || !view->mariadb_version)
|
||||
{
|
||||
ret= mariadb_fix_view(thd, view, wrong_checksum, swap_alg);
|
||||
DBUG_RETURN(ret);
|
||||
|
|
|
@ -8277,6 +8277,7 @@ mi_repair_type:
|
|||
|
||||
opt_view_repair_type:
|
||||
/* empty */ { }
|
||||
| FOR_SYM UPGRADE_SYM { Lex->check_opt.sql_flags|= TT_FOR_UPGRADE; }
|
||||
| FROM MYSQL_SYM { Lex->check_opt.sql_flags|= TT_FROM_MYSQL; }
|
||||
;
|
||||
|
||||
|
|
34
sql/table.cc
34
sql/table.cc
|
@ -6569,7 +6569,7 @@ void TABLE_LIST::register_want_access(privilege_t want_access)
|
|||
*/
|
||||
|
||||
#ifndef NO_EMBEDDED_ACCESS_CHECKS
|
||||
bool TABLE_LIST::prepare_view_security_context(THD *thd)
|
||||
bool TABLE_LIST::prepare_view_security_context(THD *thd, bool upgrade_check)
|
||||
{
|
||||
DBUG_ENTER("TABLE_LIST::prepare_view_security_context");
|
||||
DBUG_PRINT("enter", ("table: %s", alias.str));
|
||||
|
@ -6594,8 +6594,8 @@ bool TABLE_LIST::prepare_view_security_context(THD *thd)
|
|||
{
|
||||
if (thd->security_ctx->master_access & PRIV_REVEAL_MISSING_DEFINER)
|
||||
{
|
||||
my_error(ER_NO_SUCH_USER, MYF(0), definer.user.str, definer.host.str);
|
||||
|
||||
my_error(ER_NO_SUCH_USER, MYF(upgrade_check ? ME_WARNING: 0),
|
||||
definer.user.str, definer.host.str);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -6677,11 +6677,33 @@ bool TABLE_LIST::prepare_security(THD *thd)
|
|||
TABLE_LIST *tbl;
|
||||
DBUG_ENTER("TABLE_LIST::prepare_security");
|
||||
#ifndef NO_EMBEDDED_ACCESS_CHECKS
|
||||
/*
|
||||
Check if we are running REPAIR VIEW FOR UPGRADE
|
||||
In this case we are probably comming from mysql_upgrade and
|
||||
should not get an error for mysql.user table we just created.
|
||||
*/
|
||||
bool upgrade_check= (thd->lex->sql_command == SQLCOM_REPAIR &&
|
||||
(thd->lex->check_opt.sql_flags &
|
||||
(TT_FOR_UPGRADE | TT_FROM_MYSQL)) &&
|
||||
(thd->security_ctx->master_access &
|
||||
PRIV_REVEAL_MISSING_DEFINER));
|
||||
Security_context *save_security_ctx= thd->security_ctx;
|
||||
|
||||
DBUG_ASSERT(!prelocking_placeholder);
|
||||
if (prepare_view_security_context(thd))
|
||||
DBUG_RETURN(TRUE);
|
||||
if (prepare_view_security_context(thd, upgrade_check))
|
||||
{
|
||||
if (upgrade_check)
|
||||
{
|
||||
/* REPAIR needs SELECT_ACL */
|
||||
while ((tbl= tb++))
|
||||
{
|
||||
tbl->grant.privilege= SELECT_ACL;
|
||||
tbl->security_ctx= save_security_ctx;
|
||||
}
|
||||
DBUG_RETURN(FALSE);
|
||||
}
|
||||
DBUG_RETURN(TRUE); // Fatal
|
||||
}
|
||||
thd->security_ctx= find_view_security_context(thd);
|
||||
opt_trace_disable_if_no_security_context_access(thd);
|
||||
while ((tbl= tb++))
|
||||
|
@ -6707,7 +6729,7 @@ bool TABLE_LIST::prepare_security(THD *thd)
|
|||
#else
|
||||
while ((tbl= tb++))
|
||||
tbl->grant.privilege= ALL_KNOWN_ACL;
|
||||
#endif
|
||||
#endif /* NO_EMBEDDED_ACCESS_CHECKS */
|
||||
DBUG_RETURN(FALSE);
|
||||
}
|
||||
|
||||
|
|
|
@ -2763,7 +2763,7 @@ struct TABLE_LIST
|
|||
bool prepare_security(THD *thd);
|
||||
#ifndef NO_EMBEDDED_ACCESS_CHECKS
|
||||
Security_context *find_view_security_context(THD *thd);
|
||||
bool prepare_view_security_context(THD *thd);
|
||||
bool prepare_view_security_context(THD *thd, bool upgrade_check);
|
||||
#endif
|
||||
/*
|
||||
Cleanup for re-execution in a prepared statement or a stored
|
||||
|
|
Loading…
Add table
Reference in a new issue