解決yum install 時出現的“State : Sleeping, pid: xxxx”的問題
阿新 • • 發佈:2019-01-02
當我在安裝python包時,往往會依賴以下幾個包,但是有些電腦會出現以下錯誤:
[[email protected] scrapy-cluster-1.2]# yum install gcc libffi-devel python-devel openssl-devel
Loaded plugins: fastestmirror, refresh-packagekit, security
Existing lock /var/run/yum.pid: another copy is running as pid 4776.
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:20 ago
State : Sleeping, pid: 4776
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:22 ago
State : Sleeping, pid: 4776
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:24 ago
State : Sleeping, pid: 4776
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:26 ago
State : Sleeping, pid: 4776
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:28 ago
State : Sleeping, pid: 4776
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:30 ago
State : Sleeping, pid: 4776
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:32 ago
State : Sleeping, pid: 4776
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:34 ago
State : Sleeping, pid: 4776
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:36 ago
State : Sleeping, pid: 4776
Another app is currently holding the yum lock; waiting for it to exit...
The other application is: PackageKit
Memory : 52 M RSS (433 MB VSZ)
Started: Tue Jun 14 11:17:51 2016 - 338 day(s) 4:56:38 ago
State : Sleeping, pid: 4776
遇到這個錯誤我們可以用以下命令解決:
[root@pachong1 scrapy-cluster-1.2]# rm -f /var/run/yum.pid 4776
至此,你安裝這些依賴不會報這個錯誤,這個錯誤的原因是因為:
/var/run/yum.pid 已被鎖定,PID 為 4776 的另一個程式正在執行。另外一個程式鎖定了 yum。刪除yum.pid即可。
如有問題請加QQ群相互討論,QQ群號:526855734