安装MYSQL中断后,报错

问题:安装MYSQL时报错,是因为之前安装时,没有网络,中断过

root@ubuntu:/etc/init.d# sudo apt-get install mysql-server
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?

 

采取的办法是:

root@ubuntu:~# lsof /var/lib/dpkg/lock-frontend
lsof: WARNING: can't stat() fuse.gvfsd-fuse file system /run/user/1000/gvfs
Output information may be incomplete.
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
apt-get 2564 root 4uW REG 8,1 0 413925 /var/lib/dpkg/lock-frontend

root@ubuntu:~# sudo kill -9 2564   注意‘-9’,如果不加,不会成功
root@ubuntu:~# lsof /var/lib/dpkg/lock-frontend

root@ubuntu:~# sudo apt-get install mysql-server
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
libaio1 libevent-core-2.1-6 libhtml-template-perl mysql-client-5.7
mysql-client-core-5.7 mysql-server-5.7 mysql-server-core-5.7
Suggested packages:
libipc-sharedcache-perl mailx tinyca
The following NEW packages will be installed:
libaio1 libevent-core-2.1-6 libhtml-template-perl mysql-client-5.7
mysql-client-core-5.7 mysql-server mysql-server-5.7 mysql-server-core-5.7
0 upgraded, 8 newly installed, 0 to remove and 238 not upgraded.
Need to get 20.5 MB of archives.
After this operation, 160 MB of additional disk space will be used.
Do you want to continue? [Y/n] y

转载于:https://www.cnblogs.com/sike8/p/11023049.html

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值