centos在没有安装centos-release包时配置yum源

由于没有安装centos-release包,因此无法获取$releasever,asearch等相关信息,需要手动执行才行


baseurl=http://mirror.centos.org/centos/$releasever/updates/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

 

下面是常用的yum源:

 

[base1]
name=CentOS-Base1
baseurl=http://mirror.centos.org/centos/7/os/x86_64/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[base3]
name=CentOS-Base3
baseurl=http://archive.cloudera.com/cm5/redhat/7/x86_64/cm/5.12.1
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[aliyum]
name=CentOS-aliyum
baseurl=http://mirrors.aliyun.com/centos/7.6.1810/os/x86_64/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[sjtu]
name=CentOS-sjtu
baseurl=http://ftp.sjtu.edu.cn/centos/7.6.1810/os/x86_64/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[jdcloud]
name=CentOS-jdcloud
baseurl=http://mirror.jdcloud.com/centos/7.6.1810/os/x86_64
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[zju]
name=CentOS-zju
baseurl=http://mirrors.zju.edu.cn/centos/7.6.1810/os/x86_64
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[ustc]
name=CentOS-ustc
baseurl=http://centos.ustc.edu.cn/centos/7.6.1810/os/x86_64
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[tsinghua]
name=CentOS-tsinghua
baseurl=http://mirrors.tuna.tsinghua.edu.cn/centos/7.6.1810/os/x86_64/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[lzu]
name=CentOS-lzu
baseurl=http://mirror.lzu.edu.cn/centos/7.6.1810/extras/x86_64/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[163]
name=CentOS-163
baseurl=http://mirrors.163.com/centos/7.6.1810/extras/x86_64
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[cqu]
name=CentOS-cqu
baseurl=http://mirrors.cqu.edu.cn/CentOS/7.6.1810/extras/x86_64
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[ustc]
name=ustc
baseurl=http://centos.ustc.edu.cn/centos/7.6.1810/extras/x86_64/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[nginx]
name=nginx
baseurl=http://nginx.org/packages/centos/7/x86_64
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[njupt]
name=njupt
baseurl=http://mirrors.njupt.edu.cn/centos/7.6.1810/os/x86_64
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[cloudera]
name=cloudera
baseurl=http://archive.cloudera.com/cm5/redhat/7/x86_64/cm/5.12.1/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[hortonworks-2.7]
name=hortonworks-2.7
baseurl=http://public-repo-1.hortonworks.com/ambari/centos7/2.x/updates/2.7.0.0/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[hortonworks-2.6]
name=hortonworks-2.6
baseurl=http://public-repo-1.hortonworks.com/ambari/centos7/2.x/updates/2.6.1.0/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[bit]
name=bit
baseurl=http://mirror.bit.edu.cn/centos/7.6.1810/os/x86_64/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[njupt]
name=njupt
baseurl=http://mirrors.njupt.edu.cn/centos/7.6.1810/os/x86_64
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[huaweicloud]
name=CentOS-huaweicloud
baseurl=http://mirrors.huaweicloud.com/centos/7.6.1810/os/x86_64/
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值