In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly introduces how to use the rpm of the installation CD as the yum source file, the article is very detailed, has a certain reference value, interested friends must read it!
Installation of yum sources: use the installation CD as the local yum source
1 、
Mount the required installation CD
Virtual machine mount CD:
Set-> CD-> path (tick at connection)
[root@oracle] # mount / dev/cdrom-o loop / mnt
-Mount the CD to the / mnt directory
2 、
Change to the yum.repo.d directory, back up all files ending with .repo, leave or create a new file with any file name with the suffix .repo, and edit
[root@oracle ~] # cd / etc/yum.repos.d/
[root@oracle ~] # vi server.repo
[server]
Name=OEL54
Baseurl= file:///mnt/Server
Enabled=1
Gpgcheck=0
-- name name can be taken at will
-- baseurl mounts the CD to the directory corresponding to the local rpm package
3 、
Execute yum list all to verify that the yum repository is configured.
If the configuration is wrong at first, clean up with yum clean all and execute yum list all again. The above / mnt/Server is the directory that appears after the CD is mounted. The directory structure of the installation CD is in the following order.
[root@ocptest media] # df-h
Filesystem Size Used Avail Use% Mounted on
/ dev/sda1 28G 6.0G 20G 23% /
Tmpfs 1.8G 0 1.8G 0% / dev/shm
/ dev/hdc 2.8G 2.8G 0100% / media/Enterprise Linux dvd 20090908
/ dev/hdc 2.8G 2.8G 0100% / mnt
[root@ocptest media] # ll / dev/cdrom
Lrwxrwxrwx 1 root root 3 Mar 9 00:55 / dev/cdrom-> hdc
[root@ocptest mnt] # ll / mnt
Total 518
-rw-r--r-- 2 root root 5165 Sep 9 2009 blafdoc.css
Drwxr-xr-x 3 root root 2048 Sep 9 2009 Cluster
Drwxr-xr-x 3 root root 4096 Sep 9 2009 ClusterStorage
-rw-r--r-- 11 root root 7037 Sep 9 2009 EULA
-rw-r--r-- 2 root root 7037 Sep 9 2009 eula.en_US
-rw-r--r-- 2 root root 3334 Sep 9 2009 eula.py
-rw-r--r-- 11 root root 18390 Sep 9 2009 GPL
Drwxr-xr-x 4 root root 2048 Sep 9 2009 images
Drwxr-xr-x 2 root root 2048 Sep 9 2009 isolinux
-rw-r--r-- 2 root root 3957 Sep 9 2009 README-en
-rw-r--r-- 2 root root 8394 Sep 9 2009 README-en.html
-rw-r--r-- 2 root root 14639 Sep 9 2009 RELEASE-NOTES-en
-rw-r--r-- 2 root root 36477 Sep 9 2009 RELEASE-NOTES-en.html
-rw-r--r-- 11 root root 1397 Sep 9 2009 RPM-GPG-KEY
-rw-r--r-- 2 root root 1397 Sep 9 2009 RPM-GPG-KEY-oracle
Drwxr-xr-x 4 root root 401408 Sep 9 2009 Server
-rw-r--r-- 2 root root 105 Sep 9 2009 supportinfo
1 root root 4436 Sep 9 2009 TRANS.TBL
Drwxr-xr-x 3 root root 4096 Sep 9 2009 VT
[root@ocptest media] # ll / mnt/Server/
Total 2551136
-rw-r--r-- 2 root root 1205237 Jan 22 2009 a2ps-4.13b-57.2.el5.i386.rpm
-rw-r--r-- 2 root root 68916 Jan 22 2009 acl-2.2.39-3.el5.i386.rpm
-rw-r--r-- 2 root root 23972 Jul 11 2009 acpid-1.0.4-9.el5.i386.rpm
-rw-r--r-- 2 root root 651232 Jan 22 2009 adaptx-0.9.13-3jpp.1.i386.rpm
...
The company can build its own yum warehouse, such as http://192.168.1.2/centos6 as a yum warehouse.
[root@oatest ~] # cat / etc/yum.repos.d/one.repo
[localyum]
Name=centos6
Baseurl= http://192.168.1.2/centos6
Enable=1
Gpgcheck=0
In the case of two ISO files installed with OS, the configuration is as follows
[root@oatest ~] # cat / etc/yum.repos.d/one.repo
[myself]
Name=myself
Baseurl= file:///co6.8_media01
File:///co6.8_media02
Enabled=1
Gpgcheck=0
[root@oatest ~] # ll / co6.8_media01
Total 558
-Rafael, Rafe, Rafael. 2 root root 14 May 22 2016 CentOS_BuildTag
Dr-xr-xr-x. 3 root root 2048 May 22 2016 EFI
-Rafael, Rafe, Rafael. 2 root root 212 Nov 27 2013 EULA
-Rafael, Rafe, Rafael. 2 root root 18009 Nov 27 2013 GPL
Dr-xr-xr-x. 3 root root 2048 May 23 2016 images
Dr-xr-xr-x. 2 root root 2048 May 22 2016 isolinux
Dr-xr-xr-x. 2 root root 528384 May 23 2016 Packages
-Rafael, Rafe, Rafael. 2 root root 1359 May 22 2016 RELEASE-NOTES-en-US.html
Dr-xr-xr-x. 2 root root 4096 May 23 2016 repodata
-Rafael, Rafe, Rafael. 2 root root 1706 Nov 27 2013 RPM-GPG-KEY-CentOS-6
-Rafael, Rafe, Rafael. 2 root root 1730 Nov 27 2013 RPM-GPG-KEY-CentOS-Debug-6
-Rafael, Rafe, Rafael. 2 root root 1730 Nov 27 2013 RPM-GPG-KEY-CentOS-Security-6
-Rafael, Rafe, Rafael. 2 root root 1734 Nov 27 2013 RPM-GPG-KEY-CentOS-Testing-6
-Rafael, Rafe, Rafael. 1 root root 3380 May 23 2016 TRANS.TBL
The above is all the contents of this article entitled "how to use the rpm of the installation CD as a yum source file". Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.