diff --git a/debian/additions/mariadb-report b/debian/additions/mariadb-report index 5c9761e0710..ff73bb0e17e 100755 --- a/debian/additions/mariadb-report +++ b/debian/additions/mariadb-report @@ -239,26 +239,56 @@ sub get_user_mycnf sub connect_to_MySQL { - print "connect_to_MySQL\n" if $op{debug}; + print "connect_to_MySQL\n" if $op{debug}; - my $dsn; + if(my @driverList = grep {/mariadb|mysql/i} DBI->available_drivers()) { + my $dsn; + my $driver = undef; - if($mycnf{'socket'} && -S $mycnf{'socket'}) - { - $dsn = "DBI:MariaDB:mariadb_socket=$mycnf{socket}"; - } - elsif($mycnf{'host'}) - { - $dsn = "DBI:MariaDB:host=$mycnf{host}" . ($mycnf{port} ? ";port=$mycnf{port}" : ""); - } - else - { - $dsn = "DBI:MariaDB:host=localhost"; - } + if(grep {/mariadb/i} @driverList) + { + $driver = "DBI:MariaDB"; + } + elsif(grep {/mysql/i} @driverList) + { + $driver = "DBI:mysql"; + } - print "connect_to_MySQL: DBI DSN: $dsn\n" if $op{debug}; + if($mycnf{'socket'} && -S $mycnf{'socket'}) + { + if(grep {/mariadb/i} @driverList) + { + $dsn = $driver . ":mariadb_socket=$mycnf{socket}"; + } + elsif(grep {/mysql/i} @driverList) + { + $dsn = $driver . ":mysql_socket=$mycnf{socket}"; + } + } + elsif($mycnf{'host'}) + { + $dsn = $driver . ":host=$mycnf{host}" . ($mycnf{port} ? ";port=$mycnf{port}" : ""); + } + else + { + $dsn = $driver . ":host=localhost"; + } - $dbh = DBI->connect($dsn, $mycnf{'user'}, $mycnf{'pass'}) or die; + print "connect_to_MySQL: DBI DSN: " . $dsn . "\n" if $op{debug}; + + $dbh = DBI->connect($dsn, $mycnf{'user'}, $mycnf{'pass'}) or die; + } + else + { + print STDERR "Install Perl 5.x driver: DBD:mysql or DBD:MariaDB\n"; + print STDERR "currently installed Perl DBD drivers:\n"; + foreach my $driver (DBI->available_drivers()) + { + print STDERR " * " . $driver . "\n"; + } + print STDERR "\n"; + die("Exit as no MariaDB DBI driver found!\n"); + } } sub collect_reports diff --git a/debian/mariadb-test-data.lintian-overrides b/debian/mariadb-test-data.lintian-overrides index 4ff05a3be2a..630e9fcab1e 100644 --- a/debian/mariadb-test-data.lintian-overrides +++ b/debian/mariadb-test-data.lintian-overrides @@ -1,3 +1,25 @@ # These should be moved, see https://jira.mariadb.org/browse/MDEV-21654 arch-dependent-file-in-usr-share usr/share/mysql/mysql-test/suite/plugins/pam/pam_mariadb_mtr.so arch-independent-package-contains-binary-or-object usr/share/mysql/mysql-test/suite/plugins/pam/pam_mariadb_mtr.so +# Intentional for test files +national-encoding usr/share/mysql/mysql-test/* +# Extra test documentation files that really need to be kept in context in test directory +package-contains-documentation-outside-usr-share-doc usr/share/mysql/mysql-test/* +# Intentional directory structure +repeated-path-segment auth_gssapi usr/share/mysql/mysql-test/plugin/auth_gssapi/auth_gssapi/ +repeated-path-segment connect usr/share/mysql/mysql-test/plugin/connect/connect/ +repeated-path-segment disks usr/share/mysql/mysql-test/plugin/disks/disks/ +repeated-path-segment func_test usr/share/mysql/mysql-test/plugin/func_test/func_test/ +repeated-path-segment metadata_lock_info usr/share/mysql/mysql-test/plugin/metadata_lock_info/metadata_lock_info/ +repeated-path-segment mroonga usr/share/mysql/mysql-test/plugin/mroonga/mroonga/ +repeated-path-segment mroonga usr/share/mysql/mysql-test/plugin/mroonga/mroonga/include/mroonga/ +repeated-path-segment oqgraph usr/share/mysql/mysql-test/plugin/oqgraph/oqgraph/ +repeated-path-segment query_response_time usr/share/mysql/mysql-test/plugin/query_response_time/query_response_time/ +repeated-path-segment rocksdb usr/share/mysql/mysql-test/plugin/rocksdb/rocksdb/ +repeated-path-segment sequence usr/share/mysql/mysql-test/plugin/sequence/sequence/ +repeated-path-segment sphinx usr/share/mysql/mysql-test/plugin/sphinx/sphinx/ +repeated-path-segment spider usr/share/mysql/mysql-test/plugin/spider/spider/ +repeated-path-segment type_inet usr/share/mysql/mysql-test/plugin/type_inet/type_inet/ +repeated-path-segment type_test usr/share/mysql/mysql-test/plugin/type_test/type_test/ +repeated-path-segment user_variables usr/share/mysql/mysql-test/plugin/user_variables/user_variables/ +repeated-path-segment wsrep_info usr/share/mysql/mysql-test/plugin/wsrep_info/wsrep_info/ diff --git a/man/mysql-stress-test.pl.1 b/man/mysql-stress-test.pl.1 index d69f6123488..a55c5a652a3 100644 --- a/man/mysql-stress-test.pl.1 +++ b/man/mysql-stress-test.pl.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL\-STRESS\-TE" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMYSQL\-STRESS\-TE" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql-test-run.pl.1 b/man/mysql-test-run.pl.1 index b13727c3298..8b2fb5f3a21 100644 --- a/man/mysql-test-run.pl.1 +++ b/man/mysql-test-run.pl.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL\-TEST\-RUN\" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMYSQL\-TEST\-RUN\" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql.1 b/man/mysql.1 index 4bc35938f6c..8e36acdd3be 100644 --- a/man/mysql.1 +++ b/man/mysql.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql.server.1 b/man/mysql.server.1 index 4b99aadb0b3..4a5c24deda2 100644 --- a/man/mysql.server.1 +++ b/man/mysql.server.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL\&.SERVER\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMYSQL\&.SERVER\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_client_test.1 b/man/mysql_client_test.1 index 70ce1f720b7..484cd566dee 100644 --- a/man/mysql_client_test.1 +++ b/man/mysql_client_test.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_CLIENT_TEST" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-CLIENT-TEST" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_config.1 b/man/mysql_config.1 index 90b09cb5d4b..5dbe2c2140c 100644 --- a/man/mysql_config.1 +++ b/man/mysql_config.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_CONFIG\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMYSQL_CONFIG\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_convert_table_format.1 b/man/mysql_convert_table_format.1 index 2d31bdcb0fb..de2d5478fa3 100644 --- a/man/mysql_convert_table_format.1 +++ b/man/mysql_convert_table_format.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_CONVERT_TAB" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-CONVERT-TAB" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_find_rows.1 b/man/mysql_find_rows.1 index b69322e4abb..1a968aae5af 100644 --- a/man/mysql_find_rows.1 +++ b/man/mysql_find_rows.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_FIND_ROWS\F" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-FIND-ROWS\F" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_fix_extensions.1 b/man/mysql_fix_extensions.1 index bad341ab694..9321a6d6fbe 100644 --- a/man/mysql_fix_extensions.1 +++ b/man/mysql_fix_extensions.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_FIX_EXTENSI" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-FIX-EXTENSI" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_install_db.1 b/man/mysql_install_db.1 index 237efaef9df..3ce9d5544d4 100644 --- a/man/mysql_install_db.1 +++ b/man/mysql_install_db.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_INSTALL_DB\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-INSTALL-DB\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_ldb.1 b/man/mysql_ldb.1 index 8595ab5e319..24302e13139 100644 --- a/man/mysql_ldb.1 +++ b/man/mysql_ldb.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_LDB\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-LDB\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_plugin.1 b/man/mysql_plugin.1 index 6e002f2021d..3009fc1361f 100644 --- a/man/mysql_plugin.1 +++ b/man/mysql_plugin.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_PLUGIN\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-PLUGIN\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- diff --git a/man/mysql_secure_installation.1 b/man/mysql_secure_installation.1 index ca7f52cd30e..88cd2a8944c 100644 --- a/man/mysql_secure_installation.1 +++ b/man/mysql_secure_installation.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_SECURE_INST" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-SECURE-INST" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_setpermission.1 b/man/mysql_setpermission.1 index 4ab0ba5ff1e..33f8c58cb0e 100644 --- a/man/mysql_setpermission.1 +++ b/man/mysql_setpermission.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_SETPERMISSI" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-SETPERMISSI" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_tzinfo_to_sql.1 b/man/mysql_tzinfo_to_sql.1 index 8cc8a6b9fa4..90e91431edb 100644 --- a/man/mysql_tzinfo_to_sql.1 +++ b/man/mysql_tzinfo_to_sql.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_TZINFO_TO_S" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-TZINFO-TO-S" "1" "22 April 2022" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_upgrade.1 b/man/mysql_upgrade.1 index d47c3c70b85..465c905ae6e 100644 --- a/man/mysql_upgrade.1 +++ b/man/mysql_upgrade.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_UPGRADE\FR" "1" "20 July 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-UPGRADE\FR" "1" "20 July 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysql_waitpid.1 b/man/mysql_waitpid.1 index 330687ea3e4..9a2dcb72acb 100644 --- a/man/mysql_waitpid.1 +++ b/man/mysql_waitpid.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQL_WAITPID\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-WAITPID\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqlaccess.1 b/man/mysqlaccess.1 index e14de4791e2..6c2ff84c777 100644 --- a/man/mysqlaccess.1 +++ b/man/mysqlaccess.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLACCESS\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-ACCESS\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqladmin.1 b/man/mysqladmin.1 index 2b6fab12f0e..ae2fbf9ba8e 100644 --- a/man/mysqladmin.1 +++ b/man/mysqladmin.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLADMIN\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-ADMIN\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqlbinlog.1 b/man/mysqlbinlog.1 index 7ad8c714490..27232028de7 100644 --- a/man/mysqlbinlog.1 +++ b/man/mysqlbinlog.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLBINLOG\FR" "1" "14 April 2021" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-BINLOG\FR" "1" "14 April 2021" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqlcheck.1 b/man/mysqlcheck.1 index b8f102a27a4..b273dee9312 100644 --- a/man/mysqlcheck.1 +++ b/man/mysqlcheck.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLCHECK\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-CHECK\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqld.8 b/man/mysqld.8 index ffa746edd64..8857c5961c4 100644 --- a/man/mysqld.8 +++ b/man/mysqld.8 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLD\FR" "8" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADBD\FR" "8" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqld_multi.1 b/man/mysqld_multi.1 index d4e5e08efa9..3c5bca5a07b 100644 --- a/man/mysqld_multi.1 +++ b/man/mysqld_multi.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLD_MULTI\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-MULTI\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqld_safe.1 b/man/mysqld_safe.1 index ff3b8356095..36d6eb82faf 100644 --- a/man/mysqld_safe.1 +++ b/man/mysqld_safe.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLD_SAFE\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-SAFE\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqld_safe_helper.1 b/man/mysqld_safe_helper.1 index f8fc0fc4668..93bea715a34 100644 --- a/man/mysqld_safe_helper.1 +++ b/man/mysqld_safe_helper.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLD_SAFE_HELPER\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-SAFE-HELPER\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqldump.1 b/man/mysqldump.1 index ad4b167c7b8..8dcce60b0d9 100644 --- a/man/mysqldump.1 +++ b/man/mysqldump.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLDUMP\FR" "1" "24 October 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-DUMP\FR" "1" "24 October 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqldumpslow.1 b/man/mysqldumpslow.1 index d5da746a293..f93bcfac979 100644 --- a/man/mysqldumpslow.1 +++ b/man/mysqldumpslow.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLDUMPSLOW\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-DUMPSLOW\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqlhotcopy.1 b/man/mysqlhotcopy.1 index 462e2f97062..eb8d8caa39c 100644 --- a/man/mysqlhotcopy.1 +++ b/man/mysqlhotcopy.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLHOTCOPY\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-HOTCOPY\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqlimport.1 b/man/mysqlimport.1 index b7999166d32..5c2a03df843 100644 --- a/man/mysqlimport.1 +++ b/man/mysqlimport.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLIMPORT\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-IMPORT\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqlshow.1 b/man/mysqlshow.1 index f20ac9fed63..15a4a2fa4d3 100644 --- a/man/mysqlshow.1 +++ b/man/mysqlshow.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLSHOW\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-SHOW\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqlslap.1 b/man/mysqlslap.1 index 4f31489dead..1658fd7c2f0 100644 --- a/man/mysqlslap.1 +++ b/man/mysqlslap.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLSLAP\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-SLAP\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/mysqltest.1 b/man/mysqltest.1 index 57a05521498..73a466370b4 100644 --- a/man/mysqltest.1 +++ b/man/mysqltest.1 @@ -1,6 +1,6 @@ '\" t .\" -.TH "\FBMYSQLTEST\FR" "1" "15 May 2020" "MariaDB 10\&.6" "MariaDB Database System" +.TH "\FBMARIADB-TEST\FR" "1" "15 May 2020" "MariaDB 10\&.7" "MariaDB Database System" .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/mysql-test/main/multi_update.result b/mysql-test/main/multi_update.result index 3ec9ea0caa5..674dc79fe12 100644 --- a/mysql-test/main/multi_update.result +++ b/mysql-test/main/multi_update.result @@ -1161,3 +1161,111 @@ ERROR 21000: Subquery returns more than 1 row update t1 set a= (select 2 from t1 having (a = 3)); ERROR 21000: Subquery returns more than 1 row drop tables t1; +# +# MDEV-28246 Optimizer uses all partitions during an update in MariaDB 10.6.x but not in 10.2.x +# +CREATE TABLE t1 ( +part INT(1), +a INT(1), +b INT(1), +PRIMARY KEY (a,part), +INDEX b (b,part) +) PARTITION BY LIST (part) ( +PARTITION Current VALUES IN (0), +PARTITION Relevant VALUES IN (1), +PARTITION Archive VALUES IN (2) +); +CREATE TABLE t2 LIKE t1; +INSERT INTO t1 (part,a,b) VALUES (0,0,0),(1,1,1),(2,2,2); +INSERT INTO t2 (part,a,b) VALUES (0,0,0),(1,1,1),(2,2,2); +# Expecting partition "Current" +EXPLAIN FORMAT=JSON UPDATE t2 JOIN t1 USING(a) SET t2.part=3 WHERE t2.part=0 AND t1.part=0; +EXPLAIN +{ + "query_block": { + "select_id": 1, + "nested_loop": [ + { + "table": { + "table_name": "t2", + "partitions": ["Current"], + "access_type": "system", + "possible_keys": ["PRIMARY"], + "rows": 1, + "filtered": 100 + } + }, + { + "table": { + "table_name": "t1", + "partitions": ["Current"], + "access_type": "system", + "possible_keys": ["PRIMARY"], + "rows": 1, + "filtered": 100 + } + } + ] + } +} +# Expecting partition "Relevant" +EXPLAIN FORMAT=JSON UPDATE t2 JOIN t1 USING(a) SET t2.part=2 WHERE t2.part=1 AND t1.part=1; +EXPLAIN +{ + "query_block": { + "select_id": 1, + "nested_loop": [ + { + "table": { + "table_name": "t2", + "partitions": ["Relevant"], + "access_type": "system", + "possible_keys": ["PRIMARY"], + "rows": 1, + "filtered": 100 + } + }, + { + "table": { + "table_name": "t1", + "partitions": ["Relevant"], + "access_type": "system", + "possible_keys": ["PRIMARY"], + "rows": 1, + "filtered": 100 + } + } + ] + } +} +# Expecting partition "Archive" +EXPLAIN FORMAT=JSON UPDATE t2 JOIN t1 USING(a) SET t2.part=3 WHERE t2.part=2 AND t1.part=2; +EXPLAIN +{ + "query_block": { + "select_id": 1, + "nested_loop": [ + { + "table": { + "table_name": "t2", + "partitions": ["Archive"], + "access_type": "system", + "possible_keys": ["PRIMARY"], + "rows": 1, + "filtered": 100 + } + }, + { + "table": { + "table_name": "t1", + "partitions": ["Archive"], + "access_type": "system", + "possible_keys": ["PRIMARY"], + "rows": 1, + "filtered": 100 + } + } + ] + } +} +DROP TABLES t1, t2; diff --git a/mysql-test/main/multi_update.test b/mysql-test/main/multi_update.test index 3ee36f97fc5..5f4b5fc8ec3 100644 --- a/mysql-test/main/multi_update.test +++ b/mysql-test/main/multi_update.test @@ -1098,3 +1098,34 @@ select a from t1 where a= (select 2 from t1 having (a = 3)); --error ER_SUBQUERY_NO_1_ROW update t1 set a= (select 2 from t1 having (a = 3)); drop tables t1; + +--echo # +--echo # MDEV-28246 Optimizer uses all partitions during an update in MariaDB 10.6.x but not in 10.2.x +--echo # +--source include/have_partition.inc +CREATE TABLE t1 ( + part INT(1), + a INT(1), + b INT(1), + PRIMARY KEY (a,part), + INDEX b (b,part) +) PARTITION BY LIST (part) ( + PARTITION Current VALUES IN (0), + PARTITION Relevant VALUES IN (1), + PARTITION Archive VALUES IN (2) +); + +CREATE TABLE t2 LIKE t1; +INSERT INTO t1 (part,a,b) VALUES (0,0,0),(1,1,1),(2,2,2); +INSERT INTO t2 (part,a,b) VALUES (0,0,0),(1,1,1),(2,2,2); + +--echo # Expecting partition "Current" +EXPLAIN FORMAT=JSON UPDATE t2 JOIN t1 USING(a) SET t2.part=3 WHERE t2.part=0 AND t1.part=0; + +--echo # Expecting partition "Relevant" +EXPLAIN FORMAT=JSON UPDATE t2 JOIN t1 USING(a) SET t2.part=2 WHERE t2.part=1 AND t1.part=1; + +--echo # Expecting partition "Archive" +EXPLAIN FORMAT=JSON UPDATE t2 JOIN t1 USING(a) SET t2.part=3 WHERE t2.part=2 AND t1.part=2; + +DROP TABLES t1, t2; diff --git a/mysql-test/main/partition_exchange.result b/mysql-test/main/partition_exchange.result index 2b69e2fff43..ac38b189800 100644 --- a/mysql-test/main/partition_exchange.result +++ b/mysql-test/main/partition_exchange.result @@ -1237,8 +1237,18 @@ ALTER TABLE t2 REMOVE PARTITIONING; ALTER TABLE t1 EXCHANGE PARTITION pm WITH TABLE t2; DROP TABLE t1, t2; # -# End of 10.3 tests +# MDEV-14642 Assertion `table->s->db_create_options == part_table->s->db_create_options' failed in compare_table_with_partition # +CREATE TABLE t1 (a INT) ROW_FORMAT=DYNAMIC PARTITION BY KEY(a) PARTITIONS 2; +CREATE TABLE t2 (a INT) ; +ALTER TABLE t1 EXCHANGE PARTITION p1 WITH TABLE t2; +ERROR HY000: Tables have different definitions +DROP TABLE t1, t2; +CREATE TABLE t1 (a INT, PRIMARY KEY(a)) ENGINE=InnoDB PARTITION BY KEY(a) PARTITIONS 2; +CREATE TABLE t2 (a INT, PRIMARY KEY(a)) CHECKSUM=1, ENGINE=InnoDB; +ALTER TABLE t1 EXCHANGE PARTITION p0 WITH TABLE t2; +ERROR HY000: Tables have different definitions +DROP TABLE t1, t2; # # MDEV-27683 EXCHANGE PARTITION allows different index direction, but causes further errors # diff --git a/mysql-test/main/partition_exchange.test b/mysql-test/main/partition_exchange.test index 3383ebb01e3..82ccc29e00e 100644 --- a/mysql-test/main/partition_exchange.test +++ b/mysql-test/main/partition_exchange.test @@ -533,8 +533,23 @@ ALTER TABLE t1 EXCHANGE PARTITION pm WITH TABLE t2; DROP TABLE t1, t2; --echo # ---echo # End of 10.3 tests +--echo # MDEV-14642 Assertion `table->s->db_create_options == part_table->s->db_create_options' failed in compare_table_with_partition --echo # +CREATE TABLE t1 (a INT) ROW_FORMAT=DYNAMIC PARTITION BY KEY(a) PARTITIONS 2; +CREATE TABLE t2 (a INT) ; +--error ER_TABLES_DIFFERENT_METADATA +ALTER TABLE t1 EXCHANGE PARTITION p1 WITH TABLE t2; + +# Cleanup +DROP TABLE t1, t2; + +CREATE TABLE t1 (a INT, PRIMARY KEY(a)) ENGINE=InnoDB PARTITION BY KEY(a) PARTITIONS 2; +CREATE TABLE t2 (a INT, PRIMARY KEY(a)) CHECKSUM=1, ENGINE=InnoDB; +--error ER_TABLES_DIFFERENT_METADATA +ALTER TABLE t1 EXCHANGE PARTITION p0 WITH TABLE t2; + +# Cleanup +DROP TABLE t1, t2; --echo # --echo # MDEV-27683 EXCHANGE PARTITION allows different index direction, but causes further errors diff --git a/mysql-test/main/ssl_timeout.result b/mysql-test/main/ssl_timeout.result index e0d1dbed69f..208be527a6b 100644 --- a/mysql-test/main/ssl_timeout.result +++ b/mysql-test/main/ssl_timeout.result @@ -5,6 +5,6 @@ SELECT (VARIABLE_VALUE <> '') AS have_ssl FROM INFORMATION_SCHEMA.SESSION_STATUS have_ssl 1 SELECT SLEEP(600); -ERROR HY000: Lost connection to server during query +Got one of the listed errors connection default; disconnect ssl_con; diff --git a/mysql-test/main/ssl_timeout.test b/mysql-test/main/ssl_timeout.test index 430fe7130de..f5965f874ff 100644 --- a/mysql-test/main/ssl_timeout.test +++ b/mysql-test/main/ssl_timeout.test @@ -10,7 +10,7 @@ connect (ssl_con,localhost,root,,,,,SSL read_timeout=5); SELECT (VARIABLE_VALUE <> '') AS have_ssl FROM INFORMATION_SCHEMA.SESSION_STATUS WHERE VARIABLE_NAME='Ssl_cipher'; # --error CR_SERVER_LOST ---error 2013 +--error 2013,2026 SELECT SLEEP(600); connection default; diff --git a/sql/sql_partition_admin.cc b/sql/sql_partition_admin.cc index fb1ae0d5fc7..b1989f79051 100644 --- a/sql/sql_partition_admin.cc +++ b/sql/sql_partition_admin.cc @@ -258,8 +258,13 @@ bool compare_table_with_partition(THD *thd, TABLE *table, TABLE *part_table, my_error(ER_TABLES_DIFFERENT_METADATA, MYF(0)); DBUG_RETURN(TRUE); } - DBUG_ASSERT(table->s->db_create_options == - part_table->s->db_create_options); + + if (table->s->db_create_options != part_table->s->db_create_options) + { + my_error(ER_TABLES_DIFFERENT_METADATA, MYF(0)); + DBUG_RETURN(TRUE); + } + DBUG_ASSERT(table->s->db_options_in_use == part_table->s->db_options_in_use); diff --git a/sql/sql_update.cc b/sql/sql_update.cc index 843966f13c8..4da967bb115 100644 --- a/sql/sql_update.cc +++ b/sql/sql_update.cc @@ -2123,10 +2123,9 @@ int multi_update::prepare(List ¬_used_values, if (!tl) DBUG_RETURN(1); update.link_in_list(tl, &tl->next_local); - tl->shared= table_count++; + table_ref->shared= tl->shared= table_count++; table->no_keyread=1; table->covering_keys.clear_all(); - table->pos_in_table_list= tl; table->prepare_triggers_for_update_stmt_or_event(); table->reset_default_fields(); } diff --git a/storage/spider/mysql-test/spider/r/variable_deprecation.result b/storage/spider/mysql-test/spider/r/variable_deprecation.result index 4b52da3c996..6aba1e6f181 100644 --- a/storage/spider/mysql-test/spider/r/variable_deprecation.result +++ b/storage/spider/mysql-test/spider/r/variable_deprecation.result @@ -181,6 +181,21 @@ Warnings: Warning 1287 The table parameter 'crd_weight' is deprecated and will be removed in a future release DROP TABLE tbl_a; DROP TABLE tbl_b; +# MDEV-28560 Deprecate spider_buffer_size +SET spider_buffer_size = 1; +Warnings: +Warning 1287 '@@spider_buffer_size' is deprecated and will be removed in a future release +SHOW VARIABLES LIKE "spider_buffer_size"; +Variable_name Value +spider_buffer_size 1 +CREATE TABLE tbl_a (a INT) ENGINE=Spider COMMENT='bfz "1"'; +Warnings: +Warning 1287 The table parameter 'bfz' is deprecated and will be removed in a future release +CREATE TABLE tbl_b (a INT) ENGINE=Spider COMMENT='buffer_size "1"'; +Warnings: +Warning 1287 The table parameter 'buffer_size' is deprecated and will be removed in a future release +DROP TABLE tbl_a; +DROP TABLE tbl_b; DROP DATABASE auto_test_local; for master_1 for child2 diff --git a/storage/spider/mysql-test/spider/t/variable_deprecation.test b/storage/spider/mysql-test/spider/t/variable_deprecation.test index 63965cb38c4..1d2d6bfd77a 100644 --- a/storage/spider/mysql-test/spider/t/variable_deprecation.test +++ b/storage/spider/mysql-test/spider/t/variable_deprecation.test @@ -108,6 +108,15 @@ eval CREATE TABLE tbl_b (a INT) $MASTER_1_ENGINE COMMENT='crd_weight "1"'; DROP TABLE tbl_a; DROP TABLE tbl_b; +--echo # MDEV-28560 Deprecate spider_buffer_size +SET spider_buffer_size = 1; +SHOW VARIABLES LIKE "spider_buffer_size"; +eval CREATE TABLE tbl_a (a INT) $MASTER_1_ENGINE COMMENT='bfz "1"'; +eval CREATE TABLE tbl_b (a INT) $MASTER_1_ENGINE COMMENT='buffer_size "1"'; + +DROP TABLE tbl_a; +DROP TABLE tbl_b; + DROP DATABASE auto_test_local; --disable_query_log diff --git a/storage/spider/spd_param.cc b/storage/spider/spd_param.cc index 48f30a57c7b..a6063bd0070 100644 --- a/storage/spider/spd_param.cc +++ b/storage/spider/spd_param.cc @@ -1026,7 +1026,7 @@ int spider_param_bulk_update_size( */ static MYSQL_THDVAR_INT( buffer_size, /* name */ - PLUGIN_VAR_RQCMDARG, /* opt */ + PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_DEPRECATED, /* opt */ "Buffer size", /* comment */ NULL, /* check */ spider_use_table_value_deprecated, /* update */ diff --git a/storage/spider/spd_table.cc b/storage/spider/spd_table.cc index c72c6ea62b3..4d4ed78435a 100644 --- a/storage/spider/spd_table.cc +++ b/storage/spider/spd_table.cc @@ -2298,6 +2298,7 @@ int spider_parse_connect_info( #ifdef HA_CAN_BULK_ACCESS SPIDER_PARAM_INT_WITH_MAX("baf", bulk_access_free, 0, 1); #endif + SPIDER_PARAM_DEPRECATED_WARNING("bfz"); SPIDER_PARAM_INT("bfz", buffer_size, 0); #ifndef WITHOUT_SPIDER_BG_SEARCH SPIDER_PARAM_LONGLONG("bfr", bgs_first_read, 0); @@ -2516,6 +2517,7 @@ int spider_parse_connect_info( SPIDER_PARAM_DEPRECATED_WARNING("use_handler"); SPIDER_PARAM_LONG_LIST_WITH_MAX("use_handler", use_handlers, 0, 3); SPIDER_PARAM_INT_WITH_MAX("casual_read", casual_read, 0, 63); + SPIDER_PARAM_DEPRECATED_WARNING("buffer_size"); SPIDER_PARAM_INT("buffer_size", buffer_size, 0); error_num = connect_string_parse.print_param_error(); goto error;