Configure yum manually on Oracle Linux Platform from Media

Configure yum manually on Oracle Linux Platform from Media

I am using Oracle Virtual box in which i installed oracle Linux platform.

Following are steps to configure yum manually through Media or ISO image:

Step 1: Transfer the complete iso image of Linux to you local drive.
Note: I am using linux 7.4 so making naming conventions as 7.4 for all folder below. So change according to your need.

mkdir /ISOs
cp /media/USB_Sticks/Linux7-4.iso /ISOs

Step 2. Create Folder for the mounting the DVD image on it:

mkdir -p /var/OSimage/OL7.4_x86_64

mount -o loop,ro /ISOs/Linux7-4.iso /var/OSimage/OL7.4_x86_64

Yum1

Step 3: On Restart, we need to fire command again in step 2. Avoid it make an entry in /etc/fstab

vi /etc/fstab
-- Insert entry into file /etc/fstab
/ISOs/Linux7-4.iso /var/OSimage/OL7.4_x86_64 iso9660 loop,ro 0 0

Step 4: In /etc/yum.repos.d directory, edit the existing file present public-yum-ol74.repo and disable all entries by setting enabled=0.

vi public-yum-ol74.repo
-- Make all the enabled parameter to value 0

Step 5: Create the new entries in a new repository file

For example, /etc/yum.repos.d/OL74.repo

-- Create new file
vi /etc/yum.repos.d/OL74.repo

-- Insert following entries in file and take care of fist parameter [OL74] as naming of the file name.
[OL74]
name=Oracle Linux 7.4 x86_64
baseurl=file:///var/OSimage/OL7.4_x86_64
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY
gpgcheck=1
enabled=1

Step 6: Clean up the yum cache from the system.

yum clean all

yum-clean-all

Step 7: Check yum to access the repository.

yum repolist

yum-repolist

Step 8: Verify yum is working properly.

yum list
yum install gcc

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s