在ubuntu16.04下安装git,出现以下问题:
E: Could not get lock /var/lib/dpkg/lock - open (11: Resource temporarily unavailable)
E: Unable to lock the administration directory (/var/lib/dpkg/)
解决方法:https://stackoverflow.com/questions/42899411/i-want-to-install-git-in-ubuntu-but-i-am-getting-error
sudo rm /var/lib/apt/lists/lock
sudo rm /var/cache/apt/archives/lock
sudo rm /var/lib/dpkg/lock
sudo dpkg --configure -a
原因可能是已经打开了Synaptic 包管理器的GUI界面,同时想通过在终端输入sudo apt-get install安装软件。