L(A/N)MP 中遇到的MySQL的坑

1.登陸phpmyadmin 帳號密碼正確,提示以上錯誤信息。php

    phpMyAdmin - 錯誤mysql

    配置文件權限錯誤,不該任何用戶都能修改!sql

解決方法:查看了一下phpmyadmin 權限是777 .spa

phpmyadmin必須在755權限下才能夠運行。
chmod -cR 755 phpMyAdmin (解決)rest

-------------------------------------分割線-----------------------------------------code

發現CentOS7開關防火牆的命令service iptables save報錯,使用原始命令開關:ip

systemctl stop firewalld
systemctl mask firewalld

Then, install the iptables-services package:it

yum install iptables-services

Enable the service at boot-time:table

systemctl enable iptables

Managing the service登錄

systemctl [stop|start|restart] iptables

Saving your firewall rules can be done as follows:

service iptables save

or

/usr/libexec/iptables/iptables.init save

也能夠安裝的方式。

 

------------------------------------分割線----------------------------------------------------

use mysql

GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'mysql' WITH GRANT OPTION;

flush privileges;

設置mysql遠程登陸,上面第二句是:設置root用戶任何主機均可以登陸並使用「mysql」的密碼登陸。

 

------------------------------------分割線----------------------------------------------------

相關文章
相關標籤/搜索