PackageKit Deamon 已崩溃

PackageKit Deamon 已崩溃

我无法在 Kubuntu 18.10 上更新。我有 20 个软件包,当从 GUI 更新时,我收到:PackageKit Deamon 已崩溃

从终端: sudo apt-get update && sudo apt-get upgrade -y 我得到:

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?

我尝试了这个,但没有成功:https://itsfoss.com/could-not-get-lock-error/comment-page-5/

第二天我得到了:

E:dpkg 中断,您必须手动运行“sudo dpkg --configure -a”来解决问题。

运行:sudo dpkg --configure -a

Setting up snapd (2.37.1+18.10) ...
snapd.failure.service is a disabled or a static unit, not starting it.
snapd.snap-repair.service is a disabled or a static unit, not starting it.

systemctl status snapd.service

● snapd.service - Snappy daemon
   Loaded: loaded (/lib/systemd/system/snapd.service; enabled; v
   Active: deactivating (stop-sigterm) (Result: timeout)
 Main PID: 22246 (snapd)
    Tasks: 12 (limit: 4915)
   Memory: 268.4M
   CGroup: /system.slice/snapd.service
           ├─22246 /usr/lib/snapd/snapd
           ├─22319 apparmor_parser --replace --write-cache -O no
           └─22320 apparmor_parser --replace --write-cache -O no

Feb 13 11:46:58 xxxx systemd[1]: Starting Snappy daemon...
Feb 13 11:46:58 xxxx snapd[22246]: AppArmor status: apparmor is 
Feb 13 11:46:59 xxxx snapd[22246]: helpers.go:145: error trying 
Feb 13 11:46:59 xxxx systemd[1]: snapd.service: Start operation 

journalctl-xe

-- Subject: Unit snapd.service has finished shutting down
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- Unit snapd.service has finished shutting down.
Feb 13 11:47:47 xxxx systemd[1]: snapd.service: Found left-over 
Feb 13 11:47:47 xxxx systemd[1]: This usually indicates unclean 
Feb 13 11:47:47 xxxx systemd[1]: snapd.service: Found left-over 
Feb 13 11:47:47 xxxx systemd[1]: This usually indicates unclean 
Feb 13 11:47:47 xxxx systemd[1]: Starting Snappy daemon...

我无法运行:sudo dpkg --configure -a 我得到:dpkg: error: dpkg frontend is locked by another process

lsof /var/lib/dpkg/lock 

一切都死了。

我认为我必须重新安装一把新锁,但我不知道该怎么做?

sudo touch /var/lib/dpkg/lock

不工作。

答案1

我通过在启动时按住 shift 并重新启动,通过恢复模式以 root 身份进入终端。 sudo dpkg --configure -a之后从终端工作。

相关内容