打開網站的時候報錯:mysql
[1045] Access denied for user 'root'@'localhost' (using password: YES)sql
解決方案:網站
systemctl stop mariadb.service #中止MariaDBui
[root@localhost ~]# mysql
mysql>use mysql
mysql>update user set password=password("123456") where user="root";
mysql>flush privileges;spa
mysql>quit;.net
而後啓動:systemctl start mariadbget