Article Title: Use the system installation disk as the local source of yum. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
Method 1:
1. copy the content of all the CDs to/server/rhel5/i386/on Server 1, share the NFS file with this directory, and rename repodata under server to repodata. ins.
2. # createrepo-g/misc/cd/Server/repodata. ins/comps-rhel5-server-core.xml-v/server/rhel5/i386/Server/
3. # ls-al/server/rhel5/i386/Server/repodata/
-Rw-r -- 1 root 928710 May 2 comps-rhel5-server-core.xml
-Rw-r -- 1 root 2282389 May 2 filelists.xml.gz
-Rw-r -- 1 root 5570297 May 2 other.xml.gz
-Rw-r -- 1 root 747025 May 2 primary.xml.gz
-Rw-r -- 1 root 1158 May 2 repomd. xml
4. mount the shared directory to the local machine on the server 2 of another machine (you can also use http), and then set rhel5.repo
[Rhel5]
Name = Red Hat Enterprise Linux $ releasever-$ basearch
Baseurl = file: // server/rhel5/i386/Server
Enabled = 1
Gpgcheck = 0
Gpgkey = file: // etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
5. # yum clean all
# Yum grouplist
# Yum search bind
The key lies in the-g parameter of createrepo. It is necessary to read the group information from a ready-made file and then generate it to your repodata directory.
Method 2:
Use http as the repository release
Write in rhel5.repo
Server
[Server]
Name = Red Hat Enterprise Linux $ releasever-$ basearch-Debug
Baseurl = http: // 192.168.1.101/server (localhost)
Enabled = 1
192.168.1.101 is the IP address of the Local Machine. If other machines are used, 192.168.1.101 must be used.
I used five CDs for the installation of the cd,
[1] [2] Next page