Server IP : 185.86.78.101 / Your IP : 216.73.216.213 Web Server : Apache System : Linux 675867-vds-valikoshka1996.gmhost.pp.ua 5.4.0-150-generic #167-Ubuntu SMP Mon May 15 17:35:05 UTC 2023 x86_64 User : www ( 1000) PHP Version : 7.4.33 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /www/server/mysql/mysql-test/r/ |
Upload File : |
call mtr.add_suppression('Corresponding entry in binary log used default authentication.*'); DELETE FROM mysql.user WHERE user = 'wl8540'; FLUSH PRIVILEGES; SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 0 CREATE USER wl8540@host1; SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 1 CREATE USER wl8540@host1; ERROR HY000: Operation CREATE USER failed for 'wl8540'@'host1' CREATE USER IF NOT EXISTS wl8540@host1; Warnings: Note 3163 User 'wl8540'@'host1' already exists. SHOW WARNINGS; Level Code Message Note 3163 User 'wl8540'@'host1' already exists. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 1 CREATE USER IF NOT EXISTS wl8540@host1, wl8540@host2; Warnings: Note 3163 User 'wl8540'@'host1' already exists. SHOW WARNINGS; Level Code Message Note 3163 User 'wl8540'@'host1' already exists. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 2 CREATE USER IF NOT EXISTS wl8540@host1, wl8540@host2; Warnings: Note 3163 User 'wl8540'@'host1' already exists. Note 3163 User 'wl8540'@'host2' already exists. SHOW WARNINGS; Level Code Message Note 3163 User 'wl8540'@'host1' already exists. Note 3163 User 'wl8540'@'host2' already exists. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 2 SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540' AND account_locked = 'Y'; COUNT(*) 0 ALTER USER wl8540@host3 ACCOUNT LOCK; ERROR HY000: Operation ALTER USER failed for 'wl8540'@'host3' SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540' AND account_locked = 'Y'; COUNT(*) 0 ALTER USER IF EXISTS wl8540@host3, wl8540@host4, wl8540@host1 ACCOUNT LOCK; Warnings: Note 3162 User 'wl8540'@'host3' does not exist. Note 3162 User 'wl8540'@'host4' does not exist. SHOW WARNINGS; Level Code Message Note 3162 User 'wl8540'@'host3' does not exist. Note 3162 User 'wl8540'@'host4' does not exist. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540' AND account_locked = 'Y'; COUNT(*) 1 ALTER USER IF EXISTS wl8540@host2 ACCOUNT LOCK; SHOW WARNINGS; Level Code Message SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540' AND account_locked = 'Y'; COUNT(*) 2 SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 2 DROP USER wl8540@host3; ERROR HY000: Operation DROP USER failed for 'wl8540'@'host3' SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 2 DROP USER IF EXISTS wl8540@host3; Warnings: Note 3162 User 'wl8540'@'host3' does not exist. SHOW WARNINGS; Level Code Message Note 3162 User 'wl8540'@'host3' does not exist. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 2 DROP USER IF EXISTS wl8540@host3,wl8540@host2,wl8540@host4; Warnings: Note 3162 User 'wl8540'@'host3' does not exist. Note 3162 User 'wl8540'@'host4' does not exist. SHOW WARNINGS; Level Code Message Note 3162 User 'wl8540'@'host3' does not exist. Note 3162 User 'wl8540'@'host4' does not exist. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 1 DROP USER IF EXISTS wl8540@nohost1, wl8540@nohost2; Warnings: Note 3162 User 'wl8540'@'nohost1' does not exist. Note 3162 User 'wl8540'@'nohost2' does not exist. SHOW WARNINGS; Level Code Message Note 3162 User 'wl8540'@'nohost1' does not exist. Note 3162 User 'wl8540'@'nohost2' does not exist. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 1 ALTER USER IF EXISTS wl8540@nohost1, wl8540@nohost2 ACCOUNT LOCK; Warnings: Note 3162 User 'wl8540'@'nohost1' does not exist. Note 3162 User 'wl8540'@'nohost2' does not exist. SHOW WARNINGS; Level Code Message Note 3162 User 'wl8540'@'nohost1' does not exist. Note 3162 User 'wl8540'@'nohost2' does not exist. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 1 CREATE USER IF NOT EXISTS wl8540@nohost1, wl8540@nohost2; SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 3 ALTER USER IF EXISTS wl8540@nohost1, wl8540@nohost2 ACCOUNT LOCK; SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 3 CREATE USER IF NOT EXISTS wl8540@nohost1, wl8540@nohost2; Warnings: Note 3163 User 'wl8540'@'nohost1' already exists. Note 3163 User 'wl8540'@'nohost2' already exists. SHOW WARNINGS; Level Code Message Note 3163 User 'wl8540'@'nohost1' already exists. Note 3163 User 'wl8540'@'nohost2' already exists. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 3 DROP USER IF EXISTS wl8540@nohost1, wl8540@nohost2; SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 1 CREATE USER wl8540@nohost1; DROP USER IF EXISTS wl8540@nohost1, wl8540@nohost2; Warnings: Note 3162 User 'wl8540'@'nohost2' does not exist. SHOW WARNINGS; Level Code Message Note 3162 User 'wl8540'@'nohost2' does not exist. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 1 ALTER USER IF EXISTS wl8540@nohost1, wl8540@nohost2 ACCOUNT LOCK; Warnings: Note 3162 User 'wl8540'@'nohost1' does not exist. Note 3162 User 'wl8540'@'nohost2' does not exist. SHOW WARNINGS; Level Code Message Note 3162 User 'wl8540'@'nohost1' does not exist. Note 3162 User 'wl8540'@'nohost2' does not exist. SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 1 CREATE USER IF NOT EXISTS wl8540@nohost1, wl8540@nohost2; SHOW WARNINGS; Level Code Message SELECT COUNT(*) FROM mysql.user WHERE user = 'wl8540'; COUNT(*) 3 # Search warnings in the server log DELETE FROM mysql.user WHERE user = 'wl8540'; FLUSH PRIVILEGES; CREATE USER user1@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string#%y'; CREATE USER IF NOT EXISTS user2@localhost IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF'; SELECT User,plugin,authentication_string,ssl_type, password_expired,password_lifetime FROM mysql.user WHERE USER='user2'; User user2 plugin mysql_native_password authentication_string *67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF ssl_type password_expired N password_lifetime NULL CREATE USER IF NOT EXISTS user2@localhost IDENTIFIED WITH 'sha256_password'; Warnings: Note 3163 User 'user2'@'localhost' already exists. SELECT User,plugin,authentication_string,ssl_type, password_expired,password_lifetime FROM mysql.user WHERE USER='user2'; User user2 plugin mysql_native_password authentication_string *67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF ssl_type password_expired N password_lifetime NULL ALTER USER IF EXISTS user2@localhost IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF'; SELECT User,plugin,authentication_string,ssl_type, password_expired,password_lifetime FROM mysql.user WHERE USER='user2'; User user2 plugin mysql_native_password authentication_string *67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF ssl_type password_expired N password_lifetime NULL CREATE USER IF NOT EXISTS user1@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string#%y'; Warnings: Note 3163 User 'user1'@'localhost' already exists. CREATE USER IF NOT EXISTS ne_user1@localhost,user1@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; Warnings: Note 3163 User 'user1'@'localhost' already exists. ALTER USER IF EXISTS ne_user2@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string#%y'; Warnings: Note 3162 User 'ne_user2'@'localhost' does not exist. ALTER USER IF EXISTS user1@localhost,ne_user3@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string#%y'; Warnings: Note 3162 User 'ne_user3'@'localhost' does not exist. DROP USER IF EXISTS user1@localhost,user2@localhost,ne_user1@localhost, ne_user2@localhost,ne_user3@localhost; Warnings: Note 3162 User 'ne_user2'@'localhost' does not exist. Note 3162 User 'ne_user3'@'localhost' does not exist. # Restarting the server with --log-row ON # Restart server. CREATE USER user1@localhost IDENTIFIED WITH 'mysql_native_password'; CREATE USER IF NOT EXISTS user2@localhost IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF'; CREATE USER IF NOT EXISTS user1@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string#%y'; Warnings: Note 3163 User 'user1'@'localhost' already exists. CREATE USER IF NOT EXISTS ne_user1@localhost,user1@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; Warnings: Note 3163 User 'user1'@'localhost' already exists. ALTER USER IF EXISTS ne_user2@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string#%y'; Warnings: Note 3162 User 'ne_user2'@'localhost' does not exist. ALTER USER IF EXISTS user1@localhost,ne_user3@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string#%y'; Warnings: Note 3162 User 'ne_user3'@'localhost' does not exist. DROP USER IF EXISTS user1@localhost,user2@localhost,ne_user1@localhost, ne_user2@localhost,ne_user3@localhost; Warnings: Note 3162 User 'ne_user2'@'localhost' does not exist. Note 3162 User 'ne_user3'@'localhost' does not exist. # # Bug #21807286: "CREATE USER IF NOT EXISTS" REPORTS AN ERROR # CREATE USER IF NOT EXISTS b21807286@localhost IDENTIFIED BY 'xyz'; # Must not fail but return a warning CREATE USER IF NOT EXISTS b21807286@localhost IDENTIFIED BY 'xyz'; Warnings: Note 3163 User 'b21807286'@'localhost' already exists. DROP USER b21807286@localhost; # Must not fail but return a warning ALTER USER IF EXISTS b21807286@localhost IDENTIFIED BY 'xyz'; Warnings: Note 3162 User 'b21807286'@'localhost' does not exist. # Search warnings in the server log # End of 5.7 tests