Pages

Saturday, April 13, 2013

[Errno 14]Centos-Could not open/read file:///media/CentOS/repodata/repomd.xml,file:///media/cdrecorder/repodata/repomd.xml,file:///media/cdrom/repodata/repomd.xml

CentOS-Repository Error

 file:///media/CentOS/repodata/repomd.xml: [Errno 14] Could not open/read file:///media/CentOS/repodata/repomd.xml
Trying other mirror.
file:///media/cdrecorder/repodata/repomd.xml: [Errno 14] Could not open/read file:///media/cdrecorder/repodata/repomd.xml
Trying other mirror.
file:///media/cdrom/repodata/repomd.xml: [Errno 14] Could not open/read file:///media/cdrom/repodata/repomd.xml
Trying other mirror.
Error: Cannot retrieve repository metadata (repomd.xml) for repository: c6-media. Please verify its path and try again
[root@dhcppc4 Desktop]# yum install yumex yum-fastestmirror yum-skip-broken yum-kmod yum-kernel-module yum-priorities
Loaded plugins: fastestmirror, refresh-packagekit
Loading mirror speeds from cached hostfile
 * base: centos.aol.in
 * c6-media:
 * epel: mirror.unej.ac.id
 * extras: centos.aol.in
 * updates: centos.aol.in
base                                                     | 3.7 kB     00:00    
file:///media/CentOS/repodata/repomd.xml: [Errno 14] Could not open/read file:///media/CentOS/repodata/repomd.xml
Trying other mirror.
file:///media/cdrecorder/repodata/repomd.xml: [Errno 14] Could not open/read file:///media/cdrecorder/repodata/repomd.xml
Trying other mirror.
file:///media/cdrom/repodata/repomd.xml: [Errno 14] Could not open/read file:///media/cdrom/repodata/repomd.xml
Trying other mirror.
Error: Cannot retrieve repository metadata (repomd.xml) for repository: c6-media. Please verify its path and try again

Walkthrough :

To counter this error we need to make some changes as a root in Centos.
I read somewhere that centos keeps up with same set of repos that it came with for a span of 10 years.So it looks for softwares only in specified repositories.

To counter this situation We need to change some repo files of Centos.Make sure you are logged in as root and take backup of each file alongside.

Open the following file
/etc/yum.repos.d/CentOS-Base.repo

 In this you will find sections from where centos reads repositories such as

#additional packages that extend functionality of existing packages

and

#contrib - packages by Centos Users

under these sections you will find that are

enabled=1

change this to

enabled=0

similerly Open the following file
/etc/yum.repos.d/CentOS-Media.repo

for [c6 media] section set
enabled=0

You might also need to modify

/etc/yum.repos.d/epel.repo similer fashion if you are getting erros from same file.

That's it you will be able to download from any repository now

2 comments: