Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MDEV-32462: mysql_upgrade -s still checks for non system tables #2790

Merged

Conversation

an3l
Copy link
Collaborator

@an3l an3l commented Oct 17, 2023

How can this PR be tested?

  1. Create configuration file
$ cat ~/.my105.cnf
[mariadb]
datadir=/tmp/10.5
lc_messages_dir=/home/anel/GitHub/mariadb/server/build/10.5/sql/share
general_log=1
general_log_file=patch.log
plugin_load_add=type_mysql_json.so
plugin_dir=/home/anel/GitHub/mariadb/server/build/10.5/plugin/type_mysql_json/
  1. Make sure library exists
$ ls /home/anel/GitHub/mariadb/server/build/10.5/plugin/type_mysql_json/
CMakeFiles  cmake_install.cmake  Makefile  type_mysql_json.so
  1. Start manually server from source
$ ./scripts/mariadb-install-db --srcdir=../../10.5 --defaults-file=~/.my105.cnf
$ ./sql/mysqld --defaults-file=~/.my105.cnf
  1. Copy MySQL 5.7 tables to test (user) and mysql (system) databases in MariaDB
#  from source
$ cp mysql-test/std_data/mysql_json/mysql_json_test.* /tmp/10.5/mysql/ && cp mysql-test/std_data/mysql_json/mysql_json_test.* /tmp/10.5/test/
  1. Validate results
MariaDB [mysql]> show tables from test;
+-----------------+
| Tables_in_test  |
+-----------------+
| mysql_json_test |
+-----------------+
1 row in set (0.001 sec)

MariaDB [mysql]> show tables from mysql like '%json%';
+--------------------------+
| Tables_in_mysql (%json%) |
+--------------------------+
| mysql_json_test          |
+--------------------------+
1 row in set (0.001 sec)
MariaDB [mysql]> select * from mysql.mysql_json_test;
ERROR 1707 (HY000): Table rebuild required. Please do "ALTER TABLE `mysql.mysql_json_test` FORCE" or dump/reload to fix it!
MariaDB [mysql]> select * from test.mysql_json_test;
ERROR 1707 (HY000): Table rebuild required. Please do "ALTER TABLE `test.mysql_json_test` FORCE" or dump/reload to fix it!
  1. Execute mariadb_upgrade --force

mariadb_upgrade --force

$ sudo ./client/mariadb-upgrade -s --socket=/tmp/mysql.sock --port=3306 --verbose --verbose --verbose --force
Looking for 'mariadb' as: ./client/mariadb
Looking for 'mariadb-check' as: ./client/mariadb-check
The --upgrade-system-tables option was used, user tables won't be touched.
Phase 1/7: Checking and upgrading mysql database
Running 'mariadb-check' with connection arguments: --port='3305' --socket='/run/mysqld/mysqld.sock' --socket='/tmp/mysql.sock' --port='3306' 
# Connecting to localhost...
# Disconnecting from localhost...
Processing databases
mysql
CHECK TABLE `column_stats`  FOR UPGRADE
mysql.column_stats                                 OK
CHECK TABLE `columns_priv`  FOR UPGRADE
mysql.columns_priv                                 OK
CHECK TABLE `db`  FOR UPGRADE
mysql.db                                           OK
CHECK TABLE `event`  FOR UPGRADE
mysql.event                                        OK
CHECK TABLE `func`  FOR UPGRADE
mysql.func                                         OK
CHECK TABLE `global_priv`  FOR UPGRADE
mysql.global_priv                                  OK
CHECK TABLE `gtid_slave_pos`  FOR UPGRADE
mysql.gtid_slave_pos                               OK
CHECK TABLE `help_category`  FOR UPGRADE
mysql.help_category                                OK
CHECK TABLE `help_keyword`  FOR UPGRADE
mysql.help_keyword                                 OK
CHECK TABLE `help_relation`  FOR UPGRADE
mysql.help_relation                                OK
CHECK TABLE `help_topic`  FOR UPGRADE
mysql.help_topic                                   OK
CHECK TABLE `index_stats`  FOR UPGRADE
mysql.index_stats                                  OK
CHECK TABLE `innodb_index_stats`  FOR UPGRADE
mysql.innodb_index_stats                           OK
CHECK TABLE `innodb_table_stats`  FOR UPGRADE
mysql.innodb_table_stats                           OK
CHECK TABLE `mysql_json_test`  FOR UPGRADE
mysql.mysql_json_test                              Needs upgrade
CHECK TABLE `plugin`  FOR UPGRADE
mysql.plugin                                       OK
CHECK TABLE `proc`  FOR UPGRADE
mysql.proc                                         OK
CHECK TABLE `procs_priv`  FOR UPGRADE
mysql.procs_priv                                   OK
CHECK TABLE `proxies_priv`  FOR UPGRADE
mysql.proxies_priv                                 OK
CHECK TABLE `roles_mapping`  FOR UPGRADE
mysql.roles_mapping                                OK
CHECK TABLE `servers`  FOR UPGRADE
mysql.servers                                      OK
CHECK TABLE `table_stats`  FOR UPGRADE
mysql.table_stats                                  OK
CHECK TABLE `tables_priv`  FOR UPGRADE
mysql.tables_priv                                  OK
CHECK TABLE `time_zone`  FOR UPGRADE
mysql.time_zone                                    OK
CHECK TABLE `time_zone_leap_second`  FOR UPGRADE
mysql.time_zone_leap_second                        OK
CHECK TABLE `time_zone_name`  FOR UPGRADE
mysql.time_zone_name                               OK
CHECK TABLE `time_zone_transition`  FOR UPGRADE
mysql.time_zone_transition                         OK
CHECK TABLE `time_zone_transition_type`  FOR UPGRADE
mysql.time_zone_transition_type                    OK
CHECK TABLE `transaction_registry`  FOR UPGRADE
mysql.transaction_registry                         OK

Repairing tables
REPAIR NO_WRITE_TO_BINLOG TABLE mysql.mysql_json_test
mysql.mysql_json_test 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'
OK
Running 'mariadb-check' with connection arguments: --port='3305' --socket='/run/mysqld/mysqld.sock' --socket='/tmp/mysql.sock' --port='3306'

  1. Check general_log_file (make sure proper query is executed only on mysql)

General log file

 17 Connect	root@localhost on mysql using Socket
		    17 Query	SET SQL_LOG_BIN=0, WSREP_ON=OFF
		    17 Query	SELECT table_comment FROM information_schema.tables WHERE table_schema='mysql' and table_comment LIKE 'Unknown data type: %'

Basing the PR against the correct MariaDB version

  • This is a new feature and the PR is based against the latest MariaDB development branch.
  • This is a bug fix and the PR is based against the earliest maintained branch in which the bug can be reproduced.

PR quality check

  • I checked the CODING_STANDARDS.md file and my PR conforms to this where appropriate.
  • For any trivial modifications to the PR, I am ok with the reviewer making the changes themselves.

@an3l an3l added the MariaDB Foundation Pull requests created by MariaDB Foundation label Oct 17, 2023
@an3l an3l force-pushed the bb-10.5-anel-MDEV-32462-mariadb_upgrade_system_tables branch 2 times, most recently from f50d5ff to c1bd9ab Compare October 17, 2023 14:45
# Let's now load plugin first
-- source include/have_utf8.inc
# Don't load plugin in order to get ER_UNKNOWN_DATA_TYPE instead of ER_TABLE_NEEDS_REBUILD
# -- source include/have_type_mysql_json.inc
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is this commented?

Copy link
Collaborator Author

@an3l an3l Oct 18, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In order to control the output for mariadb-dump and error messages, it will not harm to stay or being removed or included.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it looks like its ensuring that the plugin exists, so I'd say include it, at the top of the file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please no commented out code. Either removed, or not commented. Looks like it should just be removed.

--copy_file std_data/mysql_json/mysql_json_test.frm $MYSQLD_DATADIR/mysql/mysql_json_test.frm
--copy_file std_data/mysql_json/mysql_json_test.MYI $MYSQLD_DATADIR/mysql/mysql_json_test.MYI
--copy_file std_data/mysql_json/mysql_json_test.MYD $MYSQLD_DATADIR/mysql/mysql_json_test.MYD
--copy_file std_data/mysql_json/mysql_json_test.frm $MYSQLD_DATADIR/test/mysql_json_test.frm
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you leave a small clarifying comment on why the test.mysql_json_test table is being placed there?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is comment in the --echo above.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mysql.mysql_json_test is examined, test.mysql_json_test doesn't appear to be anything done with it.

Copy link
Member

@cvicentiu cvicentiu Oct 18, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Concur with @grooverdan.

Every line in a test file must be purposeful.
You don't actually check that test.mysql_json_test table is "upgraded" or not.

To make the test more readable:

  1. Don't use "use mysql".
  2. Run show create table test.mysql_json_test;
  3. Run show create table mysql.mysql_json_test;
  4. Do steps 2 and 3 both before and after the upgrade execution.

--remove_file $MYSQLD_DATADIR/mysql_upgrade_info

select * from mysql.plugin;
select * from mysql.general_log where argument like "%SELECT table_comment FROM information_schema.tables%";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

* from general_log includes timestamp which is why bb fails. command_type, argument would make the result repeatable.

@@ -0,0 +1,2 @@
--general_log
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rather than set these as opts, I think you can set these around the --exec $MYSQL_UPGRADE. And reset to previous value directly afterwards.

When doing so I think truncate mysql.general_log will be required on cleanup.

This might prevent the warnings on shutdown:

2023-10-17 15:06:33 0 [Warning] Although a general log file was specified, log tables are used. To enable logging to files use the --log-output option.
2023-10-17 15:06:33 0 [Warning] Although a slow query log file was specified, log tables are used. To enable logging to files use the --log-output=file option.

@@ -1155,6 +1155,9 @@ static int install_used_plugin_data_types(void)
DYNAMIC_STRING ds_result;
const char *query = "SELECT table_comment FROM information_schema.tables"
" WHERE table_comment LIKE 'Unknown data type: %'";
if (opt_systables_only)
query= "SELECT table_comment FROM information_schema.tables"
" WHERE table_schema='mysql' and table_comment LIKE 'Unknown data type: %'";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Eh, not a big fan of repeating the query.

Suggested:

-  const char *query = "SELECT table_comment FROM information_schema.tables"
-                      " WHERE table_comment LIKE 'Unknown data type: %'";
-  if (opt_systables_only)
-    query= "SELECT table_comment FROM information_schema.tables"
-           " WHERE table_schema='mysql' and table_comment LIKE 'Unknown data type: %'";
+  char query[1024];
+  const char *extra_mysql_db_filter =
+      opt_systables_only ? "AND table_schema = 'mysql' " : "";
+  snprintf(query, sizeof(query),
+           "SELECT table_comment FROM information_schema.tables"
+           " WHERE table_comment LIKE 'Unknown data type: %%' %s",
+           extra_mysql_db_filter);
+

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMHO it is readable and performance wise better to use string as in patch.


# Let's now load plugin first
-- source include/have_utf8.inc
# Don't load plugin in order to get ER_UNKNOWN_DATA_TYPE instead of ER_TABLE_NEEDS_REBUILD
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To prevent such a requirement:

--error ER_UNKNOWN_DATA_TYPE,ER_TABLE_NEEDS_REBUILD

This would also make the select from mysql.plugin unreliable, but I'm not sure that's a significant part of this test.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, not needed select will remove.

@an3l an3l force-pushed the bb-10.5-anel-MDEV-32462-mariadb_upgrade_system_tables branch from c1bd9ab to aa3310d Compare October 18, 2023 07:11
@grooverdan
Copy link
Member

Note ps failure:

CURRENT_TEST: main.mysql_json_mysql_upgrade_system_tables
--- /home/buildbot/amd64-ubuntu-2204-debug-ps/build/mysql-test/main/mysql_json_mysql_upgrade_system_tables.result	2023-10-18 07:19:30.000000000 +0000
+++ /home/buildbot/amd64-ubuntu-2204-debug-ps/build/mysql-test/main/mysql_json_mysql_upgrade_system_tables.reject	2023-10-18 07:31:42.082609182 +0000
@@ -81,7 +81,8 @@
 select command_type, argument from mysql.general_log where argument like "%SELECT table_comment FROM information_schema.tables%";
 command_type	argument
 Query	SELECT table_comment FROM information_schema.tables WHERE table_schema='mysql' and table_comment LIKE 'Unknown data type: %'
-Query	select command_type, argument from mysql.general_log where argument like "%SELECT table_comment FROM information_schema.tables%"
+Prepare	select command_type, argument from mysql.general_log where argument like "%SELECT table_comment FROM information_schema.tables%"
+Execute	select command_type, argument from mysql.general_log where argument like "%SELECT table_comment FROM information_schema.tables%"
 show create table mysql_json_test;
 ERROR HY000: Unknown data type: 'MYSQL_JSON'
 drop table mysql.mysql_json_test;
mysqltest: Result length mismatch

enable general log into tables only for exec MYSQL_UPGRADE might correct this.

@an3l an3l force-pushed the bb-10.5-anel-MDEV-32462-mariadb_upgrade_system_tables branch from aa3310d to d2e9dc7 Compare October 18, 2023 10:02
@@ -1155,6 +1155,9 @@ static int install_used_plugin_data_types(void)
DYNAMIC_STRING ds_result;
const char *query = "SELECT table_comment FROM information_schema.tables"
" WHERE table_comment LIKE 'Unknown data type: %'";
if (opt_systables_only)
query= "SELECT table_comment FROM information_schema.tables"
" WHERE table_schema='mysql' and table_comment LIKE 'Unknown data type: %'";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Eh, not a big fan of repeating the query.

Suggested:

-  const char *query = "SELECT table_comment FROM information_schema.tables"
-                      " WHERE table_comment LIKE 'Unknown data type: %'";
-  if (opt_systables_only)
-    query= "SELECT table_comment FROM information_schema.tables"
-           " WHERE table_schema='mysql' and table_comment LIKE 'Unknown data type: %'";
+  char query[1024];
+  const char *extra_mysql_db_filter =
+      opt_systables_only ? "AND table_schema = 'mysql' " : "";
+  snprintf(query, sizeof(query),
+           "SELECT table_comment FROM information_schema.tables"
+           " WHERE table_comment LIKE 'Unknown data type: %%' %s",
+           extra_mysql_db_filter);
+

@@ -0,0 +1,92 @@
#
Copy link
Member

@cvicentiu cvicentiu Oct 18, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a big fan of the test name. Can we have two commits please of the form:

  1. Rename this test as mysql_upgrade_mysql_json_upgrade_system_tables (in this commit)
  2. Rename all mysql_json_mysql_upgrade_xxx tests to mysql_upgrade_mysql_json_xxx (in a separate commit)

This should make things consistent with the other test names in main suite related to mysql_upgrade.

# Let's now load plugin first
-- source include/have_utf8.inc
# Don't load plugin in order to get ER_UNKNOWN_DATA_TYPE instead of ER_TABLE_NEEDS_REBUILD
# -- source include/have_type_mysql_json.inc
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please no commented out code. Either removed, or not commented. Looks like it should just be removed.

--copy_file std_data/mysql_json/mysql_json_test.frm $MYSQLD_DATADIR/mysql/mysql_json_test.frm
--copy_file std_data/mysql_json/mysql_json_test.MYI $MYSQLD_DATADIR/mysql/mysql_json_test.MYI
--copy_file std_data/mysql_json/mysql_json_test.MYD $MYSQLD_DATADIR/mysql/mysql_json_test.MYD
--copy_file std_data/mysql_json/mysql_json_test.frm $MYSQLD_DATADIR/test/mysql_json_test.frm
Copy link
Member

@cvicentiu cvicentiu Oct 18, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Concur with @grooverdan.

Every line in a test file must be purposeful.
You don't actually check that test.mysql_json_test table is "upgraded" or not.

To make the test more readable:

  1. Don't use "use mysql".
  2. Run show create table test.mysql_json_test;
  3. Run show create table mysql.mysql_json_test;
  4. Do steps 2 and 3 both before and after the upgrade execution.


# Let's now load plugin first
-- source include/have_utf8.inc
--source include/not_embedded.inc
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please be consistent, either no spaces after -- or spaces after --. I suggest no space after -- anywhere in the file.

@an3l an3l added this to the 10.5 milestone Oct 19, 2023
an3l added a commit to an3l/server that referenced this pull request Oct 19, 2023
- Prevent opening of any user tables in case `upgrade-system-table`
option is used.
- Still there may be uninstalled data types in `mysql` system table so
allow it to perform.
- Closes PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
an3l added a commit to an3l/server that referenced this pull request Oct 19, 2023
- Rename files as requested by Vicentiu:
```
 mysql_json_mysql_upgrade.test                    -> mysql_upgrade_mysql_json.test
 mysql_json_mysql_upgrade_with_plugin_loaded.test -> mysql_upgrade_mysql_json_with_plugin_loaded.test
 mysql_json_mysql_upgrade_system_tables.test      -> mysql_upgrade_mysql_json_system_tables.test
```
- Related to PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
@an3l an3l force-pushed the bb-10.5-anel-MDEV-32462-mariadb_upgrade_system_tables branch from d2e9dc7 to 9ca9e20 Compare October 19, 2023 07:24
@an3l
Copy link
Collaborator Author

an3l commented Oct 19, 2023

@cvicentiu , @grooverdan thanks, updated according to the review.


# User table is not upgraded in `mysql\test` DB, so we cannot see it.
--error ER_UNKNOWN_DATA_TYPE
show create table mysql.mysql_json_test;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not good then. I thought that we'd be upgrading mysql database tables after loading the MYSQL_JSON plugin.

If mysql_upgrade is now run with -s parameter, it leads to this current logic that makes no sense:

  1. Try to check all tables in mysql database and upgrade them. This will fail for any tables with MYSQL_JSON datatype.
  2. Check if we need to load MYSQL_JSON plugin for any tables in mysql database.
  3. Don't do anything else.

Observing this, let's just skip loading MYSQL_JSON for mysql database, like you @an3l proposed initially,

static int install_used_plugin_data_types(void)
{
....
if (opt_systables_only)
  return 0;
....
}

There's no point in actually going through all that logic, loading the plugin, unloading it, to actually not do anything in the end.

To make sure, I checked all MySQL's tables in 5.7:

mysql> select distinct(data_type) from information_schema.columns where table_schema='mysql' order by 1;
+------------+
| data_type  |
+------------+
| bigint     |
| blob       |
| char       |
| datetime   |
| enum       |
| float      |
| int        |
| longblob   |
| mediumblob |
| mediumtext |
| set        |
| smallint   |
| text       |
| time       |
| timestamp  |
| tinyint    |
| varchar    |
+------------+

So we should be safe ignoring systables in this case.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated.

an3l added a commit to an3l/server that referenced this pull request Oct 19, 2023
- Prevent opening of any user tables in case `upgrade-system-table`
option is used.
- Still there may be uninstalled data types in `mysql` system table so
allow it to perform.
- Closes PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
an3l added a commit to an3l/server that referenced this pull request Oct 19, 2023
- Rename files as requested by Vicentiu:
```
 mysql_json_mysql_upgrade.test                    -> mysql_upgrade_mysql_json.test
 mysql_json_mysql_upgrade_with_plugin_loaded.test -> mysql_upgrade_mysql_json_with_plugin_loaded.test
 mysql_json_mysql_upgrade_system_tables.test      -> mysql_upgrade_mysql_json_system_tables.test
```
- Related to PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
an3l added a commit to an3l/server that referenced this pull request Oct 19, 2023
- Prevent opening of any user tables in case `upgrade-system-table`
option is used.
- Still there may be uninstalled data types in `mysql` system table so
allow it to perform.
- Closes PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
an3l added a commit to an3l/server that referenced this pull request Oct 19, 2023
- Rename files as requested by Vicentiu:
```
 mysql_json_mysql_upgrade.test                    -> mysql_upgrade_mysql_json.test
 mysql_json_mysql_upgrade_with_plugin_loaded.test -> mysql_upgrade_mysql_json_with_plugin_loaded.test
 mysql_json_mysql_upgrade_system_tables.test      -> mysql_upgrade_mysql_json_system_tables.test
```
- Related to PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
@an3l an3l force-pushed the bb-10.5-anel-MDEV-32462-mariadb_upgrade_system_tables branch from 9ca9e20 to 61b158f Compare October 19, 2023 11:13
an3l added a commit to an3l/server that referenced this pull request Oct 27, 2023
- Prevent opening of any user tables in case `upgrade-system-table`
option is used.
- Still there may be uninstalled data types in `mysql` system table so
allow it to perform.
- Closes PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
an3l added a commit to an3l/server that referenced this pull request Oct 27, 2023
- Rename files as requested by Vicentiu:
```
 mysql_json_mysql_upgrade.test                    -> mysql_upgrade_mysql_json.test
 mysql_json_mysql_upgrade_with_plugin_loaded.test -> mysql_upgrade_mysql_json_with_plugin_loaded.test
 mysql_json_mysql_upgrade_system_tables.test      -> mysql_upgrade_mysql_json_system_tables.test
```
- Related to PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
Copy link
Member

@cvicentiu cvicentiu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok to push. Please check BB if we missed any corner case.

an3l added a commit that referenced this pull request Oct 30, 2023
- Prevent opening of any user tables in case `upgrade-system-table`
option is used.
- Still there may be uninstalled data types in `mysql` system table so
allow it to perform.
- Closes PR #2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
an3l added a commit that referenced this pull request Oct 30, 2023
- Rename files as requested by Vicentiu:
```
 mysql_json_mysql_upgrade.test                    -> mysql_upgrade_mysql_json.test
 mysql_json_mysql_upgrade_with_plugin_loaded.test -> mysql_upgrade_mysql_json_with_plugin_loaded.test
 mysql_json_mysql_upgrade_system_tables.test      -> mysql_upgrade_mysql_json_system_tables.test
```
- Related to PR #2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
- Prevent opening of any user tables in case `upgrade-system-table`
option is used.
- Still there may be uninstalled data types in `mysql` system table so
allow it to perform.
- Closes PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
- Rename files as requested by Vicentiu:
```
 mysql_json_mysql_upgrade.test                    -> mysql_upgrade_mysql_json.test
 mysql_json_mysql_upgrade_with_plugin_loaded.test -> mysql_upgrade_mysql_json_with_plugin_loaded.test
 mysql_json_mysql_upgrade_system_tables.test      -> mysql_upgrade_mysql_json_system_tables.test
```
- Related to PR MariaDB#2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
@an3l an3l force-pushed the bb-10.5-anel-MDEV-32462-mariadb_upgrade_system_tables branch from 61b158f to 6d12330 Compare October 30, 2023 17:45
@an3l an3l merged commit b06ac9a into MariaDB:10.5 Oct 30, 2023
12 of 13 checks passed
an3l added a commit that referenced this pull request Oct 30, 2023
- Prevent opening of any user tables in case `upgrade-system-table`
option is used.
- Still there may be uninstalled data types in `mysql` system table so
allow it to perform.
- Closes PR #2790
- Reviewer: <daniel@mariadb.org>, <vicentiu@mariadb.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
MariaDB Foundation Pull requests created by MariaDB Foundation
3 participants