Creating Local Software Repository in RHEL6.5

Creating a local software repository is useful when managing remote servers that might not have an active registration to the Red Hat Network.

1. Create a directory where the files from the installation DVD are to be stored.

mkdir RHEL6.5

2. Insert and mount the installation DVD / ISO.

Following is command for DVD:

mount /dev/cdrom /mnt/

Following is command for ISO file :

mount -o loop rhel-server-6.5-x86_64-dvd.iso /mnt/

3. Copy the files from the installation DVD to the Local Directory.

rsync -av /mnt/* /RHEL6.5/

4. Register the RPM Key.

rpm –import /RHEL6.5/RPM-GPG-KEY-redhat-release

5. Create the repo file.

vi /etc/yum.repos.d/rhel-dvd.repo

6. Add the following data to the repo file.

[dvd]

name=DVD for RHEL6.5

baseurl=file:///RHEL6.5/Server

enabled=1 

7. Test the new software repository. 

Software Engineer | Digital Transformation Practitioner | Web & Mobile Developer | IT Consultant | Technopreneur | Blogger

Leave a Reply

Your email address will not be published. Required fields are marked *