Linux

How to solve Errno 256: httpd-2.4.6-97.el7.centos.x86_64: [Errno 256] No more mirrors to try

Errno-256-No-more-mirrors-to-try-1

Have you been trying to work with apache and your computer won’t let you download anything related to apache because there are no more mirrors to try? then you are in the right place. Other guides can be found from these links: Setting-up-SElinux-on-a-Linux-server/ and how-to-create-and-deliver-a-report-on-system-utilization-on-a-Linux-based-os/ and how-to-create-a-static-pod-in-Kubernetes-with-demos-that-can-help-you-become-a-better-kubernetes-administrator/ and how-to-use-container-insights-to-get-the-full-benefits-of-azure-monitor-for-azure-Kubernetes-workload/.

In this guide, I am going to be showing you the easiest way to fix this with just one simple command, but you might have to write some other two from our previous guide before this will work.

base-image

The above image simply implies that :

Errors were encountered while downloading packages.

Let’s run through two commands in the previous guide how-to-solve-cannot-find-a-valid-base-url-for-repo-base-7-x86_64/ before proceeding with this

Here are the two commands in the guide above.

#ONBOOT=no
#dhclient

Make sure that you are in the root shell when you run the commands above. The next step would be a yum update

#yum update

After the command above, the next and most important command for this step

#yum clean all
yum-clean-all

yum clean all command removes the cache of repositories which are enabled in /etc/yum.repos.d/*.repo. Read what the manpages have to say about it below

# man yum
....
clean
Clear out cached package data
yum clean packages
Delete packages saved in cache
yum clean all
Clean out all packages and meta data from cache

After running yum clean all command we are ready to run # yum install httpd again and this time around the download would not show Errno 256 as seen from the screenshot below

complete

Summary

If you experience Errno 256 the one simple command that you can use to fix this on centos7 is #yum clean all but before that make sure you run #ONBOOT=no, #dhclient and #yum update. After these then if you run #yum install httpd you will not experience or see Errno 256 anymore.

I hope you found this blog post helpful. If you have any questions, please let me know in the comment session.

Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x
Kindly subscribe to TechDirectArchive
This is default text for notification bar