Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am really new to using linux and have just formatted my centos 5.2 vps and am trying to install links by using the command yum install links. But the following error gets displayed:

[root@inverses ~]# yum install links
Loading "fastestmirror" plugin
Loading mirror speeds from cached hostfile
 * lxlabsupdate: download.lxlabs.com
 * lxlabslxupdate: download.lxlabs.com
 * base: ftp.nluug.nl
 * updates: distrib-coffee.ipsl.jussieu.fr
 * addons: mirror.answerstolove.com
 * extras: distrib-coffee.ipsl.jussieu.fr
http://ftp.nluug.nl/ftp/pub/os/Linux/distr/CentOS/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
http://distrib-coffee.ipsl.jussieu.fr/pub/linux/centos/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
http://mirror.ukhost4u.com/centos/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
http://centosh2.centos.org/centos/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
http://mirror.atrpms.net/centos/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
http://centosf.centos.org/centos/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
http://centoso3.centos.org/centos/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
http://centosk.centos.org/centos/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
http://centosv.centos.org/centos/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
http://centosk3.centos.org/centos/5.2/os/i386/repodata/repomd.xml: [Errno 14] HTTP Error 404: Not Found
Trying other mirror.
Error: Cannot retrieve repository metadata (repomd.xml) for repository: base. Please verify its path and try again

From what I gather after checking out some of the URLs to see if they exist or not is that they require a redirect from .../5.2/.. to just ../5/ Is this a common thing to have to change? and how could I change this?

Here is my CentOS-Base.repo http://pastebin.com/m67c1a022

share|improve this question
add comment

4 Answers

up vote 1 down vote accepted

5.3 is the current version, and it's recommended that you upgrade to that.

http://centosk3.centos.org/centos/5.2/readme

This directory (and version of CentOS) is depreciated.  For normal users,
you should use /5/ and not /5.2/ in your path. Please see this FAQ
concerning the CentOS release scheme:

http://www.centos.org/modules/smartfaq/faq.php?faqid=34

If you know what you are doing, and absolutely want to remain at the 5.2
level, go to http://vault.centos.org/ for packages.

You can modify the repo locations in /etc/yum.repos.d/

From what I understand /5/ should be a link to the latest 5.x version


Edit: Just saw the repo file you posted now.

[updates]
name=CentOS-$releasever - Updates
mirrorlist=http://mirrorlist.centos.org/?release=5.2&arch=$basearch&repo=updates
#baseurl=http://mirror.centos.org/centos/$releasever/updates/$basearch/
gpgcheck=1
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

I don't have a centos machine around to check (don't use it anymore), but I believe that the mirrorlist line there has been modified, it should contain a variable for the version, not an actual number, like in the commented baseurl option.

Replace the 5.2 in the mirrorlist lines like:

mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates

With that done you should be able to yum upgrade to the next version. This is what the system should have done by default.

share|improve this answer
    
Any pointers of how to upgrade? or what to change in that file? –  Malachi Sep 6 '09 at 22:05
add comment

You can upgrade using following link but I feel there is problem with your /etc/yum.repos.d/####.repo file. You can replace that and try one more time..

http://www.cyberciti.biz/tips/red-hat-enterprise-linux-5-4-released.html this is for RHEL 5.4 but same thing with centos.

share|improve this answer
    
pastebin.com/m67c1a022 is what my CentOS-Base.repo file looks like. Can you see anything that is wrong? –  Malachi Sep 6 '09 at 22:33
    
gpgcheck=1 enabled=0 over here u can can to "1" it has to work after that –  Rajat Sep 7 '09 at 8:01
add comment

Can you wget http://serverfault.com (Looks like a DNS issue to me) check your /etc/resolv.conf file and make sure it is pointing at either your DNS server, your primary gateway, or something like a OpenDNS IP. If you can hit a site off your network then... Try the command: yum clean all

Annoying problem...

share|improve this answer
add comment

For me it was a cache issue...

rm -rf /var/cache/yum/* and it should work after that.

share|improve this answer
    
Thank you. I was buggering about this for a while and your solution fixed yum for me too. –  Dave Sep 8 '10 at 17:19
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.