Debian Codegraph @

mysql-test/suite/ndb/t/stored_grants_drop_user.test

raw
1 # Bug#34183149 Inconsistent DROP USER Outcome in Distributed Privileges
2
3 --source include/have_ndb.inc
4 --echo server 1:
5 CREATE USER 'albus'@'%' IDENTIFIED BY 'xrm0Baa';
6 GRANT SELECT, INSERT,UPDATE,DELETE,CREATE,REFERENCES,INDEX,ALTER,CREATE VIEW
7 ON *.* TO 'albus'@'%';
8 GRANT NDB_STORED_USER ON *.* TO 'albus'@'%';
9
10 # User has been created and distributed.
11 # Switch to a different mysql server and drop the user.
12
13 connect(mysqld2,127.0.0.1,root,,test,$MASTER_MYPORT1);
14
15 --echo server 2:
16 SELECT user FROM mysql.user WHERE user = "albus";
17 DROP USER 'albus'@'%';
18 SELECT user FROM mysql.user WHERE user = "albus";
19
20
21 # SELECT from original node showed the user still existing!
22 connection default;
23 --echo server 1:
24 SELECT user FROM mysql.user WHERE user = "albus";
25
26 # No cleanup. The user has already been dropped globally.