Home > Operation and Maintenance > CentOS > 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?

王林
Release: 2020-04-02 13:30:26
Original
4676 people have browsed it

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/
Copy after login

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
Copy after login

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
Copy after login

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!

Related labels:
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template