2011年12月8日 星期四

[Linux]How to Stop yum lock

當想要install 一個套件時
最常遇見的問題:
Another app is currently holding the yum lock; waiting for it to exit...
Another app is currently holding the yum lock; waiting for it to exit...
Another app is currently holding the yum lock; waiting for it to exit...

這是因為 yum 的預設是會自動更新的....
此時剛好在更新....所以無法 install

解決方式2種:
(1)找出process 然後 kill 它

(2)關掉這個service,方法如下
a.service yum-updatesd stop
b.chkconfig --level 5 yum-updatesd stop


or


Existing lock /var/run/yum.pid: another copy is running as pid 3807.
Another app is currently holding the yum lock; waiting for it to exit...
Another app is currently holding the yum lock; waiting for it to exit...


解決方式:
rm -f /var/run/yum.pid /sbin/service yum-updatesd restart

沒有留言:

張貼留言