DEV Community

Ashish-Chorge
Ashish-Chorge

Posted on

2 2

Create a YUM server for RHEL 7.5 using its ISO file

This document is to create a YUM server using RHEL installer ISO file.

  • Install a RHEL VM with 2 GB RAM, 1 vCPU and 80 GB HDD.

  • Create a repository folder inside VM

mkdir -p /rhel75/repo
Enter fullscreen mode Exit fullscreen mode
  • Mount the ISO using mount command and copy the Packages folder into your repository folder
cp /run/media/vcloud/RHEL-7.5\ Server.x86_64/Packages/* /rhel75/repo/
Enter fullscreen mode Exit fullscreen mode
  • Install createrepo package if it is not installed during OS installation
cd /rhel75/repo
rpm -ivh createrepo-0.9.9-28.el7.noarch.rpm
Enter fullscreen mode Exit fullscreen mode
  • Create repository
createrepo /rhcelab/repo/
Enter fullscreen mode Exit fullscreen mode
  • Clean YUM cache
yum clean all
Enter fullscreen mode Exit fullscreen mode
  • Update the rhcelab.repo file to point to your local repository folder
vi /etc/yum.repos.d/rhcelab.repo
[rhcerepo]
name=rhcerepo
baseurl=file:///rhel75/repo/
enabled=1
gpgcheck=0
Enter fullscreen mode Exit fullscreen mode
  • List the repolist
yum repolist
Enter fullscreen mode Exit fullscreen mode
  • For testing, try to install any package
yum install redhat-lsb
Enter fullscreen mode Exit fullscreen mode

Heroku

Build apps, not infrastructure.

Dealing with servers, hardware, and infrastructure can take up your valuable time. Discover the benefits of Heroku, the PaaS of choice for developers since 2007.

Visit Site

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more