RHEL8 YUM源下载及应用--亲测好用

本文详细介绍如何在红帽8系统中配置yum源,通过使用清华大学开源软件镜像站提供的资源,实现快速稳定的软件包安装。文章提供了具体的配置步骤及命令。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

联网配置yum 源,亲测好用!!!

 

红帽8中yum源配置

1、dnf源文件下载

使用的是清华大学开源软件镜像站:https://mirrors.tuna.tsinghua.edu.cn/

2、dnf源配置

rhel8系统安装完成,在红帽8主机中进行如下配置:

① 使用vim编辑器打开软件源

[root@localhost ~]# vim /etc/yum.repos.d/rhel-8-beta.repo

② 具体配置如下:

[rhel-8-baseos-beta-source-rpms]

name = Red Hat Enterprise Linux 8 - BaseOS Beta (Source RPMs)

baseurl = https://downloads.redhat.com/redhat/rhel/rhel-8-beta/baseos/source/

enabled = 1

gpgcheck = 1

gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-beta,file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release


[rhel-8-for-x86_64-baseos-beta-rpms]

name = Red Hat Enterprise Linux 8 for x86_64 - BaseOS Beta (RPMs)

baseurl = https://downloads.redhat.com/redhat/rhel/rhel-8-beta/baseos/x86_64/

enabled = 1

gpgcheck = 1

gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-beta,file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release


[rhel-8-appstream-beta-source-rpms]

name = Red Hat Enterprise Linux 8 - AppStream Beta (Source RPMs)

baseurl = https://downloads.redhat.com/redhat/rhel/rhel-8-beta/appstream/source/

enabled = 1

gpgcheck = 1

gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-beta,file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release


[rhel-8-for-x86_64-appstream-beta-rpms]

name = Red Hat Enterprise Linux 8 for x86_64 - AppStream Beta (RPMs)

baseurl = https://downloads.redhat.com/redhat/rhel/rhel-8-beta/appstream/x86_64/

enabled = 1

gpgcheck = 1

gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-beta,file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

修改完成后,进行元数据缓存后即可使用。

[root@localhost ~]# dnf clean all

[root@localhost ~]# dnf makecache

此时用yum install xxx 可以实现package 安装!
————————————————

参考文章:

版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://blog.csdn.net/itcast_cn/article/details/87179791
————————————————

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值