24.03 dnf update problem?

问题如下所述,我电脑明明装的就是下面提示的版本,为啥 会报错呢?
Problem 2: package docker-25.0.3-10.oe2403.x86_64 from @System requires docker-engine =
25.0.3-10.oe2403, but none of the providers can be installed

  • cannot install both docker-engine-2:18.09.0-340.oe2403.x86_64 from update and docker
    -engine-25.0.3-10.oe2403.x86_64 from @System
  • cannot install both docker-engine-25.0.3-10.oe2403.x86_64 from update and docker-eng
    ine-2:18.09.0-340.oe2403.x86_64 from update
  • 无法为软件包安装最佳更新候选 docker-engine-25.0.3-10.oe2403.x86_64
  • 无法为软件包安装最佳更新候选 docker-25.0.3-10.oe2403.x86_64

这个问题应该属于官方仓库的问题

具体是因为系统上已经安装了 docker-25.0.3-10,但是在官方仓库里边还有一个 docker-engine-2:18.09.0 的包,这个包被设置了 Epoch=2 的优先级,所以在执行 dnf update 命令更新时,工具会认为要优先安装 docker-2:18.09.0,从而和已安装的 docker-25.0.3-10 冲突

该问题是必现问题,复现方法:

# 先安装 docker,默认会安装 docker-25.0.3-10
$ yum install docker

# 再执行更新命令
$ dnf update
Last metadata expiration check: 0:10:27 ago on Tue 03 Dec 2024 05:10:45 PM CST.
Error: 
 Problem: package docker-25.0.3-10.oe2403.x86_64 from @System requires docker-engine = 25.0.3-10.oe2403, but none of the providers can be installed
  - cannot install both docker-engine-2:18.09.0-340.oe2403.x86_64 from update and docker-engine-25.0.3-10.oe2403.x86_64 from @System
  - cannot install both docker-engine-25.0.3-10.oe2403.x86_64 from update and docker-engine-2:18.09.0-340.oe2403.x86_64 from update
  - cannot install both docker-engine-25.0.3-10.oe2403.x86_64 from openEuler-update and docker-engine-2:18.09.0-340.oe2403.x86_64 from update
  - cannot install the best update candidate for package docker-engine-25.0.3-10.oe2403.x86_64
  - cannot install the best update candidate for package docker-25.0.3-10.oe2403.x86_64
(try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)

规避方案:
dnf update --exclude=docker-25.0.3-10.oe2403.x86_64,docker-client-25.0.3-10.oe2403.x86_64,docker-engine-25.0.3-10.oe2403.x86_64

我现在是这样搞的。 sudo dnf update --nobest
另外请教一下到底要保留哪一个版本

保留哪个版本要看自己的需求了

两个版本有啥 不同呢?