无法获取锁 /var/cache/apt/archives/lock - open

无法获取锁 /var/cache/apt/archives/lock - open

我在终端上遇到这个问题已经有一天了。我尝试修复,阅读了许多指南,但毫无效果。我是 ubuntu 新手,任何帮助我都会很感激。“14.04 lts”

E: Could not get lock /var/cache/apt/archives/lock - open (11: Resource temporarily unavailable)
E: Unable to lock directory /var/cache/apt/archives/

也有这个数据。

/var/lock
/var/cache/apt-xapian-index/index.1/flintlock
/var/cache/software-center/xapian/flintlock
/var/lib/alsa/asound.state.lock
/var/lib/apt-xapian-index/update-lock
/var/lib/dpkg/lock
/var/lib/dpkg/info/libfile-fcntllock-perl.list
/var/lib/dpkg/info/libfile-fcntllock-perl.md5sums
/var/lib/dpkg/info/liblockfile-bin.list
/var/lib/dpkg/info/liblockfile-bin.md5sums
/var/lib/dpkg/info/liblockfile1:i386.list
/var/lib/dpkg/info/liblockfile1:i386.md5sums
/var/lib/dpkg/info/liblockfile1:i386.postinst
/var/lib/dpkg/info/liblockfile1:i386.postrm
/var/lib/dpkg/info/liblockfile1:i386.shlibs
/var/lib/dpkg/info/lockfile-progs.list
/var/lib/dpkg/info/lockfile-progs.md5sums
/var/lib/dpkg/info/python-lockfile.list
/var/lib/dpkg/info/python-lockfile.md5sums
/var/lib/dpkg/info/python-lockfile.postinst
/var/lib/dpkg/info/python-lockfile.prerm

答案1

如果只有一个终端运行apt-get,或者没有 Synaptic 和 Ubuntu 软件中心;您可以使用以下方法删除或移动锁定文件:

sudo mv /var/cache/apt/archives/lock /var/cache/apt/archives/lock_bak

相关内容