File: ibuf_sys_tablespace_extend.result

package info (click to toggle)
mysql-8.0 8.0.43-3
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,273,924 kB
  • sloc: cpp: 4,684,605; ansic: 412,450; pascal: 108,398; java: 83,641; perl: 30,221; cs: 27,067; sql: 26,594; sh: 24,181; python: 21,816; yacc: 17,169; php: 11,522; xml: 7,388; javascript: 7,076; makefile: 2,194; lex: 1,075; awk: 670; asm: 520; objc: 183; ruby: 97; lisp: 86
file content (84 lines) | stat: -rw-r--r-- 2,658 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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
# Initialize new data directory...
# Restart on the new data directory...
# restart: --datadir=tmp/test_data_dir --log-error=my_restart.err --log_error_verbosity=2
SET GLOBAL innodb_redo_log_capacity=52428800;
SET GLOBAL innodb_change_buffering=all;
SET GLOBAL innodb_change_buffer_max_size=50;
SET GLOBAL innodb_change_buffering_debug = 1;
SET GLOBAL innodb_disable_background_merge=ON;
SET GLOBAL DEBUG='+d,ib_redo_log_system_tablespace_expansion';
CREATE DATABASE db1;
# Create 2 tables
CALL db1.CreateNTables('db1', 't', 2);

# Create Connection objects

# Insert record in each table
INSERT INTO db1.t1
VALUES(0, 1000 , 1, REPEAT('a', 2048), REPEAT('b', 2048));
INSERT INTO db1.t2
VALUES(0, 1000 , 1, REPEAT('a', 2048), REPEAT('b', 2048));
# Wait for inserts to finish

# Insert total 2^8 records in each table
CALL db1.InsertIntoRecords('db1', 't1', 8);
CALL db1.InsertIntoRecords('db1', 't2', 8);

# Wait for insert into tables to finish
# Disable page cleaner to have redo logs for recovery later on
SET GLOBAL innodb_dict_stats_disabled_debug = 1;
SET GLOBAL innodb_master_thread_disabled_debug = 1;
SET GLOBAL debug = "+d,disable_se_persists_gtid";
FLUSH ENGINE LOGS;
SET GLOBAL debug = "+d,gtid_persist_flush_disable";
SET GLOBAL innodb_log_checkpoint_now = 1;
SET GLOBAL innodb_page_cleaner_disabled_debug = 1;
SET GLOBAL innodb_checkpoint_disabled = 1;
SET GLOBAL innodb_purge_stop_now = 1;
UPDATE db1.t1
SET k = id + k , nk = k + id, c = REPEAT('a2', 512),
pad = REPEAT('b2', 512)
WHERE id % 2 = 0;
UPDATE db1.t2
SET k = id + k , nk = k + id, c = REPEAT('a2', 512),
pad = REPEAT('b2', 512)
WHERE id % 2 = 0;

# Wait for Updates to finish
UPDATE db1.t1
SET k = id + k , nk = k + id, c = REPEAT('a3', 512),
pad = REPEAT('b3', 512)
WHERE id % 3 = 0;
UPDATE db1.t2
SET k = id + k , nk = k + id, c = REPEAT('a3', 512),
pad = REPEAT('b3', 512)
WHERE id % 3 = 0;

# Wait for Updates to finish
UPDATE db1.t1
SET k = id + k , nk = k + id, c = REPEAT('a5', 512),
pad = REPEAT('b5', 512)
WHERE id % 5 = 0;
UPDATE db1.t2
SET k = id + k , nk = k + id, c = REPEAT('a5', 512),
pad = REPEAT('b5', 512)
WHERE id % 5 = 0;

# Wait for Updates to finish

# Delete records
DELETE FROM db1.t1 WHERE id % 4 = 1 ORDER BY id;
DELETE FROM db1.t2 WHERE id % 4 = 1 ORDER BY id;

# Wait for Deletes to finish #1
Pattern "System tablespace expansion is redo logged" found
SET GLOBAL DEBUG='-d,ib_redo_log_system_tablespace_expansion';
# Verify no issues observed during crash recovery
# Kill and restart: --datadir=tmp/test_data_dir --log-error=my_restart.err --log_error_verbosity=2
SELECT id, k FROM db1.t1 ORDER BY id LIMIT 1;
id	k
2	2002

# Cleanup

# Kill and restart: