File: innodb_bug11933790.test

package info (click to toggle)
percona-xtrabackup 2.2.3-2.1
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 293,260 kB
  • ctags: 146,881
  • sloc: cpp: 1,051,960; ansic: 570,217; java: 54,595; perl: 53,495; pascal: 44,194; sh: 27,826; yacc: 15,314; python: 12,142; xml: 7,848; sql: 4,125; makefile: 1,459; awk: 785; lex: 758
file content (42 lines) | stat: -rw-r--r-- 969 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#
# Bug 11933790 - INNODB ASSERTS TRX->IN_MYSQL_TRX_LIST IN ANALYZE WITH
# PERSISTENT STATS
#

-- source include/have_innodb.inc

call mtr.add_suppression("InnoDB: Error while trying to save table statistics for table .+bug11933790.*: Lock wait timeout");

# we are only interested that the below commands do not crash the server
-- disable_query_log
-- disable_result_log

CREATE TABLE bug11933790 (c INT) ENGINE=INNODB STATS_PERSISTENT=1;

# add some records to mysql.innodb_table_stats
ANALYZE TABLE bug11933790;

SET autocommit=0;

# lock the records in mysql.innodb_table_stats
SELECT * FROM mysql.innodb_table_stats FOR UPDATE;

-- connect (con1,localhost,root,,)

-- connection con1

# this will fail with lock wait timeout; if the bug is present then mysqld
# crashes here
-- enable_query_log
-- enable_result_log
ANALYZE TABLE bug11933790;
-- disable_query_log
-- disable_result_log

-- connection default

-- disconnect con1

COMMIT;

DROP TABLE bug11933790;