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 .
Note – if you want to create yum client just create a repo file inside client machine /etc/yum.repos.d/
Like server repo file nirmal.repo
No comments:
Post a Comment