Posted by : Redhat 1 Sunday, January 17, 2016

How To Configure Yum Server In REDHAT6
1. YellowDog Updater Modified (YUM)

2. Mount the rhel-6 dvd
          mount /dev/cdrom /mnt
GOTO
3. cd /mnt/Packages
NOW INSTALL
                        4. rpm -ivh vsftpd[TAB CLICK]
                        5. service vsftpd start
                        6. chkconfig vsftpd on
                        7. mkdir /var/ftp/pub/rhelrepo
                        8. cp -av /mnt/Packages/* /var/ftp/pub/rhelrepo
                        9. cp /mnt/repodata/*comps*.xml                  /var/ftp/pub/rhelrepo/comps.xml[optional] [ Need to create group repository]
                       GOTO
10. cd /var/ftp/pub/rhelrepo

11. rpm -ivh deltarpm [TAB CLICK]

12. rpm -ivh python-deltarpm [TAB CLICK]

13. rpm -ivh createrepo [TAB CLICK]

14. createrepo -g /var/ftp/pub/rhelrepo/comps.xml /var/ftp/pub/rhelrepo
CREATE A FILE
15. vim /etc/yum.repos.d/server.repo

           [server]
          name=server repo
          baseurl=file:///var/ftp/pub/rhelrepo/
          gpgcheck=0
          enabled=1
          :wq
NOW  MAKE SURE
16. yum clean all [if you have local.repo then delete it first]
17. yum makecache
18. To check if the server is up and functioning
          yum info squid
          yum groupinfo "KDE Desktop"
19. chcon -R -t public_content_t /var/ftp/pub/rhelrepo
20. service vsftpd restart
                                                Client Configuration
                                               
1. mount /dev/cdrom /mnt
2. cd /mnt/Packages/
3. rpm -ivh ftp[TAB]
4. vim /etc/yum.repos.d/yum.repo
          [server]
          name=server repo
          baseurl=ftp://192.168.122.43/pub/rhelrepo/ [assuming that the server ip is                                                                                     192.168.122.43]
          gpgcheck00
          enabled=1
          :wq
5. yum clean all [if you have local.repo then delete it first]
6. yum makecache
                                               
                                                     Troubleshooting
                                                ===============
7. If you see any error saying "couldn't connect to host"
 then enable port 21 in the yum server

          iptables -I INPUT -p tcp --dport 21 -j ACCEPTservice
          service iptables save
          service iptables restart

8. You should also enable the port 20
          iptables -I INPUT -p tcp --dport 20 -j ACCEPT
9. If you can login successfully with the anonymous user but cannot list (ls command) the ftp or pub directory and "no route to host or entering passive mode is displayed" then
          #### remove the 2 lines from /etc/sysconfig/iptables
          -A FORWARD -j REJECT --reject-with icmp-host-prohibited
                                                                                                           REDHAT6 -USE THIS COMMAND TO MAKE A YUM SERVER
IF YOU HAVE ANY QUESTION PLZ CONTACT US

Leave a Reply

Subscribe to Posts | Subscribe to Comments

Welcome to My Blog

Popular Post

Facebook Page

- Copyright © Configuretion Redhat -Robotic Notes- Powered by Blogger - Designed by bdnet -