Get the App
SLTechnology News&Howtos  ›  Servers  › 

How to set NetEase download Source in CentOS system

Shulou Source: shulou.com Published: 2022-06-01 17:24:39 11月12日 Update

This article will explain in detail how to set up the download source of NetEase in the CentOS system. The content of the article is of high quality, so the editor will share it with you for reference. I hope you will have a certain understanding of the relevant knowledge after reading this article.

The code is as follows:

# mv / etc/yum.repos.d/CentOS-Base.repo / etc/yum.repos.d/CentOS-Base.repo.backup / / back up the original settings first and have the habit before making any changes

CentOS-5

The code is as follows:

# wget http://mirrors.163.com/.help/CentOS5-Base-163.repo-O / etc/yum.repos.d/CentOS-Base.repo

# yum makecache

CentOS-6

The code is as follows:

# wget http://mirrors.163.com/.help/CentOS6-Base-163.repo-O / etc/yum.repos.d/CentOS-Base.repo

# yum makecache

The source settings for centos5 are as follows:

The code is as follows:

# CentOS-Base.repo

#

# The mirror system uses the connecting IP address of the client and the

# update status of each mirror to pick mirrors that are updated to and

# geographically close to the client. You should use this for CentOS updates

# unless you are manually picking other mirrors.

#

# If the mirrorlist= does not work for you, as a fall back you can try the

# remarked out baseurl= line instead.

#

#

[base]

Name=CentOS-$releasever-Base-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/os/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os

Gpgcheck=1

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

# released updates

[updates]

Name=CentOS-$releasever-Updates-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/updates/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates

Gpgcheck=1

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

# packages used/produced in the build but not released

[addons]

Name=CentOS-$releasever-Addons-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/addons/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=addons

Gpgcheck=1

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

# additional packages that may be useful

[extras]

Name=CentOS-$releasever-Extras-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/extras/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras

Gpgcheck=1

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

# additional packages that extend functionality of existing packages

[centosplus]

Name=CentOS-$releasever-Plus-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/centosplus/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus

Gpgcheck=1

Enabled=0

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

# contrib-packages by Centos Users

[contrib]

Name=CentOS-$releasever-Contrib-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/contrib/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contrib

Gpgcheck=1

Enabled=0

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

The source settings for centos6 are as follows:

The code is as follows:

# CentOS-Base.repo

#

# The mirror system uses the connecting IP address of the client and the

# update status of each mirror to pick mirrors that are updated to and

# geographically close to the client. You should use this for CentOS updates

# unless you are manually picking other mirrors.

#

# If the mirrorlist= does not work for you, as a fall back you can try the

# remarked out baseurl= line instead.

#

#

[base]

Name=CentOS-$releasever-Base-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/os/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os

Gpgcheck=1

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

# released updates

[updates]

Name=CentOS-$releasever-Updates-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/updates/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates

Gpgcheck=1

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

# additional packages that may be useful

[extras]

Name=CentOS-$releasever-Extras-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/extras/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras

Gpgcheck=1

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

# additional packages that extend functionality of existing packages

[centosplus]

Name=CentOS-$releasever-Plus-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/centosplus/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus

Gpgcheck=1

Enabled=0

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

# contrib-packages by Centos Users

[contrib]

Name=CentOS-$releasever-Contrib-163.com

Baseurl= http://mirrors.163.com/centos/$releasever/contrib/$basearch/

# mirrorlist= http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contrib

Gpgcheck=1

Enabled=0

Gpgkey= http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

On how to set up NetEase download source in the CentOS system to share here, I hope the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.

Tags: Code system NetEase content articles more knowledge articles good backup quality reference help related Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Huawei Microsoft macOS MySQL Shulou Technology