安裝mysql時的一些問題 問題如下: /usr/bin/mysql_secure_installation NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQL SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY! In order to log into MySQL to secure it, we'll need the current password for the root user. If you've just installed MySQL, and you haven't set the root password yet, the password will be blank, so you should just press enter here. Enter current password for root (enter for none): ERROR 1820 (HY000): You must SET PASSWORD before executing this statement 解決辦法: 登陸mysql 如果無法登陸mysql 可以在my.cnf中增加skip-grant-tables;跳過驗證,登陸mysql後重新設置一下密碼 set password=password('123456'); 然後運行 /usr/bin/mysql_secure_installation 進行安全設置就可以了 搞定收工