1. 安装
sudo apt-get update
sudo apt-get install apache2
sudo apt-get install mariadb-server-10.0
sudo apt-get install php php-mysql
2. 在浏览器(我用的火狐… .可)输入树莓派ip,得到
3. 改密码
sudo mysql
use mysql;
UPDATE user SET password=password('MYSQL') WHERE user='root';
UPDATE user SET plugin='mysql_native_password' WHERE user = 'root';
flush privileges;
exit
4. 重启mysql服务
sudo systemctl restart mysql
mysql -u root -p