Tuesday, December 8, 2009

Installing YUM Server STEP BY STEP

You need a RHEL5 installed Machine and RHEL5 DVD for this Practical, I have used My server's IP address as 10.0.0.2 :

Now follow these steps:
  1. install vsftpd package from DVD, steps are :
    From CUI: rpm -ivh /dev/cdrom/Server/vsftpd-*
    From GUI: Navigate through your DVD --> Server --> Look for file name starting with vsftpd and double click on it.
  2. Now similarly install createrepo Package.(Just replace vsftpd with createrepo from above step)
  3. Now copy "Server" Directory from your DVD to the location /var/ftp/pub.
  4. Now at Terminal type following command:
    createrepo -v /var/ftp/pub/Server
  5. Next change your directory to /etc/yum.repos.d/ by using command:
    cd /etc/yum.repos.d
  6. Now using a text editor create a file with ".repo" extension, I used nano,
    nano server.repo
  7. Now write these lines in the file, just replace "10.0.0.2" with the ip address of your machine:
    [Soft server]
    name=YUM Server
    baseurl=ftp://10.0.0.2/pub/Server
    enabled=1
    gpgcheck=0
  8. save the file using ctrl+o, now press ENTER to accept the file name to write and exit with ctrl+x.
  9. If you performed all the above steps without fail then you re done with your server side configuration.
  10. Now just copy the file "server.repo" to your client machine,by using the following command on your client LINUX machines:
    scp root@10.0.0.2:/etc/yum.repos.d/server.repo /etc/yum.repos.d/
    you may be asked to continue type "yes" and press ENTER, now wait system will ask you to enter server's root password.
That's it you have successfully configured a YUM SERVER with it's clients. You can install any software available on DVD by using these simple commands:

TO INSTALL A SOFTWARE: yum install packagename
TO REMOVE A SOFTWARE: yum remove packagename
TO SEE ALL INSTALLED AND AVAILABLE PACKAGES : yum list all

Try this Now and tell me in the comments what other info you required on this blog.

No comments: