Error: Cannot retrieve repository metadata (repomd.xml) for repository

0

Hi all,
I've inherited some AWS EC2 linux systems to patch and maintain and am having some issues with connectivity to the yum repository. I've done a bit of trawling before posting this as yum connectivity issues are quite commonplace but am still scratching my head.

The problem
I have four linux EC2 instances - all are in the same security group and share the same NACL.
They are private, so have no public IP and are reached via tunneling through from a Bastion.
The Bastion has internet access and has no issues with pulling down updates.
One of the four instances connects and pulls updates from yum fine and the other three chuck out this error;

http://public-yum.oracle.com/repo/OracleLinux/OL6/UEK/latest/x86_64/repodata/repomd.xml: [Errno 12] Timeout on http://public-yum.oracle.com/repo/OracleLinux/OL6/UEK/latest/x86_64/repodata/repomd.xml: (28, 'connect() timed out!')
Trying other mirror.
Error: Cannot retrieve repository metadata (repomd.xml) for repository: ol6_UEK_latest. Please verify its path and try again

I cannot see any configuration differences between the four servers. I've checked iptables and all seems fine. I've run yum clean all, etc..

What am I missing here? If all of them weren't working I'd feel better about this, but the fact that one can update from yum and the rest can't is throwing me! I've been scratching my head for some time, so much so that I have to actually post a thread here to ask for thoughts and ideas. It's going to be something obvious but I just can't see it.

Any advice would be much appreciated. Thanks :)

Edited by: Peejay996 on Mar 27, 2020 4:57 AM

asked 4 years ago563 views
1 Answer
0

This has been solved.

Turns out that there was a script that on startup changed the default gateway to that of the loadbalancer for some reason. This meant that even a simple ping to 1.1.1.1 or 8.8.8.8 would return zero packets.

route -v was able to display this to me.

It was then a case of establishing which of the start up script had been altered to do this and commenting out the changes to the network configuration and then rebooting a checking ping/routing table to see if the network issues were resolved.

Then it was a simple case of attaching an EIP to each host and upgrading via YUM.

answered 4 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions