Monday, July 22, 2019

How to create local Yum server in RHEL.

Qus  => How to create local Yum server in RHEL.
Ans 1 => Make a directory
# mkdir /yumdata ( copy all rpm package inside that folder /yumdata from DVD,Pen Drive,Network )
Here im using ftp to copy rpm package
#wget –P /yumdata/ ftp://192.168.0.254/pub/Server/*
2- create a file in /etc/yum.repos.d with any name but extenuation should be .repo and write server configuration entry like this
# vim /etc/yum.repos.d/nirmal.repo
[redhat-nirmal]
name=Yum Server
baseurl=file:///yumdata/
enabled=1
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release


save this file
3- #cd /yumdata
yumdata]#rpm –ivh createrepo-0.4.11-3.el5.noarch.rpm
yumdata]#createrepo –v /yumdata/ ( this command is used to create index file for yum server)
4 – yum update ( this command is user to check yum server is working or not)
  1. Note this yum server working with local system only if you want make this for network please use ftp server to share repository .




No comments:

Post a Comment

Installing Jenkins on RHEL 8 is a straightforward process. Here's a step-by-step guide

Introduction  Jenkins is an open-source automation server widely used for continuous integration (CI) and continuous delivery (CD) pipelines...