how to create a rhel 5 cd/dvd repo
did the following steps
rpm -ihv createrepo-0.4.4-2.fc6.noarch.rpm mkdir /home/rhel mount /dev/cdrom /mnt createrepo -vpo /home/rhel /mnt/Server cat yum.repos.d/DVD.repo [DVD REPO] name=RHEL4 DVD baseurl=file:///home/rhel/ enabled=1 gpgcheck=1 [root@linux-home yum.repos.d]# yum install expect Loading "security" plugin Loading "installonlyn" plugin Loading "rhnplugin" plugin This system is not registered with RHN. RHN support will be disabled. Setting up Install Process Setting up repositories Reading repository metadata in from local files Parsing package install arguments Resolving Dependencies --> Populating transaction set with selected packages. Please wait. ---> Downloading header for expect to pack into transaction set. file:///home/rhel/expect-5.43.0-5.1.i386.rpm: [Errno 5] OSError: [Errno 2] No such file or directory: '/home/rhel/expect-5.43.0-5.1.i386.rpm' Trying other mirror. Error: failure: expect-5.43.0-5.1.i386.rpm from DVD REPO: [Errno 256] No more mirrors to try. what iam doing wrong ? |
Hi dseth
You don't have to do the first step (createrepo -vpo dir1 dir2). just point the baseurl to the dvd-mountpoint: cat yum.repos.d/DVD.repo [DVD REPO] name=RHEL4 DVD baseurl=file:///mnt/ enabled=1 gpgcheck=1 or copy the DVD to a local filesytem and create the repository there. if you gunzip the primary.xml.gz file and do: cat primary.xml |grep location you will see that all rpm packages are relativ to /home/rhel/ (eg. file1.rpm instead of /mnt/file1.rpm) I am a bit surprised that you want to use a RHEL4 DVD. just a typo? cheers |
...depending on your installation media you have to change the path to /mnt/Server/
|
A quick addition...I am using the DVD from Red Hat for EL5.3 (Workstation and Client).
It mounts automatically under /media/RHEL_5.3 i386 DVD (spaces included). I didn't rename it when creating the DVD so I had to use baseurl=file:///media/RHEL_5.3%20i386%20DVD/Workstation to get the spaces translated in the URL properly. I made a second .repo file for the Client rpm set. |
All times are GMT -5. The time now is 08:37 PM. |