diff --git a/test/initial_sharding_multi.py b/test/initial_sharding_multi.py index a8b8c243152..998864e3f67 100755 --- a/test/initial_sharding_multi.py +++ b/test/initial_sharding_multi.py @@ -121,21 +121,15 @@ def setUpModule(): fd.write(init_db) fd.write(''' # Set real passwords for all users. +ALTER USER 'root'@'localhost' IDENTIFIED BY 'RootPass'; +ALTER USER 'vt_dba'@'localhost' IDENTIFIED BY 'VtDbaPass'; +ALTER USER 'vt_app'@'localhost' IDENTIFIED BY 'VtAppPass'; +ALTER USER 'vt_allprivs'@'localhost' IDENTIFIED BY 'VtAllPrivsPass'; +ALTER USER 'vt_repl'@'%' IDENTIFIED BY 'VtReplPass'; +ALTER USER 'vt_filtered'@'localhost' IDENTIFIED BY 'VtFilteredPass'; + # connecting through a port requires 127.0.0.1 # --host=localhost will connect through socket -UPDATE mysql.user SET %s = PASSWORD('RootPass') - WHERE User = 'root' AND Host = 'localhost'; -UPDATE mysql.user SET %s = PASSWORD('VtDbaPass') - WHERE User = 'vt_dba' AND Host = 'localhost'; -UPDATE mysql.user SET %s = PASSWORD('VtAppPass') - WHERE User = 'vt_app' AND Host = 'localhost'; -UPDATE mysql.user SET %s = PASSWORD('VtAllprivsPass') - WHERE User = 'vt_allprivs' AND Host = 'localhost'; -UPDATE mysql.user SET %s = PASSWORD('VtReplPass') - WHERE User = 'vt_repl' AND Host = '%%'; -UPDATE mysql.user SET %s = PASSWORD('VtFilteredPass') - WHERE User = 'vt_filtered' AND Host = 'localhost'; - CREATE USER 'vt_dba'@'127.0.0.1' IDENTIFIED BY 'VtDbaPass'; GRANT ALL ON *.* TO 'vt_dba'@'127.0.0.1'; GRANT GRANT OPTION ON *.* TO 'vt_dba'@'127.0.0.1'; @@ -167,7 +161,7 @@ def setUpModule(): ON *.* TO 'vt_filtered'@'127.0.0.1'; FLUSH PRIVILEGES; -''' % tuple([password_col] * 6)) +''') credentials = { 'vt_dba': ['VtDbaPass'], 'vt_app': ['VtAppPass'],