Debian和ubuntu apt-get 安装意外中断后导致资源被锁,及screen用法-泓源视野

Debian和ubuntu apt-get 安装意外中断后导致资源被锁,及screen用法

错误提示:

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?

解决办法:

sudo rm /var/cache/apt/archives/lock
sudo rm /var/lib/dpkg/lock
最后提醒安装前记得screen 一下!这样网络中断也可以接着运行
screen -S yourname -> 新建一个叫yourname的session
screen -ls -> 列出当前所有的session
screen -r yourname -> 回到yourname这个session
screen -d yourname -> 远程detach某个session
screen -d -r yourname -> 结束当前session并回到yourname这个session
本文由 泓源视野 作者:admin 发表,其版权均为 泓源视野 所有,文章内容系作者个人观点,不代表 泓源视野 对观点赞同或支持。如需转载,请注明文章来源。
9

发表评论

Protected with IP Blacklist CloudIP Blacklist Cloud
您是第8236406 位访客, 您的IP是:[44.222.104.49]