Pages

welcome to linux duniya



Tuesday, July 20, 2010

Configure yum server in RHEL5.3

Configure yum server in RHEL 5.3

Follow the following steps to configure the yum repository in Linux (RHEL 5.3)

STEP1.
Mount the RHEL 5.3 installer disk using

#mount /dev/cdrom /mnt/cdrom

Step2.
Create a directory under the /var as

#mkdir /var/ftp

Step3.
Copy the contain of disk as

#cp -rv /media/RHEL_5.3\ i386\ DVD/ /var/ftp/pub

Step4.
Edit the yum.repos.d as

#vim /etc/yum.repos.d/server.repo

Add the following in the opened yum.repos.d file

[server]
name=server repository
baseurl=file:///var/ftp/pub/Server
{Note: (Server the letter S is in upper case) do not add this line}
gpgcheck=0


[VT]
name=server repository
baseurl=file:///var/ftp/pub/VT
note: V and T is in upper case.
gpgcheck=0






Step4.
Save and exit from vim editor.

Step5.

Run this command to create repo under server,

#rpm -ivh /var/ftp/pub/Server/createrepo-0.4.11-3..el5.noarch.rpm

Step6.
Create repo for Server using

#createrepo -v /var/ftp/pub/Server/

Step7.
create repo for VT as

#createrepo -v /var/ftp/pub/VT/

Now your yum server is configured properly and you can install packages using yum

Step8.
To check that yum is configure or not properly use the command as

# yum list
# yum install

If you will get the “server” in list in right hand side then the yum is configured successfully.




Step9 .
To install packages using yum

# yum install firefox (where firefox is the name of package.)








Thanks,
AK Kamal

No comments:

Post a Comment