Home  >  Article  >  Operation and Maintenance  >  What should I do if I cannot use yum to install software on centos?

What should I do if I cannot use yum to install software on centos?

王林
王林Original
2020-04-02 13:30:264640browse

What should I do if I cannot use yum to install software on centos?

Solution:

1. Download the yum source corresponding to the system version

2. Enter the following path:

#cd /etc/yum.repos.d/

will Back up the original CentOS-Base.repo and change it to CentOS-Base.repo.backup

Change the newly downloaded yum source to CentOS-Base.repo

3. Edit the following files

#vim /etc/resolv.conf

Add nameserver 8.8.8.8

What should I do if I cannot use yum to install software on centos?

4. Run the following command:

# yum makecache

What should I do if I cannot use yum to install software on centos?

Related tutorials Recommended: centos tutorial

The above is the detailed content of What should I do if I cannot use yum to install software on centos?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn