CentOS is a comprehensive system designed with a corporate focus and in which it is sought to provide us with the best options for security, stability and performance of applications and processes, but in many times when the system is installed for the first time and we try to perform a task With the YUM package manager , how to install or search for a package, the following error is displayed:
"Cannot find a valid baseurl for repo: base / 7 / x86_64"
This error refers to the fact that the YUM package manager is not able to access the base repository from where the information and details of the package are obtained, this can occur due to situations such as:
- errors in the base URL of the repository configuration file
TechnoWikis will explain how to fix this error in CentOS 8..
To stay up to date, remember to subscribe to our YouTube channel! SUBSCRIBE
Cannot find a valid baseurl for repo base7x86_64 error in CentOS 8
Step 1
The first thing will be to execute the following command in the console:
ONBOOT = no
Step 2
ONBOOT = does not take care of preventing boot protocols from being executed in CentOS 8. After this we will execute the following:
dhclient
Step 3
Dhclient is tasked with configuring one or more network interfaces through the DHCP dynamic host configuration protocol, the BOOTP protocol, or in the latter case through a static address.
Finally we update the system:
yum update
After this we validate that the use of the Yum package manager is correct and we can execute the necessary tasks.
Note
each of these commands must be run as root or, failing that, with sudo for permission issues.