加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > Linux > 正文

mkisofs命令

发布时间:2020-12-14 00:18:30 所属栏目:Linux 来源:网络整理
导读:目录 mkisofs命令 参考 mkisofs命令 自定义系统镜像 mkisofs命令 ?? Written by Zak Zhu 参考 鸟哥私房菜(http://cn.linux.vbird.org/linux_basic/0240tarcompress_5.php) loveaborn/用mkisofs命令制作redhat enterprise linux (RHEL6.4) ISO启动镜像(https:

目录

  • mkisofs命令
    • 参考
    • mkisofs命令
    • 自定义系统镜像

mkisofs命令

?? Written by Zak Zhu

参考

  • 鸟哥私房菜(http://cn.linux.vbird.org/linux_basic/0240tarcompress_5.php)
  • loveaborn/用mkisofs命令制作redhat enterprise linux (RHEL6.4) ISO启动镜像(https://www.linuxidc.com/Linux/2013-08/88967.htm)
  • macg/mkisofs------制作iso文件(http://blog.sina.com.cn/s/blog_6151984a0100fqmy.html)
  • Red Hat Installation Guide--2.4.2(https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/5/html-single/installation_guide/index)

mkisofs命令

mkisofs - create ISO9660/Joliet/HFS filesystem with optional Rock Ridge attributes

命令格式

mkisofs [options] <-o cd.iso> pathspec ...

参数注释

参数 注释
-R Generate SUSP and RR records using the Rock Ridge protocol to further describe the fileson the ISO9660 filesystem.
-r This is like the -R option,but file ownership and modes are set to more useful values. The uid and gid are set to zero,because they are usually only useful on the author‘s system,and not useful to the client. All the file read bits are set true,so that files and directories are globally readable on the client. If any execute bit is set for a file,set all of the execute bits,so that executables are globally executable on the client. If any search bit is set for a directory,set all of the search bits,so that directories are globally searchable on the client. All write bits are cleared,because the filesystem will be mounted read-only in any case. If any of the special mode bits are set,clear them,because file locks are not useful on a read-only filesystem,and set-id bits are not desirable for uid 0 or gid 0.

其他参数,详见下面<自定义系统镜像>中的组合使用

自定义系统镜像

  1. 在vmware-workstation的虚拟机里,挂载光盘

    mount /dev/sr0 /mnt/cdrom

  2. 复制/mnt/cdrom里的文件到/tmp/custom/下

    cp -r /mnt/cdrom/* /tmp/custom/

  3. 根据需求编写ks.cfg

    vim /tmp/custom/isolinux/ks.cfg

  4. 赋予isolinux.bin执行和写权限

    chmod u+wx /tmp/custom/isolinux/isolinux.bin

  5. 用mkisofs制作ISO文件

    # Step 1
    cd /tmp/custom/
    
    # Step 2
    mkisofs -R -J -T -v  -b isolinux/isolinux.bin  -c isolinux/boot.cat  -no-emul-boot  -boot-load-size 4  -boot-info-table  -o /tmp/custom.iso  /tmp/custom

上述步骤是根据参考内容总结出来的,我没有做验证. 我等以后有需求再做验证,如果有道友根据我写的步骤实现了需求,请留言告知,万分谢谢 !!

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读