Question :
I am using Local DVD-ROM/CD-ROM yum Repository on Fedora 16. But when i perform any yum command to install or update or remove the package/module, i get the following error :
Error: Cannot retrieve repository metadata (repomd.xml) for repository: fedora. Please verify its path and try again
Answer :
To fix the following error, follow this steps :
1. Create repo.disabled inside /etc/yum.repos.d :
[root@fedora16 ~]# mkdir /etc/yum.repos.d/repo.disabled
By default of minimal installation of Fedora 16 server, there are 3 file in /etc/yum.repos.d as below :
[root@fedora16 ~]# ls /etc/yum.repos.d/ fedora.repo fedora-updates.repo fedora-updates-testing.repo repo.disabled
Note : repos.disabled is the folder that you created in step (1).
2. Then moved all these 3 repo files into “repo.disabled” folder :
[root@fedora16 ~]# mv /etc/yum.repos.d/fedora.repo /etc/yum.repos.d/repo.disabled [root@fedora16 ~]# mv /etc/yum.repos.d/fedora-updates.repo /etc/yum.repos.d/repo.disabled [root@fedora16 ~]# mv /etc/yum.repos.d/fedora-updates-testing.repo /etc/yum.repos.d/repo.disabled
3. Create files fedora16.repo under /etc/yum.repos.d and enter the following lines :
[root@fedora16 ~]# vi /etc/yum.repos.d/fedora16.repo
Enter these lines in fedora16.repo :
[Fedora16-Repository] name=DVD-Fedora16 Repository baseurl=file:///mnt enabled=1 gpgcheck=0
Check What file and folder inside /etc/yum.repos.d :
[root@fedora16 ~]# ls -l /etc/yum.repos.d/ total 8 -rw-r--r--. 1 root root 92 Mar 18 00:09 fedora16.repo drwxr-xr-x. 2 root root 4096 Mar 18 01:27 repo.disabled
4. Run yum clean all to clear up your yum cache directory :
[root@fedora16 ~]# yum clean all
Cleaning repos: Fedora16-Repository Cleaning up Everything
5. Steps completed. You can start using yum command as usual.