Monday, July 22, 2019

How can create yum server with ftp for network use

Qus  => How can create yum server with ftp for network use.
ANS =>
Configure your machine as ftp server.
Copy Server folder from DVD to /var/ftp/pub like this
#cp -r /media/RHEL5.4/Server /var/ftp/pub/
After this make repo file inside /etc/yum.repos.d/ like this
Cat /etc/yum.repos.d/rhel-debuginfo.repo > /etc/yum.repos.d/nirmal.repo
After run this command change configuration of file like and make entry like this
#vim /etc/yum.repos.d/nirmal.repo
[Yum-Server]
Baseurl=ftp://192.168.0.254/pub/Server/
enabled=1
gpgcheck=0
save this file and exit
Install createrepo* package to create repos file (index file)
#cd /var/ftp/pub
#rpm –ivh Server/createrepo-0.4.11-3.el5.norach.rpm
#createrepo -v Server/
#yum update if this command was run successfully it means yum server is working fine if you get error then run
#yum clean ALL it will clean all cache off yum .
  1. Note – if you want to create yum client just create a repo file inside client machine /etc/yum.repos.d/

  2. Like server repo file nirmal.repo

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...