我尝试在ubuntu中安装python 3.6
sudo apt-get install python3.6
它出现以下错误
E: Could not get lock /var/lib/dpkg/lock - open (11: Resource temporarily unavailable)
E: Unable to lock the administration directory (/var/lib/dpkg/), is another process using it?
答案 0 :(得分:0)
当apt进程正在运行时会发生这种情况,并在进程完成时被删除。如果没有进程正在运行锁定,这可能意味着进程由于某种原因而卡住并且没有释放锁定。
试试这个:
ps aux | grep apt
sudo kill -9 processnumber
您可以在此处找到有关如何移除锁定的更多解决方案:https://askubuntu.com/questions/15433/unable-to-lock-the-administration-directory-var-lib-dpkg-is-another-process
然后使用以下链接安装python3.6:https://askubuntu.com/questions/865554/how-do-i-install-python-3-6-using-apt-get