[英]I tried installing python 3.6 in ubuntu but every time I give the command in the terminal it shows an error:
I tried installing python 3.6 in ubuntu 我尝试在ubuntu中安装python 3.6
sudo apt-get install python3.6
It gives the following error 它给出了以下错误
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?
This happens lock is placed when an apt process is running, and is removed when the process completes. 当apt进程正在运行时,将发生这种锁定,在进程完成时将其删除。 If there is a lock with no process running, this may mean the process got stuck for some reason and has not released the lock.
如果存在没有运行任何进程的锁,则可能意味着该进程由于某种原因而卡住并且尚未释放该锁。
Try this: 尝试这个:
ps aux | grep apt
sudo kill -9 processnumber
You can find more solutions on how to remove the lock here: https://askubuntu.com/questions/15433/unable-to-lock-the-administration-directory-var-lib-dpkg-is-another-process 您可以在此处找到有关如何删除锁的更多解决方案: https : //askubuntu.com/questions/15433/unable-to-lock-the-administration-directory-var-lib-dpkg-is-another-process
Then install python3.6 using this link: https://askubuntu.com/questions/865554/how-do-i-install-python-3-6-using-apt-get 然后使用此链接安装python3.6: https ://askubuntu.com/questions/865554/how-do-i-install-python-3-6-using-apt-get
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.