这个MySQL安装已经升级到5.7.40,如果你仍然需要运行mysql_upgrade,使用——force错误处理包mysql-server-5.7(——configure)安装mysql-server-5.7包后安装脚本子进程返回错误退出状态1处理时遇到错误:mysql -服务器- 5.7E:子进程/usr/bin/dpkg返回错误码(1)
我该怎么做??
我尝试了这些cmd,仍然出现错误:
sudo apt-get cleanSudo apt-get purge mysql*Sudo apt-get updateSudo apt-get install -f安装mysql-server-5.7Sudo apt-get dist-upgrade
试试这样做。
sudo service mysql stop
sudo apt-get --purge remove mysql*
sudo rm -rf /etc/mysql/
Then I reinstalled it:
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install mariadb-server
sudo service mysql start
sudo mysql -u root -p
secret
sudo mysql -u root -p
GRANT ALL PRIVILEGES on *.* to 'root'@'localhost' IDENTIFIED BY '<password>';
FLUSH PRIVILEGES;