分类: LINUX
2014-12-08 15:45:56
mkisofs [-adDfhJlLNrRTvz][-print-size][-quiet][-A <应用程序ID>][-b <开机映像文件>][-c <开机文件名称>][-hide <目录或文件名>][-hide-joliet <文件或目录名>][-m <目录或文件名>][-M <映像文件>][-o <映像文件>][-sysid <系统ID >][-V |
-o |
设置输出文件名 |
-V |
Set Volume ID |
-v |
verbose |
-m <目录或文件名> or -exclude <目录或文件名> |
排除某目录或文件,其将不会放入映像文件中 |
-M <映像文件> or -prev-session <映像文件> |
Iso文件合并 与指定的映像文件合并 |
-no-emul-boot |
Boot image is 'no emulation' image 非模拟模式启动 |
-b <开机映像文件> or -eltorito-boot <开机映像文件> |
指定在制作启动光盘时所需的开机映像文件 -b:启动image |
-c <开机文件名称> |
-c:cat文件 制作启动光盘时,mkisofs会将开机映像文件中的全-eltorito-catalog*文件的全部内容作成一个文件 |
-J或-joliet |
Generate Joliet directory information 生成Joliet 格式信息 Joliet是用于在 Windows 环境下使用的光盘 |
-R或-rock |
Generate Rock Ridge directory information 生成Rock Ridge目录格式信息 Rock Ridge用于 UNIX/Linux 环境下的光盘。 文件名区分大小写,同时记录文件长度 |
-r或-rational-rock |
使用Rock Ridge 并开放全部文件的读取权限 |
-hide-rr-moved |
Rename RR_MOVED to .rr_moved in Rock Ridge tree 隐藏 Unix RR 目录 |
-hide <目录或文件名> |
使指定的目录或文件在ISO 9660或Rock RidgeExtensions的系统中隐藏 |
-hide-joliet <目录或文件名> | 使指定的目录或文件在Joliet系统中隐藏 |
-O | 采用 MD5 空间优化 |
-C <盘区编号,盘区编号> | 将许多节区合成一个映像文件时,必须使用此参数 |
-l -relaxed-filenames -gbk4dos-filenames -gbk4win-filenames |
允许长文件名 扩展的文件名 DOS下支持中文 WIN下支持中文 |
[root@mail home]# ls clamav guan guant iei simscan yu |
[root@mail home]# mkisofs -o test.iso -v /home/guan /home/guant 可以后跟多个目录做source mkisofs 2.0 (i686-pc-linux-gnu) Scanning /home/guan Scanning /home/guan/.kde Scanning /home/guan/.kde/Autostart Scanning /home/guan/sun Scanning /home/guan/t1 Scanning /home/guan/t1/temp Scanning /home/guan/t1/temp/t11 Scanning /home/guant/t2/temp/t11 Scanning /home/guant/t2/temp/t11/t111 Using CLUST000.PDF;1 for /home/guan/newiei/cluster_ibm_totstor_osp.pdf (cluster_hp.pdf) Using CLUST001.PDF;1 for /home/guan/newiei/cluster_hp.pdf (cluster_emc_osp.pdf) Using NTRAC000.DOC;1 for /home/guan/newiei/Ntracker v9 r1.doc (nTracker Deployment Guide (2006-11-22).doc) Using PRESE000.PPT;1 for /home/guan/newiei/Presentation3.ppt (Presentation2.ppt) Using CISCO000.MHT;1 for /home/guan/newiei/Cisco IOS NetFlow Configuration Guide, Release 12_4 - Configuring NetFlow Aggregation Caches - Cisco Systems.mht (Cisco IOS Switching Services Configuration?Guide, Release?12_2 - Configuring Multiprotocol Label Switching? [Cisco IOS Software Releases 12_2 Mainline] - Cisco Systems.mht) Writing: Initial Padbock Start Block 0 Done with: Initial Padbock Block(s) 16 Writing: Primary Volume Descriptor Start Block 16 Done with: Primary Volume Descriptor Block(s) 1 Writing: End Volume Descriptor Start Block 17 Done with: End Volume Descriptor Block(s) 1 Writing: The File(s) Start Block 38 10.49% done, estimate finish Fri Jun 15 14:40:41 2007 20.94% done, estimate finish Fri Jun 15 14:40:22 2007 62.83% done, estimate finish Fri Jun 15 14:40:14 2007 73.31% done, estimate finish Fri Jun 15 14:40:20 2007 83.77% done, estimate finish Fri Jun 15 14:40:19 2007 94.25% done, estimate finish Fri Jun 15 14:40:22 2007 Total translation table size: 0 Total rockridge attributes bytes: 0 Total directory bytes: 28672 Path table size(bytes): 168 Done with: The File(s) Block(s) 47695 Writing: Ending pad block Start Block 47733 Done with: Ending pad block Block(s) 27 Max brk space used 21000 47760 extents written (93 Mb) [root@mail home]# |
[root@mail home]# ls -l test.iso -rw-r--r-- 1 root root 97812480 Jun 15 14:40 test.iso |
[root@mm guan]# ls /mnt/cdrom/ autorun RELEASE-NOTES-bn.html EULA RELEASE-NOTES-de.html GPL RELEASE-NOTES-en images RELEASE-NOTES-en.html isolinux RELEASE-NOTES-es.html README-it.html RELEASE-NOTES-ru.html README-ja.html RELEASE-NOTES-ta.html README-ko.html RELEASE-NOTES-U1-bn.html README-pa.html RELEASE-NOTES-U1-de.html RPM-GPG-KEY README-pt_BR.html RELEASE-NOTES-U1-en SRPMS README-ru.html RELEASE-NOTES-U1-en.html TRANS.TBL README-ta.html RELEASE-NOTES-U1-es.html README-zh_CN.html RELEASE-NOTES-U1-fr.html README-zh_TW.html RELEASE-NOTES-U1-gu.html RedHat RELEASE-NOTES-U1-hi.html |
[root@mm guan]# mkiso -o linux-dev-redhat-as4r4.iso -v -r /mnt/cdrom |
[root@mail home]# mount /home/test.iso /mnt/disk1 mount: /home/test.iso is not a block device (maybe try `-o loop'?) |
[root@mail home]# mount -o loop /home/test.iso /mnt/disk1 |
[root@mail home]# ls /mnt/disk1 4_root_l _bash_lo _bashrc fggggggg.txt huawei.txt _kde network.txt _bash_hi _bash_pr del.txt _gtkrc ifcfg_et linux_2_.bz2 newiei sdfsdf.txt [root@mail home]# |
mkisofs -r -J -T -V "Custom RHEL4 Build" -o /home/guan/custom-RHEL4-dvd.iso \ -b isolinux/isolinux.bin -c isolinux/boot.cat \ -no-emul-boot -boot-load-size 4 -boot-info-table . |
-r -J: -rational-rock -joliet -b:启动image -c:cat文件 -no-emul-boot -boot-load-size 4: Set numbers of load sectors -boot-info-table:Patch boot image with info table |