What is yum source, how to change yum source, and how to change yum Source

Source: Internet
Author: User

What is yum source, how to change yum source, and how to change yum Source

Yum (all called Yellow dog Updater, Modified)

Yum is a Shell front-end Package Manager in Fedora, RedHat, and CentOS. Based on RPM package management, You can automatically download and install the RPM package from the specified server, and automatically handle dependencies. you can install all dependent software packages at a time without the need for tedious download and installation.

Rpm is a software package management method developed by RedHat. With rpm, we can easily install, query, uninstall, and upgrade software. However, the dependency between rpm packages is often cumbersome, especially when software is grouped by multiple rpm packages.

Difference: in a simple answer, rpm can only install the rpm package that has been downloaded to the local machine. yum can download and install rpm packages online, update the system, and automatically handle dependencies between packages. This is not available in rpm tools.

 

Use Centos as an example to change the yum Source:

1. Backup Source

Mv/etc/yum. repos. d/CentOS-Base.repo/etc/yum. repos. d/CentOS-Base.repo.backup

 

2. Open the source directory

Cd/etc/yum. repos. d/

 

3. Download Source

Wget http://mirrors.163.com/.help/CentOS7-Base-163.repo

163 source URL: http://mirrors.163.com/.help/centos.html

 

4. Clear yum Cache

Yum clean all

Yum stores the downloaded software package and header in the cache without deleting it automatically. Use the yum clean command to clear disk space.

More precisely, yum clean headers clears the header, yum clean packages clears the downloaded rpm package, and yum clean all clears all.

 

5. Generate yum Cache

Yum makecache

Yum makecache downloads the server package information to a local computer and caches it with yum-C search xxx. You can search for software information without searching the Internet.

 

6. Main yum operations

The main command of yum is as follows:

Yum search software package

Yum install package installation package

Uninstall the yum remove package

Yum update system

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.