由于“请求冲突”,Rocky Linux 从 8.x 升级到 9 失败

由于“请求冲突”,Rocky Linux 从 8.x 升级到 9 失败

yum upgrade -y我尝试使用以下说明从 Rocky 8.6 升级(在我通过 更新所有软件包后现在是 8.7 ):

https://www.techrepublic.com/article/upgrade-rocky-linux/


REPO_URL="https://download.rockylinux.org/pub/rocky/9/BaseOS/x86_64/os/Packages/r"
RELEASE_PKG="rocky-release-9.0-2.4.el9.noarch.rpm"
REPOS_PKG="rocky-repos-9.0-2.4.el9.noarch.rpm"
GPG_KEYS_PKG="rocky-gpg-keys-9.0-2.4.el9.noarch.rpm"

然后 :

sudo dnf install $REPO_URL/$RELEASE_PKG $REPO_URL/$REPOS_PKG $REPO_URL/$GPG_KEYS_PKG

结果显示如下信息:

[root@rocky ~]# dnf install $REPO_URL/$RELEASE_PKG $REPO_URL/$REPOS_PKG $REPO_URL/$GPG_KEYS_PKG
Last metadata expiration check: 13:22:44 ago on Sat 26 Nov 2022 08:23:39 PM CET.
rocky-release-9.0-2.4.el9.noarch.rpm                                                                                                                       117 kB/s |  22 kB     00:00    
rocky-repos-9.0-2.4.el9.noarch.rpm                                                                                                                         114 kB/s |  12 kB     00:00    
rocky-gpg-keys-9.0-2.4.el9.noarch.rpm                                                                                                                      110 kB/s |  12 kB     00:00    
Error: 
 Problem: problem with installed package remi-release-8.6-1.el8.remi.noarch
  - package remi-release-8.6-1.el8.remi.noarch requires system-release(releasever) = 8, but none of the providers can be installed
  - package remi-release-8.4-1.el8.remi.noarch requires system-release(releasever) = 8, but none of the providers can be installed
  - package remi-release-8.5-2.el8.remi.noarch requires system-release(releasever) = 8, but none of the providers can be installed
  - package remi-release-8.5-3.el8.remi.noarch requires system-release(releasever) = 8, but none of the providers can be installed
  - cannot install both rocky-release-9.0-2.4.el9.noarch and rocky-release-8.7-1.2.el8.noarch
  - conflicting requests
(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)
[root@rocky ~]# 

neofetch返回:

[root@rocky ~]# neofetch
        #####           [email protected] 
       #######          ---------------------- 
       ##O#O##          OS: Rocky Linux 8.7 (Green Obsidian) x86_64 
       #######          Host: KVM/QEMU (Standard PC (Q35 + ICH9, 2009) pc-q35-7.0) 
     ###########        Kernel: 4.18.0-425.3.1.el8.x86_64 
    #############       Uptime: 11 mins 
   ###############      Packages: 872 (rpm) 
   ################     Shell: bash 4.4.20 
  #################     Resolution: 1280x800 
#####################   Terminal: /dev/pts/0 
#####################   CPU: QEMU Virtual version 2.5+ (8) @ 999MHz 
  #################     GPU: 00:01.0 Red Hat, Inc. Virtio GPU 
                        Memory: 438MiB / 1807MiB 

错误提示我正在安装 8.6,而我安装的是 9.x。这里可能存在什么问题?

答案1

我认为您需要在 dnf 安装命令行中添加 epel-release 和 remi-release 包。

所以:

https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
https://rpms.remirepo.net/enterprise/remi-release-9.rpm

相关内容