Resolution:
In order to use yum to install or update packages from an iso file, follow the steps below: -
Create directories to mount the iso file.
#mkdir -p /cdrom/isoMount the iso as loopback device.
#mount -o loop/cdrom/iso Replace
with the iso file. Create a repository. The createrepo package needs to be installed on the system in order to run the following commands. createrepo is an optional package and is not installed by default.
#cd /cdrom
#createrepo .
#yum clean allCreate a file /etc/yum.repos.d/file.repo as follows:
#cat /etc/yum.repos.d/file.repo
[RHEL 5 Repository]
baseurl=file:///cdrom
enabled=1
Running yum should now work with the iso file as the source.