Debian Codegraph @

mysql-test/suite/rpl/r/rpl_priv_checks_user_slave_extra_columns.result

raw
1 #
2 # TC.1) Check column level privilege checking with an extra column on the
3 # slave
4 #
5 #
6 # 1) Set applier privilege checks.
7 #
8 include/master-slave.inc
9 Warnings:
10 Note #### Sending passwords in plain text without SSL/TLS is extremely insecure.
11 Note #### Storing MySQL user name or password information in the connection metadata repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START REPLICA; see the 'START REPLICA Syntax' in the MySQL Manual for more information.
12 [connection master]
13 #
14 # 2) Set `binlog_row_image` to `MINIMAL`.
15 #
16 SET @@global.binlog_row_image = MINIMAL;
17 SET @@session.binlog_row_image = MINIMAL;
18 #
19 # 3) Create a table on the master.
20 #
21 CREATE TABLE test.t1 (a INT);
22 include/sync_slave_sql_with_master.inc
23 #
24 # 4) Add an extra column on the slave.
25 #
26 ALTER TABLE test.t1 ADD COLUMN b INT;
27 include/stop_slave.inc
28 include/start_slave.inc
29 #
30 # 5) Make a DDL change on the master.
31 #
32 INSERT INTO test.t1 VALUES (1);
33 include/sync_slave_sql_with_master.inc
34 #
35 # 6) Check tables have the same data on master and slave.
36 #
37 include/diff_tables.inc [master:t1,slave:t1]
38 #
39 # TC.2) Check column level privilege checking with a column short on the
40 # slave
41 #
42 #
43 # 1) Create a table on the master with two or more columns.
44 #
45 CREATE TABLE test.t2 (a INT, b INT, c VARCHAR(50));
46 include/sync_slave_sql_with_master.inc
47 #
48 # 2) Remove the table last column on the slave.
49 #
50 ALTER TABLE test.t2 DROP COLUMN c;
51 include/stop_slave.inc
52 include/start_slave.inc
53 #
54 # 3) Make a DDL change on the master.
55 #
56 INSERT INTO test.t2 VALUES (1,1,"a string of characters");
57 include/sync_slave_sql_with_master.inc
58 #
59 # 4) Check tables have the same data on master and slave.
60 #
61 include/diff_tables.inc [master:t2,slave:t2]
62 SET @@global.binlog_row_image = GLOBAL_BINLOG_ROW_IMAGE;
63 SET @@session.binlog_row_image = SESSION_BINLOG_ROW_IMAGE;
64 DROP TABLE t1;
65 DROP TABLE t2;
66 include/rpl_end.inc