Rootop 服务器运维与web架构

There are unfinished transactions remaining. You might consider running yum-complete-transaction first to finish them

之前yum安装软件的时候用ctrl c 停止过,结果每次装软件或者卸载都提示有未完成的传输。
[root@Rootop ~]# yum remove goaccess
Loaded plugins: fastestmirror
Setting up Remove Process
Resolving Dependencies
There are unfinished transactions remaining. You might consider running yum-complete-transaction first to finish them.
The program yum-complete-transaction is found in the yum-utils package.

提示通过执行 yum-complete-transaction 完成,需要先安装 yum-utils 包
[root@Rootop ~]# yum install -y yum-utils
[root@Rootop ~]# yum-complete-transaction
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirrors.aliyun.com
* epel: ftp.sjtu.edu.cn
* extras: mirrors.skyshe.cn
* updates: mirrors.skyshe.cn
There are 6 outstanding transactions to complete. Finishing the most recent one
The remaining transaction had 6 elements left to run
Package libtalloc-2.0.7-2.el6.x86_64 already installed and latest version
Package libtevent-0.9.18-3.el6.x86_64 already installed and latest version
Nothing in the unfinished transaction to cleanup.
Cleaning up completed transaction file

再次执行卸载:
[root@Rootop ~]# yum remove samba
Loaded plugins: fastestmirror
Setting up Remove Process
Resolving Dependencies
There are unfinished transactions remaining. You might consider running yum-complete-transaction first to finish them.
还是提示有未完成。

执行下面两个命令:
[root@Rootop ~]# yum clean all
Loaded plugins: fastestmirror
Cleaning repos: base epel extras updates
Cleaning up Everything
Cleaning up list of fastest mirrors

[root@Rootop ~]# yum-complete-transaction --cleanup-only

Loaded plugins: fastestmirror
Determining fastest mirrors
Cannot retrieve metalink for repository: epel. Please verify its path and try again
又有别的报错,查资料说需要修改epel的仓库配置文件,把https改为http。

[epel]
name=Extra Packages for Enterprise Linux 6 - $basearch
#下面的https改为http
mirrorlist=http://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=$basearch
failovermethod=priority
enabled=1

重新执行yum-complete-transaction:

[root@Rootop yum.repos.d]# yum-complete-transaction --cleanup-only
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.yun-idc.com
 * epel: mirrors.yun-idc.com
 * extras: mirrors.yun-idc.com
 * updates: mirrors.yun-idc.com
Cleaning up unfinished transaction journals
Cleaning up 2014-06-15.01:05.45
Cleaning up 2014-06-15.01:07.56

看到2个清理提示。
再次执行yum install或者remove没有了未完成的提示。曾经因为这个问题把系统的yum折腾坏一次。

原创文章,转载请注明。本文链接地址: https://www.rootop.org/pages/3077.html

作者:Venus

服务器运维与性能优化

评论已关闭。