Skip to content

Commit

Permalink
MDEV-12645 - mysql_install_db: no install test db option
Browse files Browse the repository at this point in the history
Added --skip-test-db option to mysql_install_db. If specified, no test
database created and relevant grants issued.

Removed --skip-auth-anonymous-user option of mysql_install_db. Now it is
covered by --skip-test-db.

Dropped some Debian patches that did the same.

Removed unused make_win_bin_dist.1, make_win_bin_dist and
mysql_install_db.pl.in.
  • Loading branch information
svoj committed Apr 30, 2018
1 parent 8bbcc0d commit 9a84980
Show file tree
Hide file tree
Showing 52 changed files with 729 additions and 1,386 deletions.
1 change: 1 addition & 0 deletions debian/mariadb-server-10.3.install
Original file line number Diff line number Diff line change
Expand Up @@ -98,4 +98,5 @@ usr/share/mysql/mysql_performance_tables.sql
usr/share/mysql/mysql_system_tables.sql
usr/share/mysql/mysql_system_tables_data.sql
usr/share/mysql/mysql_test_data_timezone.sql
usr/share/mysql/mysql_test_db.sql
usr/share/mysql/wsrep_notify
4 changes: 3 additions & 1 deletion debian/mariadb-server-10.3.postinst
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,9 @@ EOF
# Debian: beware of the bashisms...
# Debian: can safely run on upgrades with existing databases
set +e
bash /usr/bin/mysql_install_db --rpm --cross-bootstrap --user=mysql --disable-log-bin 2>&1 | $ERR_LOGGER
bash /usr/bin/mysql_install_db --rpm --cross-bootstrap --user=mysql \
--disable-log-bin --skip-test-db 2>&1 | \
$ERR_LOGGER
set -e


Expand Down
3 changes: 0 additions & 3 deletions debian/patches/00list
Original file line number Diff line number Diff line change
@@ -1,5 +1,2 @@
33_scripts__mysql_create_system_tables__no_test.dpatch
38_scripts__mysqld_safe.sh__signals.dpatch
41_scripts__mysql_install_db.sh__no_test.dpatch
50_mysql-test__db_test.dpatch
61_replace_dash_with_bash_mbug675185.dpatch

This file was deleted.

20 changes: 0 additions & 20 deletions debian/patches/41_scripts__mysql_install_db.sh__no_test.dpatch

This file was deleted.

24 changes: 0 additions & 24 deletions debian/patches/50_mysql-test__db_test.dpatch

This file was deleted.

176 changes: 0 additions & 176 deletions man/make_win_bin_dist.1

This file was deleted.

4 changes: 4 additions & 0 deletions mysql-test/main/ctype_create.result
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ USE test;
#
# MDEV-7387 Alter table xxx CHARACTER SET utf8, CONVERT TO CHARACTER SET latin1 should fail
#
CREATE DATABASE tmp DEFAULT CHARACTER SET latin5;
USE tmp;
CREATE TABLE t1 (a VARCHAR(10)) CHARACTER SET DEFAULT, CHARACTER SET utf8;
ERROR HY000: Conflicting declarations: 'CHARACTER SET DEFAULT' and 'CHARACTER SET utf8'
CREATE TABLE t1 (a VARCHAR(10)) CHARACTER SET utf8, CHARACTER SET DEFAULT;
Expand All @@ -105,6 +107,8 @@ ERROR HY000: Conflicting declarations: 'CHARACTER SET latin5' and 'CHARACTER SET
ALTER TABLE t1 CONVERT TO CHARACTER SET DEFAULT, CHARACTER SET latin1;
ERROR HY000: Conflicting declarations: 'CHARACTER SET latin5' and 'CHARACTER SET latin1'
DROP TABLE t1;
DROP DATABASE tmp;
USE test;
#
# End of 10.0 tests
#
4 changes: 4 additions & 0 deletions mysql-test/main/ctype_create.test
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@ USE test;
--echo #
--echo # MDEV-7387 Alter table xxx CHARACTER SET utf8, CONVERT TO CHARACTER SET latin1 should fail
--echo #
CREATE DATABASE tmp DEFAULT CHARACTER SET latin5;
USE tmp;
--error ER_CONFLICTING_DECLARATIONS
CREATE TABLE t1 (a VARCHAR(10)) CHARACTER SET DEFAULT, CHARACTER SET utf8;
--error ER_CONFLICTING_DECLARATIONS
Expand All @@ -137,6 +139,8 @@ ALTER TABLE t1 CONVERT TO CHARACTER SET DEFAULT, CHARACTER SET utf8;
--error ER_CONFLICTING_DECLARATIONS
ALTER TABLE t1 CONVERT TO CHARACTER SET DEFAULT, CHARACTER SET latin1;
DROP TABLE t1;
DROP DATABASE tmp;
USE test;

--echo #
--echo # End of 10.0 tests
Expand Down
1 change: 0 additions & 1 deletion mysql-test/main/ctype_latin1_de-master.opt

This file was deleted.

6 changes: 5 additions & 1 deletion mysql-test/main/ctype_latin1_de.result
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
create database latin1_german2_ci default character set latin1 collate latin1_german2_ci;
use latin1_german2_ci;
set names latin1;
set @@collation_connection=latin1_german2_ci;
select @@collation_connection;
Expand Down Expand Up @@ -139,7 +141,7 @@ a
a
check table t1;
Table Op Msg_type Msg_text
test.t1 check status OK
latin1_german2_ci.t1 check status OK
select * from t1 where a like "�%";
a b
� 1
Expand Down Expand Up @@ -835,3 +837,5 @@ hex(weight_string('x
#
# End of 5.6 tests
#
drop database latin1_german2_ci;
use test;
5 changes: 5 additions & 0 deletions mysql-test/main/ctype_latin1_de.test
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
#
# Test latin_de character set
#
create database latin1_german2_ci default character set latin1 collate latin1_german2_ci;
use latin1_german2_ci;

set names latin1;
set @@collation_connection=latin1_german2_ci;
Expand Down Expand Up @@ -180,3 +182,6 @@ select hex(weight_string('x
--echo #
--echo # End of 5.6 tests
--echo #

drop database latin1_german2_ci;
use test;
1 change: 1 addition & 0 deletions mysql-test/main/ctype_ucs.result
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,7 @@ DROP TABLE t1;
# and reverse() function
#
# Problem # 1 (original report): wrong parsing of ucs2 data
SET character_set_connection=ucs2;
SELECT '00' UNION SELECT '10' INTO OUTFILE 'tmpp.txt';
CREATE TABLE t1(a INT);
LOAD DATA INFILE 'tmpp.txt' INTO TABLE t1 CHARACTER SET ucs2
Expand Down
1 change: 1 addition & 0 deletions mysql-test/main/ctype_ucs.test
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ DROP TABLE t1;
--echo #

--echo # Problem # 1 (original report): wrong parsing of ucs2 data
SET character_set_connection=ucs2;
SELECT '00' UNION SELECT '10' INTO OUTFILE 'tmpp.txt';
CREATE TABLE t1(a INT);
LOAD DATA INFILE 'tmpp.txt' INTO TABLE t1 CHARACTER SET ucs2
Expand Down
2 changes: 2 additions & 0 deletions mysql-test/main/drop_bad_db_type.result
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,10 @@ Level Warning
Code 1286
Message Unknown storage engine 'ARCHIVE'
install soname 'ha_archive';
db.opt
t1.ARZ
t1.frm
drop table t1;
db.opt
uninstall soname 'ha_archive';
set debug_dbug='-d,unstable_db_type';
Loading

0 comments on commit 9a84980

Please sign in to comment.