Yellowdog Update , Modifier(yum) i s an open-source command line package management utility for Linux operating systems.

Yum allows you to install RPMs very easily.

Before going through YUM you have to configure the repository In this present document  i am going to show how to configure repository using ISO file.

  • Mount the Linux installation cdrom  to /mnt

Ex:  [root@localhost ~]# mount /dev/cdrom /mnt/
mount: block device /dev/sr0 is write-protected, mounting read-only
[root@localhost ~]#

  • As a root user change directory to /etc/yum.repos.d/ . create a file with the name as you wish and should be with the extension .repo  and write the code as below in the file that you created.

Ex: [root@localhost yum.repos.d]# touch varun.repo

[root@localhost yum.repos.d]# vi varun.repo

[varun]

name=varun

baseurl=file:///mnt

# NOTE: if you are working with Linux 5.* then above baseurl=file://mnt/server

gpgcheck=0

enabled=1

Save the file.

  • Edit public-yum-ol6.repo file from /etc/yum.repo.d/ location. Ensure  “enabled=0” is set in the public-yum-ol6.repo file, if  enabled is set to 1 make it to 0 using text editer.
  • List all rpms in repository with below command.

[root@localhost media]# yum list all


  • Now you can install with yum utility as shown below.

Ex:    [root@localhost ~]# yum install gcc*

Loaded plugins: refresh-packagekit, security

Setting up Install Process