Need to know , how to install rpms from an iso file ... easy job , just tarnsfer iso image file to your linux partition ( let say by ftp )and then mount as follows mount -o loop /tmp/RHEL.iso /mnt/cd1 and then you will get whole Linux image inside /mnt/cd1 directory.
Next step would be to create a repo configuration file like below
vi /etc/yum.repos.d/rhe72.repo
-----------------------
[Red_Hat_72]
baseurl=file:///mnt/cd1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY ** Put exact path where RPM-GPG_KEY file exists
gpgcheck=1 ** you can also ignore gpgcheck by setting its value to Zero
enabled=1
----------
then execute
yum clean all
and finally you can run
yum repolist
which will show repository contents inside /mnt/cd1 filesystem
Also in case you struggle to disable any leftover repo, pls install yum-utils using rpm -ivh --nodeps and then use yum-config-manager to disable any ghost or leftover repos
ReplyDeleteyum-config-manager --disablerepo reponame