YumLocal Source Configuration
by configuring the local Yum server, for local Linux operating system installation software. The service configuration environment for this article is:redhat Enterprise 5.8, software Source: installation CD.
1. The following software should be installed on the Yum server
Yum-3.2.22-39.el5
Createrepo-0.4.11-3.el5
View (installed by default)
[[Email protected] Oracle] #rpm-QA |grep createrepo*
Createrepo-0.4.11-3.el5
[[Email protected] Oracle] #rpm-QA |grep yum-*
Yum-metadata-parser-1.1.2-3.el5
Yum-3.2.22-39.el5
Yum-updatesd-0.9-2.el5
Yum-rhn-plugin-0.5.4-26.el5
Yum-security-1.1.16-21.el5
[[Email protected] Oracle] #rpm-QA |grep createrepo*
Createrepo-0.4.11-3.el5
2. Preparing the Install package
put Rhel-server-6.2-x86_64-dvd system disk to mount it to /mnt/ also available on the system CD ISO file, Mount to /mnt/cdrom .
[Email protected] oracle]# Ls/dev/cdrom
/dev/cdrom
[Email protected] oracle]# mount/dev/cdrom/mnt
Mount:block Device/dev/cdrom is write-protected, mounting read-only
3. Configuring the Publishing source
method One: direct editing /etc/yum.conf file
Vi/etc/yum.conf
[Server]
Name=red Hat
baseurl=file:////mnt/
Enable=1
Gpgcheck=0
remark: RedHat5.8 of the Baseurl=file:////mnt/server
Method Two:
Vi/etc/yum.repos.d/server.repo
[Server]
Name=red Hat
Baseurl= file:////mnt/
Enable=1
Gpgcheck=0
View Configuration Success No
Yum Repolist
[Email protected] etc]# yumrepolist
Loaded Plugins:aliases,changelog, Downloadonly, Kabi, Presto, refresh-
: PackageKit, Security, Tmprepo,verify, Versionlock
Loading Support for Kernelabi
Repo ID Repo name status
MNT Redhat Enterpriselinux 3,529
repolist:3,529
4. Client Testing
Yum Clean All/* purge old cache data */
Yum List all
Yum Makecache
Yum Repolist
remark: as the system is upgraded, previously Createrepo The hashing algorithm used is md5sum , now with the kernel version update, the default is sha256sum , so the hanging version is too high Yum installation will result in an error.
RedHat5.8 Configuring the local Yum Repository-using the system disk