mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
mysql-5.5.29 merge
This commit is contained in:
@@ -40,3 +40,4 @@ ha_blackhole storage/blackhole BLACKHOLE_PLUGIN
|
||||
ha_federated storage/federated FEDERATED_PLUGIN
|
||||
mypluglib plugin/fulltext SIMPLE_PARSER
|
||||
libdaemon_example plugin/daemon_example DAEMONEXAMPLE
|
||||
adt_null plugin/audit_null AUDIT_NULL
|
||||
|
@@ -8,6 +8,7 @@
|
||||
# --let $rpl_server_number= N
|
||||
# [--let $rpl_server_parameters= --flag1 --flag2 ...]
|
||||
# [--let $rpl_debug= 1]
|
||||
# [--let $rpl_server_error= 0]
|
||||
# --source include/rpl_start_server.inc
|
||||
#
|
||||
# Parameters:
|
||||
@@ -21,6 +22,9 @@
|
||||
# If set, extra parameters given by this variable are passed to
|
||||
# mysqld.
|
||||
#
|
||||
# $rpl_server_error
|
||||
# If set, failure of the server startup is expected.
|
||||
#
|
||||
# $rpl_debug
|
||||
# See include/rpl_init.inc
|
||||
#
|
||||
@@ -47,8 +51,9 @@ if ($rpl_server_parameters)
|
||||
# Write file to make mysql-test-run.pl start up the server again
|
||||
--exec echo "$_rpl_start_server_command" > $MYSQLTEST_VARDIR/tmp/mysqld.$rpl_server_number.expect
|
||||
|
||||
--source include/rpl_reconnect.inc
|
||||
|
||||
|
||||
--let $include_filename= rpl_start_server.inc $_rpl_start_server_args
|
||||
--source include/end_include_file.inc
|
||||
if (!$rpl_server_error)
|
||||
{
|
||||
--source include/rpl_reconnect.inc
|
||||
--let $include_filename= rpl_start_server.inc $_rpl_start_server_args
|
||||
--source include/end_include_file.inc
|
||||
}
|
||||
|
@@ -3,3 +3,5 @@ Name Location Comment
|
||||
Ronald Bradford Brisbane, Australia EFF contribution for UC2006 Auction
|
||||
Sheeri Kritzer Boston, Mass. USA EFF contribution for UC2006 Auction
|
||||
Mark Shuttleworth London, UK. EFF contribution for UC2006 Auction
|
||||
Warnings:
|
||||
Warning 1681 'SHOW CONTRIBUTORS' is deprecated and will be removed in a future release.
|
||||
|
@@ -121,17 +121,20 @@ ERROR 28000: Access denied for user 'grant_plug_dest'@'localhost'
|
||||
this should fail : not the same user
|
||||
GRANT PROXY ON grant_plug TO grant_plug_dest;
|
||||
ERROR 28000: Access denied for user 'grant_plug_dest'@'localhost'
|
||||
this should fail : same user, but on a different host
|
||||
This is a valid grant
|
||||
GRANT PROXY ON grant_plug_dest TO grant_plug;
|
||||
ERROR 28000: Access denied for user 'grant_plug_dest'@'localhost'
|
||||
this should work : same user
|
||||
GRANT PROXY ON grant_plug_dest@localhost TO grant_plug_dest2;
|
||||
REVOKE PROXY ON grant_plug_dest@localhost FROM grant_plug_dest2;
|
||||
REVOKE PROXY ON grant_plug_dest FROM grant_plug;
|
||||
this should work : same user
|
||||
GRANT PROXY ON grant_plug_dest TO grant_plug_dest2;
|
||||
REVOKE PROXY ON grant_plug_dest FROM grant_plug_dest2;
|
||||
this should fail : not the same user
|
||||
GRANT PROXY ON grant_plug_dest@localhost TO grant_plug WITH GRANT OPTION;
|
||||
ERROR 28000: Access denied for user 'grant_plug_dest'@'localhost'
|
||||
this should fail : not the same user
|
||||
REVOKE PROXY ON grant_plug_dest@localhost FROM grant_plug;
|
||||
ERROR 28000: Access denied for user 'grant_plug_dest'@'localhost'
|
||||
this should fail : can't create users
|
||||
GRANT PROXY ON grant_plug_dest@localhost TO grant_plug@localhost;
|
||||
GRANT PROXY ON grant_plug_dest TO grant_plug@localhost;
|
||||
ERROR 42000: You are not allowed to create a user with GRANT
|
||||
in default connection
|
||||
# test what root can grant
|
||||
@@ -149,12 +152,12 @@ GRANT PROXY ON future_user TO grant_plug;
|
||||
in default connection
|
||||
SHOW GRANTS FOR grant_plug;
|
||||
Grants for grant_plug@%
|
||||
GRANT ALL PRIVILEGES ON *.* TO 'grant_plug'@'%' IDENTIFIED VIA test_plugin_server USING 'grant_plug_dest' WITH GRANT OPTION
|
||||
GRANT ALL PRIVILEGES ON *.* TO 'grant_plug'@'%' IDENTIFIED VIA test_plugin_server USING 'grant_plug_dest'
|
||||
GRANT PROXY ON 'future_user'@'%' TO 'grant_plug'@'%'
|
||||
REVOKE PROXY ON future_user FROM grant_plug;
|
||||
SHOW GRANTS FOR grant_plug;
|
||||
Grants for grant_plug@%
|
||||
GRANT ALL PRIVILEGES ON *.* TO 'grant_plug'@'%' IDENTIFIED VIA test_plugin_server USING 'grant_plug_dest' WITH GRANT OPTION
|
||||
GRANT ALL PRIVILEGES ON *.* TO 'grant_plug'@'%' IDENTIFIED VIA test_plugin_server USING 'grant_plug_dest'
|
||||
## testing drop user
|
||||
CREATE USER test_drop@localhost;
|
||||
GRANT PROXY ON future_user TO test_drop@localhost;
|
||||
|
@@ -1552,3 +1552,14 @@ RELEASE_LOCK('t')
|
||||
óóóó
|
||||
1
|
||||
SET NAMES latin1;
|
||||
#
|
||||
# WL#6454: Deprecate SHOW AUTHORS and SHOW CONTRIBUTORS
|
||||
#
|
||||
SHOW AUTHORS;
|
||||
SHOW WARNINGS;
|
||||
Level Code Message
|
||||
Warning 1681 'SHOW AUTHORS' is deprecated and will be removed in a future release.
|
||||
SHOW CONTRIBUTORS;
|
||||
SHOW WARNINGS;
|
||||
Level Code Message
|
||||
Warning 1681 'SHOW CONTRIBUTORS' is deprecated and will be removed in a future release.
|
||||
|
@@ -259,7 +259,6 @@ SELECT `my.db`.f1(2);
|
||||
# Switching to default connection.
|
||||
DROP DATABASE `my.db`;
|
||||
USE test;
|
||||
set @@global.concurrent_insert= @old_concurrent_insert;
|
||||
#
|
||||
# Bug#11763507 - 56224: FUNCTION NAME IS CASE-SENSITIVE
|
||||
#
|
||||
|
@@ -1269,3 +1269,43 @@ SELECT * FROM t1;
|
||||
c1 c2
|
||||
1 NULL
|
||||
DROP TABLE t1;
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
Variable_name Value
|
||||
auto_increment_increment 1
|
||||
auto_increment_offset 1
|
||||
CREATE TABLE t1 (c1 INT UNSIGNED PRIMARY KEY AUTO_INCREMENT, c2 VARCHAR(10)) ENGINE=InnoDB;
|
||||
INSERT INTO t1 VALUES (2147483648, 'a');
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` int(10) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`c2` varchar(10) DEFAULT NULL,
|
||||
PRIMARY KEY (`c1`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=2147483649 DEFAULT CHARSET=latin1
|
||||
SELECT * FROM t1;
|
||||
c1 c2
|
||||
2147483648 a
|
||||
ALTER TABLE t1 CHANGE c1 c1 INT;
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'c1' at row 1
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` int(11) NOT NULL DEFAULT '0',
|
||||
`c2` varchar(10) DEFAULT NULL,
|
||||
PRIMARY KEY (`c1`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1(c2) VALUES('b');
|
||||
SELECT * FROM t1;
|
||||
c1 c2
|
||||
0 b
|
||||
2147483647 a
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` int(11) NOT NULL DEFAULT '0',
|
||||
`c2` varchar(10) DEFAULT NULL,
|
||||
PRIMARY KEY (`c1`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
@@ -126,12 +126,12 @@ CREATE TABLE t1(
|
||||
c TEXT NOT NULL, d TEXT NOT NULL,
|
||||
PRIMARY KEY (c(767),d(767)))
|
||||
ENGINE=InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1 CHARSET=ASCII;
|
||||
ERROR 42000: Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. You have to change some columns to TEXT or BLOBs
|
||||
ERROR 42000: Row size too large (> 8126). Changing some columns to TEXT or BLOB may help. In current row format, BLOB prefix of 0 bytes is stored inline.
|
||||
CREATE TABLE t1(
|
||||
c TEXT NOT NULL, d TEXT NOT NULL,
|
||||
PRIMARY KEY (c(767),d(767)))
|
||||
ENGINE=InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=2 CHARSET=ASCII;
|
||||
ERROR 42000: Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. You have to change some columns to TEXT or BLOBs
|
||||
ERROR 42000: Row size too large (> 8126). Changing some columns to TEXT or BLOB may help. In current row format, BLOB prefix of 0 bytes is stored inline.
|
||||
CREATE TABLE t1(
|
||||
c TEXT NOT NULL, d TEXT NOT NULL,
|
||||
PRIMARY KEY (c(767),d(767)))
|
||||
@@ -139,7 +139,7 @@ ENGINE=InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=4 CHARSET=ASCII;
|
||||
drop table t1;
|
||||
CREATE TABLE t1(c TEXT, PRIMARY KEY (c(440)))
|
||||
ENGINE=InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1 CHARSET=ASCII;
|
||||
ERROR 42000: Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. You have to change some columns to TEXT or BLOBs
|
||||
ERROR 42000: Row size too large (> 8126). Changing some columns to TEXT or BLOB may help. In current row format, BLOB prefix of 0 bytes is stored inline.
|
||||
CREATE TABLE t1(c TEXT, PRIMARY KEY (c(438)))
|
||||
ENGINE=InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1 CHARSET=ASCII;
|
||||
INSERT INTO t1 VALUES(REPEAT('A',512)),(REPEAT('B',512));
|
||||
|
@@ -3026,7 +3026,7 @@ c21 CHAR(255), c22 CHAR(255), c23 CHAR(255), c24 CHAR(255),
|
||||
c25 CHAR(255), c26 CHAR(255), c27 CHAR(255), c28 CHAR(255),
|
||||
c29 CHAR(255), c30 CHAR(255), c31 CHAR(255), c32 CHAR(255)
|
||||
) ENGINE = InnoDB;
|
||||
ERROR 42000: Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. You have to change some columns to TEXT or BLOBs
|
||||
ERROR 42000: Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help. In current row format, BLOB prefix of 768 bytes is stored inline.
|
||||
DROP TABLE IF EXISTS t1;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 't1'
|
||||
|
@@ -8,7 +8,7 @@ ERROR HY000: Too big row
|
||||
SHOW WARNINGS;
|
||||
Level Code Message
|
||||
Error 139 Too big row
|
||||
Error 1118 Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. You have to change some columns to TEXT or BLOBs
|
||||
Error 1118 Row size too large (> 8126). Changing some columns to TEXT or BLOB may help. In current row format, BLOB prefix of 0 bytes is stored inline.
|
||||
DROP TABLE bug53591;
|
||||
SET GLOBAL innodb_file_format=Antelope;
|
||||
SET GLOBAL innodb_file_per_table=0;
|
||||
|
@@ -649,7 +649,7 @@ CREATE TABLE worklog5743 (col_1_varchar VARCHAR (4000) CHARACTER SET 'utf8',
|
||||
col_2_varchar VARCHAR (4000) CHARACTER SET 'utf8' ,
|
||||
PRIMARY KEY (col_1_varchar(1024))
|
||||
) ROW_FORMAT=DYNAMIC, engine = innodb;
|
||||
ERROR 42000: Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. You have to change some columns to TEXT or BLOBs
|
||||
ERROR 42000: Row size too large (> max_row_size). Changing some columns to TEXT or BLOB may help. In current row format, BLOB prefix of 0 bytes is stored inline.
|
||||
CREATE TABLE worklog5743 (
|
||||
col_1_varbinary VARBINARY (4000) ,
|
||||
col_2_varchar VARCHAR (4000) CHARACTER SET 'utf8',
|
||||
|
@@ -139,7 +139,7 @@ DROP TABLE IF EXISTS t1;
|
||||
CREATE TABLE t1 (c1 INT AUTO_INCREMENT, c2 INT, PRIMARY KEY(c1)) ENGINE=InnoDB;
|
||||
INSERT INTO t1 VALUES (NULL, 1);
|
||||
DELETE FROM t1 WHERE c1 = 1;
|
||||
INSERT INTO t1 VALUES (2,1);
|
||||
INSERT INTO t1 VALUES (2,1);
|
||||
INSERT INTO t1 VALUES (NULL,8);
|
||||
SELECT * FROM t1;
|
||||
DROP TABLE t1;
|
||||
@@ -639,7 +639,7 @@ SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
|
||||
# Check if we handl offset > column max value properly
|
||||
# Check if we handle offset > column max value properly
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=256;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
# TINYINT
|
||||
@@ -648,3 +648,21 @@ INSERT INTO t1 VALUES (1, NULL);
|
||||
SHOW CREATE TABLE t1;
|
||||
SELECT * FROM t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
# Check if we handle the case where a current value is greater than the max
|
||||
# of the column. IMO, this should not be allowed and the assertion that fails
|
||||
# is actually an invariant.
|
||||
SET @@SESSION.AUTO_INCREMENT_INCREMENT=1, @@SESSION.AUTO_INCREMENT_OFFSET=1;
|
||||
SHOW VARIABLES LIKE "%auto_inc%";
|
||||
# TINYINT
|
||||
CREATE TABLE t1 (c1 INT UNSIGNED PRIMARY KEY AUTO_INCREMENT, c2 VARCHAR(10)) ENGINE=InnoDB;
|
||||
INSERT INTO t1 VALUES (2147483648, 'a');
|
||||
SHOW CREATE TABLE t1;
|
||||
SELECT * FROM t1;
|
||||
ALTER TABLE t1 CHANGE c1 c1 INT;
|
||||
SHOW CREATE TABLE t1;
|
||||
INSERT INTO t1(c2) VALUES('b');
|
||||
SELECT * FROM t1;
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
|
@@ -1,5 +1,10 @@
|
||||
-- source include/have_innodb.inc
|
||||
|
||||
if (`select plugin_auth_version <= "1.1.8-29.1" from information_schema.plugins where plugin_name='innodb'`)
|
||||
{
|
||||
--skip Not fixed in XtraDB 1.1.8-29.1 or earlier
|
||||
}
|
||||
|
||||
let $per_table=`select @@innodb_file_per_table`;
|
||||
let $format=`select @@innodb_file_format`;
|
||||
let $innodb_strict_mode_orig=`select @@session.innodb_strict_mode`;
|
||||
|
@@ -4,6 +4,11 @@
|
||||
# .\sync\sync0sync.c line 324
|
||||
# is fixed
|
||||
|
||||
if (`select plugin_auth_version <= "1.1.8-29.1" from information_schema.plugins where plugin_name='innodb'`)
|
||||
{
|
||||
--skip Not fixed in XtraDB 1.1.8-29.1 or earlier
|
||||
}
|
||||
|
||||
#######################################################################
|
||||
# #
|
||||
# Please, DO NOT TOUCH this file as well as the innodb.result file. #
|
||||
|
@@ -1,5 +1,9 @@
|
||||
--source include/have_innodb.inc
|
||||
|
||||
if (`select plugin_auth_version <= "1.1.8-29.1" from information_schema.plugins where plugin_name='innodb'`)
|
||||
{
|
||||
--skip Not fixed in XtraDB 1.1.8-29.1 or earlier
|
||||
}
|
||||
let $file_format=`select @@innodb_file_format`;
|
||||
let $file_per_table=`select @@innodb_file_per_table`;
|
||||
|
||||
|
@@ -14,6 +14,10 @@
|
||||
# #
|
||||
######################################################################
|
||||
|
||||
if (`select plugin_auth_version <= "1.1.8-29.1" from information_schema.plugins where plugin_name='innodb'`)
|
||||
{
|
||||
--skip Not fixed in XtraDB 1.1.8-29.1 or earlier
|
||||
}
|
||||
|
||||
# Save innodb variables
|
||||
let $innodb_file_format_orig=`select @@innodb_file_format`;
|
||||
@@ -601,6 +605,7 @@ DROP TABLE worklog5743;
|
||||
# Prefix index with utf8 charset + varchar.
|
||||
# For varchar we also log the column itself as oppose of TEXT so it error
|
||||
# with limit 1024 due to overhead.
|
||||
--replace_regex /> [0-9]*/> max_row_size/
|
||||
-- error 1118
|
||||
CREATE TABLE worklog5743 (col_1_varchar VARCHAR (4000) CHARACTER SET 'utf8',
|
||||
col_2_varchar VARCHAR (4000) CHARACTER SET 'utf8' ,
|
||||
|
@@ -1,6 +1,7 @@
|
||||
UPDATE performance_schema.setup_instruments SET enabled = 'NO', timed = 'YES';
|
||||
UPDATE performance_schema.setup_instruments SET enabled = 'YES'
|
||||
WHERE name LIKE 'wait/io/file/%';
|
||||
flush status;
|
||||
DROP TABLE IF EXISTS t1;
|
||||
CREATE TABLE t1 (id INT PRIMARY KEY, b CHAR(100) DEFAULT 'initial value')
|
||||
ENGINE=MyISAM;
|
||||
@@ -113,3 +114,19 @@ WHERE p.PROCESSLIST_ID = 1
|
||||
GROUP BY h.EVENT_NAME
|
||||
HAVING TOTAL_WAIT > 0;
|
||||
UPDATE performance_schema.setup_instruments SET enabled = 'YES';
|
||||
show status like "performance_schema%";
|
||||
Variable_name Value
|
||||
Performance_schema_cond_classes_lost 0
|
||||
Performance_schema_cond_instances_lost 0
|
||||
Performance_schema_file_classes_lost 0
|
||||
Performance_schema_file_handles_lost 0
|
||||
Performance_schema_file_instances_lost 0
|
||||
Performance_schema_locker_lost 0
|
||||
Performance_schema_mutex_classes_lost 0
|
||||
Performance_schema_mutex_instances_lost 0
|
||||
Performance_schema_rwlock_classes_lost 0
|
||||
Performance_schema_rwlock_instances_lost 0
|
||||
Performance_schema_table_handles_lost 0
|
||||
Performance_schema_table_instances_lost 0
|
||||
Performance_schema_thread_classes_lost 0
|
||||
Performance_schema_thread_instances_lost 0
|
||||
|
@@ -2,6 +2,15 @@ UPDATE performance_schema.setup_instruments SET enabled = 'NO', timed = 'YES';
|
||||
UPDATE performance_schema.setup_instruments SET enabled = 'YES'
|
||||
WHERE name LIKE 'wait/synch/mutex/%'
|
||||
OR name LIKE 'wait/synch/rwlock/%';
|
||||
flush status;
|
||||
select NAME from performance_schema.mutex_instances
|
||||
where NAME = 'wait/synch/mutex/sql/LOCK_open';
|
||||
NAME
|
||||
wait/synch/mutex/sql/LOCK_open
|
||||
select NAME from performance_schema.rwlock_instances
|
||||
where NAME = 'wait/synch/rwlock/sql/LOCK_grant';
|
||||
NAME
|
||||
wait/synch/rwlock/sql/LOCK_grant
|
||||
DROP TABLE IF EXISTS t1;
|
||||
CREATE TABLE t1 (id INT PRIMARY KEY, b CHAR(100) DEFAULT 'initial value')
|
||||
ENGINE=MyISAM;
|
||||
@@ -112,3 +121,19 @@ test_fm2_rw_timed
|
||||
Success
|
||||
UPDATE performance_schema.setup_instruments SET enabled = 'YES';
|
||||
DROP TABLE t1;
|
||||
show status like "performance_schema%";
|
||||
Variable_name Value
|
||||
Performance_schema_cond_classes_lost 0
|
||||
Performance_schema_cond_instances_lost 0
|
||||
Performance_schema_file_classes_lost 0
|
||||
Performance_schema_file_handles_lost 0
|
||||
Performance_schema_file_instances_lost 0
|
||||
Performance_schema_locker_lost 0
|
||||
Performance_schema_mutex_classes_lost 0
|
||||
Performance_schema_mutex_instances_lost 0
|
||||
Performance_schema_rwlock_classes_lost 0
|
||||
Performance_schema_rwlock_instances_lost 0
|
||||
Performance_schema_table_handles_lost 0
|
||||
Performance_schema_table_instances_lost 0
|
||||
Performance_schema_thread_classes_lost 0
|
||||
Performance_schema_thread_instances_lost 0
|
||||
|
@@ -12,6 +12,9 @@ UPDATE performance_schema.setup_instruments SET enabled = 'NO', timed = 'YES';
|
||||
UPDATE performance_schema.setup_instruments SET enabled = 'YES'
|
||||
WHERE name LIKE 'wait/io/file/%';
|
||||
|
||||
# reset lost counters
|
||||
flush status;
|
||||
|
||||
--disable_warnings
|
||||
DROP TABLE IF EXISTS t1;
|
||||
--enable_warnings
|
||||
@@ -182,3 +185,7 @@ HAVING TOTAL_WAIT > 0;
|
||||
|
||||
# Clean-up.
|
||||
UPDATE performance_schema.setup_instruments SET enabled = 'YES';
|
||||
|
||||
# In case of failure, will indicate the root cause
|
||||
show status like "performance_schema%";
|
||||
|
||||
|
@@ -13,6 +13,15 @@ UPDATE performance_schema.setup_instruments SET enabled = 'YES'
|
||||
WHERE name LIKE 'wait/synch/mutex/%'
|
||||
OR name LIKE 'wait/synch/rwlock/%';
|
||||
|
||||
# reset lost counters
|
||||
flush status;
|
||||
|
||||
# Make sure objects are instrumented
|
||||
select NAME from performance_schema.mutex_instances
|
||||
where NAME = 'wait/synch/mutex/sql/LOCK_open';
|
||||
select NAME from performance_schema.rwlock_instances
|
||||
where NAME = 'wait/synch/rwlock/sql/LOCK_grant';
|
||||
|
||||
--disable_warnings
|
||||
DROP TABLE IF EXISTS t1;
|
||||
--enable_warnings
|
||||
@@ -116,3 +125,7 @@ SELECT IF((COALESCE(@after_count, 0) - COALESCE(@before_count, 0)) = 0, 'Success
|
||||
# Clean-up.
|
||||
UPDATE performance_schema.setup_instruments SET enabled = 'YES';
|
||||
DROP TABLE t1;
|
||||
|
||||
# In case of failure, will indicate the root cause
|
||||
show status like "performance_schema%";
|
||||
|
||||
|
@@ -93,7 +93,7 @@ Variable_name Value
|
||||
Rpl_semi_sync_master_no_tx 0
|
||||
show status like 'Rpl_semi_sync_master_yes_tx';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_yes_tx 301
|
||||
Rpl_semi_sync_master_yes_tx 11
|
||||
[ on slave ]
|
||||
[ slave status after replicated inserts ]
|
||||
show status like 'Rpl_semi_sync_slave_status';
|
||||
@@ -101,13 +101,13 @@ Variable_name Value
|
||||
Rpl_semi_sync_slave_status ON
|
||||
select count(distinct a) from t1;
|
||||
count(distinct a)
|
||||
300
|
||||
10
|
||||
select min(a) from t1;
|
||||
min(a)
|
||||
1
|
||||
select max(a) from t1;
|
||||
max(a)
|
||||
300
|
||||
10
|
||||
|
||||
# BUG#50157
|
||||
# semi-sync replication crashes when replicating a transaction which
|
||||
@@ -133,6 +133,7 @@ SET SESSION AUTOCOMMIT= 1;
|
||||
#
|
||||
include/stop_slave.inc
|
||||
[ on master ]
|
||||
set global rpl_semi_sync_master_timeout= 5000;
|
||||
[ master status should be ON ]
|
||||
show status like 'Rpl_semi_sync_master_status';
|
||||
Variable_name Value
|
||||
@@ -142,7 +143,7 @@ Variable_name Value
|
||||
Rpl_semi_sync_master_no_tx 0
|
||||
show status like 'Rpl_semi_sync_master_yes_tx';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_yes_tx 304
|
||||
Rpl_semi_sync_master_yes_tx 14
|
||||
show status like 'Rpl_semi_sync_master_clients';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_clients 1
|
||||
@@ -157,7 +158,7 @@ Variable_name Value
|
||||
Rpl_semi_sync_master_no_tx 1
|
||||
show status like 'Rpl_semi_sync_master_yes_tx';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_yes_tx 304
|
||||
Rpl_semi_sync_master_yes_tx 14
|
||||
insert into t1 values (100);
|
||||
[ master status should be OFF ]
|
||||
show status like 'Rpl_semi_sync_master_status';
|
||||
@@ -165,10 +166,10 @@ Variable_name Value
|
||||
Rpl_semi_sync_master_status OFF
|
||||
show status like 'Rpl_semi_sync_master_no_tx';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_no_tx 302
|
||||
Rpl_semi_sync_master_no_tx 12
|
||||
show status like 'Rpl_semi_sync_master_yes_tx';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_yes_tx 304
|
||||
Rpl_semi_sync_master_yes_tx 14
|
||||
#
|
||||
# Test semi-sync status on master will be ON again when slave catches up
|
||||
#
|
||||
@@ -198,10 +199,10 @@ Variable_name Value
|
||||
Rpl_semi_sync_master_status ON
|
||||
show status like 'Rpl_semi_sync_master_no_tx';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_no_tx 302
|
||||
Rpl_semi_sync_master_no_tx 12
|
||||
show status like 'Rpl_semi_sync_master_yes_tx';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_yes_tx 304
|
||||
Rpl_semi_sync_master_yes_tx 14
|
||||
show status like 'Rpl_semi_sync_master_clients';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_clients 1
|
||||
@@ -217,10 +218,10 @@ include/stop_slave.inc
|
||||
[ Semi-sync master status variables before FLUSH STATUS ]
|
||||
SHOW STATUS LIKE 'Rpl_semi_sync_master_no_tx';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_no_tx 302
|
||||
Rpl_semi_sync_master_no_tx 12
|
||||
SHOW STATUS LIKE 'Rpl_semi_sync_master_yes_tx';
|
||||
Variable_name Value
|
||||
Rpl_semi_sync_master_yes_tx 305
|
||||
Rpl_semi_sync_master_yes_tx 15
|
||||
FLUSH NO_WRITE_TO_BINLOG STATUS;
|
||||
[ Semi-sync master status variables after FLUSH STATUS ]
|
||||
SHOW STATUS LIKE 'Rpl_semi_sync_master_no_tx';
|
||||
|
@@ -67,7 +67,7 @@ if ($value == No such row)
|
||||
{
|
||||
set sql_log_bin=0;
|
||||
eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_SO';
|
||||
set global rpl_semi_sync_master_timeout= 5000; /* 5s */
|
||||
set global rpl_semi_sync_master_timeout= 60000; /* 60s */
|
||||
set sql_log_bin=1;
|
||||
}
|
||||
enable_query_log;
|
||||
@@ -173,7 +173,7 @@ let $_connections_semisync_slave= query_get_value(SHOW STATUS LIKE 'Threads_conn
|
||||
replace_result $_connections_normal_slave CONNECTIONS_NORMAL_SLAVE $_connections_semisync_slave CONNECTIONS_SEMISYNC_SLAVE;
|
||||
eval select $_connections_semisync_slave - $_connections_normal_slave as 'Should be 0';
|
||||
|
||||
let $i=300;
|
||||
let $i=10;
|
||||
echo [ insert records to table ];
|
||||
disable_query_log;
|
||||
while ($i)
|
||||
@@ -237,6 +237,7 @@ source include/stop_slave.inc;
|
||||
|
||||
connection master;
|
||||
echo [ on master ];
|
||||
set global rpl_semi_sync_master_timeout= 5000;
|
||||
|
||||
# The first semi-sync check should be on because after slave stop,
|
||||
# there are no transactions on the master.
|
||||
@@ -263,7 +264,7 @@ show status like 'Rpl_semi_sync_master_yes_tx';
|
||||
|
||||
# Semi-sync status on master is now OFF, so all these transactions
|
||||
# will be replicated asynchronously.
|
||||
let $i=300;
|
||||
let $i=10;
|
||||
disable_query_log;
|
||||
while ($i)
|
||||
{
|
||||
|
@@ -174,21 +174,35 @@ GRANT PROXY ON ''@'' TO grant_plug;
|
||||
--error ER_ACCESS_DENIED_NO_PASSWORD_ERROR
|
||||
GRANT PROXY ON grant_plug TO grant_plug_dest;
|
||||
|
||||
--echo this should fail : same user, but on a different host
|
||||
--error ER_ACCESS_DENIED_NO_PASSWORD_ERROR
|
||||
# Security context in THD contains two pairs of (user,host)
|
||||
# 1. (user,host) pair referring to inbound connection
|
||||
# 2. (priv_user,priv_host) pair obtained from mysql.user table after doing
|
||||
# authnetication of incoming connection.
|
||||
# Granting/revoking proxy privileges, privileges should be checked wrt
|
||||
# (priv_user, priv_host) tuple that is obtained from mysql.user table
|
||||
# Following is a valid grant because effective user of connection is
|
||||
# grant_plug_dest@% and statement is trying to grant proxy on the same
|
||||
# user.
|
||||
--echo This is a valid grant
|
||||
GRANT PROXY ON grant_plug_dest TO grant_plug;
|
||||
REVOKE PROXY ON grant_plug_dest FROM grant_plug;
|
||||
|
||||
--echo this should work : same user
|
||||
GRANT PROXY ON grant_plug_dest@localhost TO grant_plug_dest2;
|
||||
REVOKE PROXY ON grant_plug_dest@localhost FROM grant_plug_dest2;
|
||||
GRANT PROXY ON grant_plug_dest TO grant_plug_dest2;
|
||||
REVOKE PROXY ON grant_plug_dest FROM grant_plug_dest2;
|
||||
|
||||
--echo this should work : same user
|
||||
# grant_plug_dest@localhost is not the same as grant_plug_dest@%
|
||||
# so following grant/revoke should fail
|
||||
--echo this should fail : not the same user
|
||||
--error ER_ACCESS_DENIED_NO_PASSWORD_ERROR
|
||||
GRANT PROXY ON grant_plug_dest@localhost TO grant_plug WITH GRANT OPTION;
|
||||
--echo this should fail : not the same user
|
||||
--error ER_ACCESS_DENIED_NO_PASSWORD_ERROR
|
||||
REVOKE PROXY ON grant_plug_dest@localhost FROM grant_plug;
|
||||
|
||||
--echo this should fail : can't create users
|
||||
--error ER_CANT_CREATE_USER_WITH_GRANT
|
||||
GRANT PROXY ON grant_plug_dest@localhost TO grant_plug@localhost;
|
||||
GRANT PROXY ON grant_plug_dest TO grant_plug@localhost;
|
||||
|
||||
connection default;
|
||||
--echo in default connection
|
||||
|
@@ -1371,3 +1371,17 @@ SELECT RELEASE_LOCK('t');
|
||||
--connection default
|
||||
SET NAMES latin1;
|
||||
|
||||
|
||||
--echo #
|
||||
--echo # WL#6454: Deprecate SHOW AUTHORS and SHOW CONTRIBUTORS
|
||||
--echo #
|
||||
|
||||
--disable_result_log
|
||||
SHOW AUTHORS;
|
||||
--enable_result_log
|
||||
SHOW WARNINGS;
|
||||
|
||||
--disable_result_log
|
||||
SHOW CONTRIBUTORS;
|
||||
--enable_result_log
|
||||
SHOW WARNINGS;
|
||||
|
@@ -429,14 +429,6 @@ disconnect addcon;
|
||||
DROP DATABASE `my.db`;
|
||||
USE test;
|
||||
|
||||
#
|
||||
# Restore global concurrent_insert value. Keep in the end of the test file.
|
||||
#
|
||||
|
||||
set @@global.concurrent_insert= @old_concurrent_insert;
|
||||
|
||||
# Wait till all disconnects are completed
|
||||
--source include/wait_until_count_sessions.inc
|
||||
|
||||
--echo #
|
||||
--echo # Bug#11763507 - 56224: FUNCTION NAME IS CASE-SENSITIVE
|
||||
|
Reference in New Issue
Block a user