解决linux报/var/run/yum.pid已被锁定的问题
使用Vmware刚安装完centos 7 系统后,想使用yum命令安装其他的软件,却不曾想报错了。报错如下:
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
/var/run/yum.pid 已被锁定,PID 为 54240 的另一个程序正在运行。
Another app is currently holding the yum lock; waiting for it to exit...
另一个应用程序是:PackageKit
内存:173 M RSS (520 MB VSZ)
已启动: Wed Apr 22 09:34:52 2020 - 1:21:33之前
状态 :睡眠中,进程ID:54240
Another app is currently holding the yum lock; waiting for it to exit...
另一个应用程序是:PackageKit
内存:173 M RSS (520 MB VSZ)
已启动: Wed Apr 22 09:34:52 2020 - 1:21:35之前
状态 :睡眠中,进程ID:54240
Another app is currently holding the yum lock; waiting for it to exit...
另一个应用程序是:PackageKit
内存:173 M RSS (520 MB VSZ)
已启动: Wed Apr 22 09:34:52 2020 - 1:21:37之前
状态 :睡眠中,进程ID:54240
^C
Exiting on user cancel.
解决方法:删除/var/run/yum.pid文件
命令:rm -rf /var/run/yum.pid