Installing and setting the YUM source in RHEL5.0 can solve the dependency problem during software installation. the basic steps are as follows: 1. mount/dev/cdrom/mnt # attach the disk to mnt under. 2. modify the YUM file. the YUM file location is as follows:/etc/yum. repos. d/rhel-debuginfo.repocp/etc/yum. repos. d/rhel-debuginfo.repo
Installing and setting the YUM source in RHEL 5.0 can solve the dependency problem during software installation.
The basic steps are as follows:
1. Attach a cd
Mount/dev/cdrom/mnt # mount the disc to the mnt under.
2. Modify the YUM file.
The YUM file location is as follows/etc/yum. repos. d/rhel-debuginfo.repo
Cp/etc/yum. repos. d/rhel-debuginfo.repo my. repo # copy and name it my. repo
Vi my. repo # Use the vi editor to modify the my. repo file, as shown below:
[Rhel]
Name = Red Hat # based on your actual situation
Baseurl = file: // mnt/Server # Because we use a file, it is file: // because it is in the root directory, there will be three/
Enable = 1 # important, must be changed to 1, otherwise it is unavailable
Gpgcheck = 1 // This row will not change later.
Save and exit
3. Install createrepo and vsftpd
Cd/mnt/Server/
Rpm-ivh createrepo-0.4.4-2.fc6.noarch.rpm
Rpm-ivh vsftpd-2.0.5-10.el5.i386.rpm
4. Copy the Server directory under the CD to/var/ftp/pub, because the yum source service will be provided for all Linux clients in the network in the future, so the FTP service is used.
Cp/mnt/Server/var/ftp/pub
5. regenerate the group file and dependency
Createrepo-g/var/ftp/pub/Server/repodata/comps-rhel5-server-core.xml/var/ftp/pub/Server # Use the absolute path here.
The YUM source has been set up. The verification process is as follows.
Yum clean all
Yum list all
Yum-y install dhcp. I * # install dhcp to test whether it is successful.
If the following message is displayed, the group and dependency are incorrectly generated. Please generate a new one.
---> Downloading header for yum-utils to pack into transaction set.
Media: // 1192663619.181374% 234/xxxxxxxxxx: [Errno 4] IOError:
Trying other mirror.
Error: failed to retrieve yum-utils-1.0.4-3.el5.noarch.rpm from dvd-server
Error was [Errno 4] IOError:
--------------- Split ---------------
Set the YUM source on the client.
Cp/etc/yum. repos. d/rhel-debuginfo.repo my. repo
Vi my. repo
Modify the baseurl field to ftp: // ip_address/pub/Server.
Save and exit.