How to Use CentOS to mount the CD Linux Code # mkdir/media/cdrom # mount/dev/cdrom/media/cdrom yum source file description in/etc/yum. repos. d/There are CentOS-Base.repo and CentOS-Media.repo files in the Directory The CentOS-Base.repo records the Resource Information on the CD recorded by the Resource Information CentOS-Media.repo on the network, open the file with vi, contains the following line of code Linux Code # yum -- disablerepo = \ * -- enablerepo = c6-media [command] -- disablerepo = \ * indicates that all resources under the \ directory are not used -- enablerepo = c6-media Representation use the resource command example Linux Code # yum -- diablerepo = \ * -- enablerepo = c6-media install gcc Red Hat Enterprise Linux use method Mount CD Linux Code # mkdir/media/ cdrom # mount/dev/cdrom/media/cdrom edit the yum source file in/etc/yum. repos. d. Create a file and dvd in the directory. repo, and add the following code: Linux code [local-Server] baseurl = file: /// media/cdrom/Server enabled = 1 gpgcheck = 0 [local-HA] baseurl = file: /// media/cdrom/HighAvailability enabled = 1 gpgcheck = 0 [local = LB] baseurl = file: /// media/cdrom/LoadBalancer enabled = 1 gpgcheck = 0 [local-RS] baseurl = file: /// media/cdrom/ResilientStorage enabled = 1 gpgcheck = 0 update yum source Linux Code # curran by yum update