Linux运维•运维日志-解决Another app is currently holding the yum lock; waiting for it to exit...

[root@bogon ~]# yum install gcc-c++ 
Loaded plugins: fastestmirror, refresh-packagekit, security
Existing lock /var/run/yum.pid: another copy is running as pid 2395.
Another app is currently holding the yum lock; waiting for it to exit...
  The other application is: PackageKit
    Memory :  20 M RSS ( 35 MB VSZ)
    Started: Thu Jul 20 11:25:58 2017 - 8:01:01 ago
    State  : Sleeping, pid: 2395

这里的意思是yum被占用所以需要把这个进程干掉!!! 
解决办法: 
第一种办法:

kill -s 9 2395

第二种办法: 
要是第一种没效果就用下面语句:

注:执行下面的命令,如果一次没有效果,就执行个七八次,反正不影响。

rm -f /var/run/yum.pid

然后使用ps命令:

ps aux|grep yum

查看占用yum的进程是否被干掉 
然后安心的使用yum命令吧。。。我这里安装的是很多依赖

yum -y install wget openssl* gcc gcc-c++ autoconf libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel libxml2 libxml2-devel zlib zlib-devel glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devel ncurses ncurses-devel curl curl-devel e2fsprogs e2fsprogs-devel krb5 krb5-devel libidn libidn-devel openssl openssl-devel openldap openldap-devel nss_ldap openldap-clients openldap-servers make gd gd2 gd-devel gd2-devel libxslt libxslt-devel libaio libaio-devel

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值