使用mysql-server更新到ubuntu17.04失败,并带有initscripts依赖项


1

安装一些对ubuntu17.04的更新并使用删除mysql-server之后autoremove,我遇到此错误:

mysql-server-5.7 : 依赖(dependent): initscripts 但无法安装它(but can't install it)
sudo apt install initscripts
# 没有可用的软件包 initscripts,但是它被其它的软件包引用了
# 这可能意味着这个缺失的软件包可能已被废弃,
# 或者只能在其他发布源中找到
# no valid package initscripts,but it referred by other package
# this means it may be abandoned, or can be found in other repo
# replaced by following
# sysvinit-utils util-linux:i386 sysvinit-utils:i386 util-linux

sudo apt install mysql-server-5.7。我已经尝试了16-04-upgrade-broke-mysql-server,但是仍然无法解决上述问题!

Answers:


1

这可以通过使用MySQL APT存储库进行更新来解决

sudo dpkg -i mysql-apt-config_0.8.7-1_all.deb
sudo apt update

并选择5.7 OK

  1. 备份configure filedatabases
  2. sudo rm /etc/alternatives/my.cnf /etc/mysql -fr
  3. sudo rm /var/lib/mysql/* -fr
  4. sudo apt remove mysql-server mysql-client mysql-community-client --purge
  5. sudo mkdir -p /etc/mysql/conf.d/

    else error with mysql-server (--configure)==> /etc/mysql/conf.d/在/etc/init.d/mysql重新启动中找不到

  6. sudo apt install mysql-server mysql-client --fix-broken --fix-missing

  7. 使用备份文件还原configure_files和数据库
  8. /etc/init.d/mysql restart

希望这可以节省您的时间!祝好运!

BTWFailed to start mysql.service: Unit mysql.service is masked==>systemctl unmask mysql.service
MARKdpkg-query -l mysql*排队包裹状态。

By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.