您好,登錄后才能下訂單哦!
Mysql修改密碼的方式
如果忘記密碼--skip-grant-tables
1、alter user
alter user test@'localhost' identified by 'xxxx!';
2、grant
show grants for test@'localhost'; GRANT USAGE ON *.* TO 'test'@'localhost' IDENTIFIED BY PASSWORD '*xxxxxxxxxxxxx';
GRANT USAGE ON *.* TO 'test'@'localhost' IDENTIFIED BY 'xxxxxxxxxxxxx';
3、set password
set password for test@'localhost'=password('xxx')
4、update mysql.user
mysql> UPDATE mysql.user SET Password = PASSWORD('newpass') WHERE user = 'test' and host='localhost'; mysql> FLUSH PRIVILEGES;
5、mysqladmin
mysqladmin -u test password "newpass" #第一次設置 mysqladmin -u test password oldpass "newpass" #如果root已經設置過密碼,采用如下方法
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。