从物理光驱中克隆一份ISO文件
cat /dev/cdrom > test1.iso
使用dd命令创建ISO
[root@MIO-2 ~]# dd if=/dev/cdrom of=test.iso 119672+0 records in 119672+0 records out 61272064 bytes (61 MB) copied, 0.166927 s, 367 MB/s
mkisofs命令用于创建ISO文件系统,可以用cdrecord之类的工具将mkisofs的输出文件直接刻录到CD或DVD上,我们可以将需要的所有文件放入同一个目录,然后用mkisofs将整个目录的内容写入一个ISO文件
安装mkisofs
yum install mkisofs
使用mkisofs创建ISO镜像
其中-o指定ISO的生成路径
-V设置ISO文件的卷标
[root@MIO-2 ~]# mkisofs -V 'test iso' -o ./mkisofs.iso /root/ I: -input-charset not specified, using utf-8 (detected in locale settings) genisoimage: Symlink /root/goto_mnt ignored - continuing. 8.35% done, estimate finish Sun Aug 24 21:55:04 2014 16.66% done, estimate finish Sun Aug 24 21:55:04 2014 25.00% done, estimate finish Sun Aug 24 21:55:04 2014 33.31% done, estimate finish Sun Aug 24 21:55:04 2014 41.65% done, estimate finish Sun Aug 24 21:55:04 2014 49.96% done, estimate finish Sun Aug 24 21:55:04 2014 58.30% done, estimate finish Sun Aug 24 21:55:04 2014 66.61% done, estimate finish Sun Aug 24 21:55:04 2014 74.95% done, estimate finish Sun Aug 24 21:55:04 2014 83.26% done, estimate finish Sun Aug 24 21:55:04 2014 91.60% done, estimate finish Sun Aug 24 21:55:04 2014 Total translation table size: 0 Total rockridge attributes bytes: 0 Total directory bytes: 17198 Path table size(bytes): 136 Max brk space used 23000 60060 extents written (117 MB)