我正在使用 CentOS 7 - CentOS Linux 版本 7.0.1406(核心)
我想下载更新的内核,我知道以下内核可用于 CentOS7.X 版本:
3.10.0-123、3.10.0-229、3.10.0-327、3.10.0-514
但是当我 yum 信息时,我收到以下信息:
[admin@CentOS70 ~]$ yum list --showduplicates kernel
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
* base: centos.spd.co.il
* extras: centos.spd.co.il
* updates: centos.spd.co.il
Installed Packages
kernel.x86_64 3.10.0-123.el7 @anaconda
Available Packages
kernel.x86_64 3.10.0-693.el7 base
kernel.x86_64 3.10.0-693.1.1.el7 updates
kernel.x86_64 3.10.0-693.2.1.el7 updates
kernel.x86_64 3.10.0-693.2.2.el7 updates
kernel.x86_64 3.10.0-693.5.2.el7 updates
[admin@CentOS70 ~]$
为什么 yum 不建议我安装 3.10.0-327 ?我怎样才能将它们全部呈现出来?
我的目标是制作一个包含所有内核的基础机器。由于CentOS 7.4无法安装3.10.0-123.el7,因此我将获得最低版本7(7.0)并在其上安装所有内核。
当尝试添加新存储库时,我收到由同行错误重置的连接。
name=CentOS-7.0 - Base
#mirrorlist=http://mirrorlist.centos.org/release=$releasever&arch=$basearch&repo=os
baseurl=http://vault.centos.org/7.0.1406/os/x86_64/
#baseurl=http://mirror.centos.org/centos/$releasever/os/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
答案1
好的,
需要做的是更新 repos 文件。
就我而言,我想要所有基本版本,所以我创建了一个新文件:
vi /etc/yum.repos.d/CentOS-Custom.repo
并粘贴:
[CentOS-7.0-Base]
name=CentOS-7.0 - Base
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
baseurl=http://vault.centos.org/7.0.1406/os/x86_64/
#baseurl=http://mirror.centos.org/centos/$releasever/os/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
[CentOS-7.1-Base]
name=CentOS-7.1 - Base
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
baseurl=http://vault.centos.org/7.1.1503/os/x86_64/
#baseurl=http://mirror.centos.org/centos/$releasever/os/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
[CentOS-7.2-Base]
name=CentOS-7.2 - Base
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
baseurl=http://vault.centos.org/7.2.1511/os/x86_64/
#baseurl=http://vault.centos.org/6.2/os/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
[CentOS-7.3-Base]
name=CentOS-7.3 - Base
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
baseurl=http://vault.centos.org/7.3.1611/os/x86_64/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
[base]
name=CentOS-7.4 - Base
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
baseurl=http://vault.centos.org/7.4.1708/os/Source/
#baseurl=http://mirror.centos.org/centos/$releasever/os/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
所以我的输出看起来像:
[root@CentOS73-x64 admin]# yum list --showduplicates kernel
...
Installed Packages
kernel.x86_64 3.10.0-514.el7 @anaconda
kernel.x86_64 3.10.0-693.2.2.el7 @updates
Available Packages
kernel.x86_64 3.10.0-123.el7 CentOS-7.0-Base
kernel.x86_64 3.10.0-229.el7 CentOS-7.1-Base
kernel.x86_64 3.10.0-327.el7 CentOS-7.2-Base
kernel.x86_64 3.10.0-514.el7 CentOS-7.3-Base
kernel.x86_64 3.10.0-693.el7 base
kernel.x86_64 3.10.0-693.1.1.el7 updates
kernel.x86_64 3.10.0-693.2.1.el7 updates
kernel.x86_64 3.10.0-693.2.2.el7 updates
kernel.x86_64 3.10.0-693.5.2.el7 updates
[root@CentOS73-x64