編集する

編集する

Hortonworks HDPにMySQLとMySQL Community Serverをインストールしました。サービスを開始してパスワードを変更してみました。

/usr/bin/mysql_secure_installation

Securing the MySQL server deployment.

Connecting to MySQL using a blank password.
The 'validate_password' plugin is installed on the server.
The subsequent steps will run with the existing configuration
of the plugin.
Please set the password for root here.

New password: 

Re-enter new password: 

Estimated strength of the password: 50 
Do you wish to continue with the password provided?(Press y|Y for Yes, any other key for No) : y
 ... Failed! Error: The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement

そしてその過程は継続して繰り返されます。

skip=grant-tables私のファイルから/etc/my.conf削除しました

Bartの提案を試してみましたが、最初はうまくいきましたが、同じ問題が発生しました。

I logged as a root.
mysql> create database registry;
Query OK, 1 row affected (0.05 sec)

mysql> CREATE USER 'registry'@'%' IDENTIFIED BY 'R12$%34qw';
ERROR 1290 (HY000): The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement

この問題をどのように解決しますか?

ベストアンサー1

MySQLを正常に停止して再起動するだけです。

編集する

それ以外の場合:

権限を更新します。

GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' WITH GRANT OPTION;
FLUSH PRIVILEGES;

~から文書:

フラッシュ権限

mysqlデータベースの付与テーブルから権限を再ロードします。

サーバーは GRANT および CREATE USER ステートメントの結果として情報をメモリーにキャッシュします。このメモリーは、対応する REVOKE ステートメントと DROP USER ステートメントによって解放されないため、キャッシュを引き起こすステートメント・インスタンスを多数実行しているサーバーでは、メモリー使用量が増加します。このキャッシュメモリはFLUSH PRIVILEGESを使用して解放できます。

おすすめ記事