欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

linux中yum update被占用(Another app is currently holding the yum lock)的解決辦法

  發(fā)布時間:2016-10-07 16:56:26   作者:佚名   我要評論
這篇文章主要介紹了linux中yum update被占用,Another app is currently holding the yum lock的解決辦法,需要的朋友可以參考下

使用yum安裝計劃任務(wù)功能,結(jié)果提示:


復(fù)制代碼
代碼如下:

# yum -y install vixie-cron
Loaded plugins: fastestmirror, refresh-packagekit, security
Existing lock /var/run/yum.pid: another copy is running as pid <font color="#ff0000">25960</font>.
Another app is currently holding the yum lock; waiting for it to exit...


可能是系統(tǒng)自動升級正在運行,yum在鎖定狀態(tài)中。
已經(jīng)有一個yum進(jìn)程在運行了,使用kill干掉它:


復(fù)制代碼
代碼如下:

# kill -s 9 25960
# ps aux|grep yum
root 6744 0.0 0.0 103260 900 pts/1 S+ 14:59 0:00 grep yum
root 25960 0.0 0.0 0 0 ? Z Sep19 0:01 [yumBackend.py] <defunct>


很遺憾,kill對付不了它,那怎么辦呢?

可以通過強制關(guān)掉yum進(jìn)程:

#rm -f /var/run/yum.pid

然后就可以使用yum了。如果不行可以重啟yum

/sbin/service yum-updatesd restart

以下是其它網(wǎng)友的補充:

補充一、

有時,在linux下yum update會提示:

Another app is currently holding the yum lock解決方案

解決辦法是干掉緩存中的yum進(jìn)程,重啟yum。

清掉緩存中的進(jìn)程:

rm -f /var/run/yum.pid

重啟yum(我的系統(tǒng)是fedora)

systemctl status yum-updatesd.service

centos用戶使用:

/sbin/service yum-updatesd restart

補充二、

在CentOS上yum -y install gcc* gcc-c++* autoconf* automake* zlib* libxml* ncurses-devel* libmcrypt* libtool*時出現(xiàn)錯誤:

\ 

1)怎么回事呢?根據(jù)提示,原來是系統(tǒng)進(jìn)程已經(jīng)有一個update在運行了。在進(jìn)程里查看下:ps -ef | grep update

\

2)通過kill殺掉這個進(jìn)程,可殺掉之后,錯誤依舊。原來在/var/run目錄下,還有yum這個進(jìn)程ID,需要將這個進(jìn)程id文件強制刪除掉:

\ 

3)同時重啟下yum更新服務(wù),如下:

\

4)最后重新yum -y install gcc* gcc-c++* autoconf* automake* zlib* libxml* ncurses-devel* libmcrypt* libtool* ,已正常

\

以上就是腳本之家小編的整理了,希望大家多支持腳本之家網(wǎng)站。

相關(guān)文章

最新評論