linux - yum 更新显示已安装的软件包版本

标签 linux shell centos rpm yum

我的系统已经安装了一个 libmaxminddb-1.2.0-10.el8.rpm 包。但是当我运行 yum update --assumeno 时,要求再次重新安装同一个软件包,不知道为什么会发生这种情况以及如何避免它。谢谢

[root@vm x86_64]# ls | grep libmax
libmaxminddb-1.2.0-10.el8.rpm

[root@vm~]# yum update --assumeno
Repository 'My-Repository' is missing name in configuration, using id.
Repository 'updates' is missing name in configuration, using id.
Last metadata expiration check: 0:14:11 ago on Thu 04 Feb 2021 06:16:35 PM UTC.
Dependencies resolved.
=====================================================================================================================================================================================================
Package                                         Architecture                              Version                                           Repository                                         Size
=====================================================================================================================================================================================================
Upgrading:
libmaxminddb                                    x86_64                                    1.2.0-10.el8                                      My-Repository                                     33 k

Transaction Summary
=====================================================================================================================================================================================================
Upgrade  1 Package

Total download size: 33 k
Operation aborted.

最佳答案

也许新包具有相同的名称、版本、版本和架构,但不同的时代(从包装的角度来看这会很丑陋)?尝试比较您拥有的和可用的。
要查看您已安装的软件包的详细信息(在此示例中,我使用的是 bash):

# rpm -q --queryformat "Epoch: %{EPOCH}\n" bash
Epoch: (none)
# rpm -q --info bash
Name        : bash
Version     : 5.0.17
Release     : 2.fc33
Architecture: x86_64
Install Date: Tue 20 Oct 2020 01:36:17 AM CEST
Group       : Unspecified
Size        : 7709818
License     : GPLv3+
Signature   : RSA/SHA256, Tue 28 Jul 2020 12:10:09 AM CEST, Key ID 49fd77499570ff31
Source RPM  : bash-5.0.17-2.fc33.src.rpm
Build Date  : Mon 27 Jul 2020 03:17:35 PM CEST
Build Host  : buildhw-x86-14.iad2.fedoraproject.org
Packager    : Fedora Project
Vendor      : Fedora Project
URL         : https://www.gnu.org/software/bash
Bug URL     : https://bugz.fedoraproject.org/bash
Summary     : The GNU Bourne Again shell
Description :
The GNU Bourne Again shell (Bash) is a shell or command language
interpreter that is compatible with the Bourne shell (sh). Bash
incorporates useful features from the Korn shell (ksh) and the C shell
(csh). Most sh scripts can be run by bash without modification.
然后获取有关可用包的相同信息:
# yum download bash
# rpm -qp bash-5.0.17-2.fc33.x86_64.rpm --queryformat "Epoch: %{EPOCH}\n"
Epoch: (none)
# rpm -qp bash-5.0.17-2.fc33.x86_64.rpm --info
Name        : bash
Version     : 5.0.17
Release     : 2.fc33
Architecture: x86_64
Install Date: (not installed)
Group       : Unspecified
Size        : 7709818
License     : GPLv3+
Signature   : RSA/SHA256, Tue 28 Jul 2020 12:10:09 AM CEST, Key ID 49fd77499570ff31
Source RPM  : bash-5.0.17-2.fc33.src.rpm
Build Date  : Mon 27 Jul 2020 03:17:35 PM CEST
Build Host  : buildhw-x86-14.iad2.fedoraproject.org
Packager    : Fedora Project
Vendor      : Fedora Project
URL         : https://www.gnu.org/software/bash
Bug URL     : https://bugz.fedoraproject.org/bash
Summary     : The GNU Bourne Again shell
Description :
The GNU Bourne Again shell (Bash) is a shell or command language
interpreter that is compatible with the Bourne shell (sh). Bash
incorporates useful features from the Korn shell (ksh) and the C shell
(csh). Most sh scripts can be run by bash without modification.

关于linux - yum 更新显示已安装的软件包版本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/66132219/

相关文章:

java - Android screenshot2 Linux 上的工具 NullPointerException

linux - 一次性删除大量文件夹

MySQL 5.6 LOAD XML LOCAL INFILE 和空 XML 元素

android - VirtualBox Linux 无法挂载安卓设备

linux - 依赖性问题 - 未配置

linux - 将 shell 脚本和 zip 文件组合成一个可执行文件以进行部署

mongodb - 如何在CentOS中使用附加参数执行 'service mongod start'?

android mmap 失败 : invalid argument (errno 22)

linux - 使用 BIND 与子域的 DNS - 多个服务器和托管帐户

linux - 重定向程序的结果