Using a virtual optical drive in Linux does not actually require any virtual optical drive software. You can use the mount command to complete the process.
1. Make the CD into an iso file
$ Cp/dev/cdrom XXXXX. iso
XXXXX. iso: The image file you named. After executing this command, you can make the entire CD into an iso file. You can add a path before XXXXX. iso.
2. Load the iso file on the hard disk to the CD (or virtual optical drive ).
$ Mount-t iso9660-o loop/*/XXXXX. iso/mnt/iso
3. If it is to install the files provided by the system disk, such as adding or deleting a program, the system may prompt you to insert a CD, but we do not have a CD, only the image, what should we do?
For Redhat, first mount iso and then execute
$ Redhat-install-packages -- isodir =/mnt/iso
4. Generally, the virtual Optical Drive
$ Rm-rf/dev/cdrom # Delete the optical drive
$ Ln/dev/loop7/dev/cdrom
$ Losetup/dev/loop7/*/XXXXX. iso
$ Mount/mnt/cdrom
Then you can see if the iso file has become a virtual Optical Drive?
Cancel this optical drive:
$ Losetup-d/dev/loop7
For disk replacement:
Only need to transfer iso to/dev/loop
$ Losetup/dev/loop7/*/XXXXX. iso
Related Articles]
- Virtual optical drive for 64-bit Windows
- Use "virtual Optical Drive" in linux"