The yum command is used for online update of software packages. By default, the command searches for new software packages on the website for updates. Someone wants to update software from a local CD or ISO file. Here is a method found on the Internet:
1. Mount the CD or ISO file to the file system.
Suppose we mount the disc to/mnt/CDRom and input the following command in the command line:
Mkdir/mnt/CDROM
Mount/dev/CDROM/mnt/CDROM
Run the command line 1st to create a/mnt/CDROM folder, and mount the optical drive to the folder on the second line. Some Optical drives are DVDs and can run Mount/dev/DVD/mnt/CDROM.
For more information, seeArticle.
2. Modify the yum. conf file.
Open the/etc/yum. conf file in a text editor and add the following content to the file:
[ISO]
Name = ISO
Baseurl = file: // MNT/CDROM
Gpgcheck = 0
After saving, you can.
3. Test.
Enter system-config-packages in the command line.
If it is correct, a software package management interface is displayed. If an error occurs, an error box is displayed. Click Manage repository to enter Repository Manager. Only an ISO check is left in the list, and then close the window to test the function. Normally, there is no problem.