Yanor.net/
Wiki
Blog
GitHub
Sandbox
開始行:
* rootユーザのパスワードをリセットする [#jb674727]
** 手順 [#s08a29e6]
- mysqldを停止する。
- mysqldを以下のようにオプション指定して起動する。(する...
shell> mysqld_safe --skip-grant-tables
- パスワードを設定する。
-- MySQL5.6まで
mysql> UPDATE mysql.user SET Password=PASSWORD('my_new_p...
mysql> FLUSH PRIVILEGES;
-- MySQL5.7以降
mysql> UPDATE mysql.user SET authentication_string=passw...
-- MySQL8
mysql> update user set authentication_string='new_my_pas...
- mysqldを停止する。
- mysqldを通常起動する。
** 上で上手く行かない場合 [#t120c844]
mysql> UPDATE user SET authentication_string=null WHERE ...
mysql> ALTER USER 'root'@'localhost' identified BY 'new_...
** 参考 [#ga96de6e]
http://dev.mysql.com/doc/refman/5.6/en/resetting-permissi...
終了行:
* rootユーザのパスワードをリセットする [#jb674727]
** 手順 [#s08a29e6]
- mysqldを停止する。
- mysqldを以下のようにオプション指定して起動する。(する...
shell> mysqld_safe --skip-grant-tables
- パスワードを設定する。
-- MySQL5.6まで
mysql> UPDATE mysql.user SET Password=PASSWORD('my_new_p...
mysql> FLUSH PRIVILEGES;
-- MySQL5.7以降
mysql> UPDATE mysql.user SET authentication_string=passw...
-- MySQL8
mysql> update user set authentication_string='new_my_pas...
- mysqldを停止する。
- mysqldを通常起動する。
** 上で上手く行かない場合 [#t120c844]
mysql> UPDATE user SET authentication_string=null WHERE ...
mysql> ALTER USER 'root'@'localhost' identified BY 'new_...
** 参考 [#ga96de6e]
http://dev.mysql.com/doc/refman/5.6/en/resetting-permissi...
ページ名: