每次使用apt时,我都会得到“超时到达的错误”。看看/var/log/syslog,我看到了:
dbus[619]: [system] Activating via systemd: service name='org.freedesktop.PackageKit' unit='packagekit.service'
systemd[1]: Starting PackageKit Daemon...
PackageKit: daemon start
PackageKit: daemon quit
packagekitd[12925]: Failed to load the backend: Failed to execute statement 'PRAGMA synchronous=OFF': database disk image is malformed
systemd[1]: Started PackageKit Daemon.
gnome-software[2433]: running search with refine-flags=require-icon with timeout=60 with max-results=20 with search=packagek on plugin=snap took 378ms
gnome-software[2433]: running search with refine-flags=require-icon with timeout=60 with max-results=20 with search=packageki on plugin=snap took 432ms
gnome-software[2433]: running search with refine-flags=require-icon with timeout=60 with max-results=20 with search=packagekit on plugin=snap took 231ms
gnome-software[2433]: failed to call gs_plugin_refine on packagekit-refine: failed to resolve package_ids: Error calling StartServiceByName for org.freedesktop.PackageKit: GDBus.Error:org.freedesktop.DBus.Error.TimedOut: Failed to activate service 'org.freedesktop.PackageKit': timed out以前有人遇到过这个问题吗?有办法修复数据库吗?或者我可以重新安装打包包吗?
发布于 2018-08-17 23:55:37
以下工作取得了成效:
sudo apt-get remove packagekit
sudo apt-get purge packagekit
sudo apt-get install ubuntu-software另外,您应该能够使用以下选项:
sudo apt-get remove --purge packagekit
sudo apt-get install ubuntu-software我本希望能找到更好的解决办法。我确实找到了带有pkcon选项的repair命令,但是它依赖于运行packagekitd来与数据库交互。
我无法在网上找到任何关于数据库存储位置的引用,也无法找到如何以其他方式处理这个问题的参考。与PackageKit相关的大多数问题都是关于Fedora、RedHat或CentOS的,所以没有那么有帮助。
发布于 2022-05-26 21:23:13
数据库文件如下所示。删除它并重新启动packagekit服务。
/var/lib/PackageKit/transactions.db
https://askubuntu.com/questions/1059223
复制相似问题