http://www.smorgasbork.com/2012/01/04/building-a-custom-centos-6-kickstart-disc-part-1/

Create a directory to mount your source.
# mkdir /tmp/bootiso Loop mount the source ISO you are modifying. (Download from Red Hat / CentOS.)
# mount -o loop /path/to/some.iso /tmp/bootiso Create a working directory for your customized media.
# mkdir /tmp/bootisoks Copy the source media to the working directory.
# cp -r /tmp/bootiso/* /tmp/bootisoks/ Unmount the source ISO and remove the directory.
# umount /tmp/bootiso && rmdir /tmp/bootiso. Change permissions on the working directory.
# chmod -R u+w /tmp/bootisoks Copy your Kickstart script which has been modified for the packages and %post to the working directory.
# cp /path/to/someks.cfg /tmp/bootisoks/isolinux/ks.cfg Copy any additional RPMs to the directory structure and update the metadata.
# cp /path/to/*.rpm /tmp/bootisoks/Packages/.
# cd /tmp/bootisoks/Packages && createrepo -dpo .. . Add kickstart to boot options.
# sed -i 's/append\ initrd\=initrd.img$/append initrd=initrd.img\ ks\=cdrom:\/ks.cfg/' /tmp/bootisoks/isolinux/isolinux.cfg Create the new ISO file.
# cd /tmp/bootisoks && mkisofs -o /tmp/boot.iso -b isolinux.bin -c boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -R -J -v -T isolinux/. .

http://unix.stackexchange.com/questions/233379/centos-custom-iso-installation-dev-root-does-not-exist

mkfsiso

A mkisofs run needs one or more input directories or files and a name for the emerging filesystem image file. There are options for standards compliance, for filesystem attributes, and -most important here- for setting up boot entry points.

-o DISKPATH sets the result file name. E.g. "bootable.iso".

-R enables normal Unix filenames and attributes by Rock Ridge extension. -r does the same but also changes access permissions to make all files readable by everybody.

-J enables MS-Windows UCS-2 names via Joliet extension.

-iso-level NUMBER sets the ISO 9660 Level of Interchange. Level 1 allows only 8.3 filenames. Level 2 allows up to 30 characters in filenames. Level 3 allows data files larger than 4 GiB - 1.

-U violates ISO 9660 specs by allowing long case-sensitive filenames outside of said extensions. If you know that the reader can stand it, then this is a cheap way to get decent file names. But expect standard readers to become confused.

-V TEXT sets the ISO 9660 Volume ID. It can be up to 32 characters long and is often used by automounters as name of the mount directory for the filesystem.

-hide ISOPATH and -hide-joliet ISOPATH may be used to exclude a data file from the directory trees while still having its content in data blocks of the filesystem.

-c ISOPATH sets the filename for the El Torito Boot Catalog. The file is created automatically if boot images are announced. If option -c is missing, then the file will not show up in the directory trees of the ISO filesystem.

-b ISOPATH announces a data file as El Torito boot image for PC-BIOS.

-e ISOPATH announces a data file as El Torito boot image for EFI. This is not an option of original mkisofs, but is understood by some variants of genisoimage and by xorriso -as mkisofs.

-no-emul-boot and -hard-disk-boot choose emulation modes other than the default of floppy emulation. Especially -no-emul-boot is needed for boot images of ISOLINUX and GRUB2.

-boot-load-size NUMBER sets how many blocks of the boot image are to be loaded by the BIOS. A usual number with -no-emul-boot is 4.

-boot-info-table causes a Boot Info Table to be written into the boot image. Needed for boot images of ISOLINUX and GRUB2.

-eltorito-alt-boot ends the range of -b or -e. All further El Torito boot options will apply to the next boot image given by -b or -e.

-G DISKPATH copies the content of a data file into the System Area of the ISO filesystem. This is used to bring MBR or other boot blocks into the filesystem to enable booting from hard-disk-like devices or booting on exotic hardware.

-isohybrid-mbr DISKPATH copies a SYSLINUX/ISOLINUX MBR template into the System Area and makes it execute the El Torito boot image for BIOS. This is a speciality of xorriso -as mkisofs.

-isohybrid-gpt-basdat announces the boot image as GPT partition for booting via EFI and as MBR partition. This is a speciality of xorriso -as mkisofs.

-graft-points enables the interpretation of pathspecs which give a target path in the ISO filesystem together with the path of an input directory or file.

A program argument, which is not recognized as option (e.g. because it does not begin by a dash "-") and is not parameter of an option, is taken as path to an input directory or file. If it is a directory, then its content gets merged with the content of the root directory of the emerging ISO filesystem. If it is a file of other type, then it gets copied into the root directory.
If enabled, then pathspecs get recognized by an equal sign which separates target path from source path. E.g.

centos custom iso的更多相关文章

  1. CentOS 本地ISO 挂载并配置本地软件源

    CentOS 挂载ISO镜像文件为本地源 操作系统:CentOS5.5 ISO文件:CentOS5.5的ISO镜像一个 操作步骤: 一.挂载iso文件到挂载点 [root@server ~ ]# mo ...

  2. Ubuntun CentOS的ISO官方MD5在哪里查看(安装虚拟电脑时出现严重错误的解决方法)

    近日在VirtualBox虚拟机上安装Linux,然后果断的选择了Ubuntu.当我新建虚拟机,一切配置完成之后,启动虚拟机,还没开始安装就提示虚拟电脑出现严重错误,需要关闭.起初以为是配置错了,上网 ...

  3. 定制centos安装iso

    参考 https://gist.github.com/pauljeff/4b9ad551cb6c35870d7c https://www.redhat.com/archives/kickstart-l ...

  4. CentOS 挂载iso文件配置yum源

    1.挂载iso 准备好centos的光盘镜像 挂载前的准备; mkdir -p /dev/centos mkdir -p  /mnt/local_yum 挂载 mount -o loop /opt/s ...

  5. RedHat/CentOS利用iso镜像做本地yum源

    在这里用iso或者光盘做本地yum源的方法是差不多的,只是用光盘的话Linux系统会自动挂载,用iso镜像的或需要手动挂载,这里就说挂载iso的方法吧. (1) 创建iso存放目录和挂载目录 mkdi ...

  6. Centos光盘ISO安装过程再理解

    ISO启动时的基本流程 vmlinuz  -> 加载initrd.img -> 加载内核基本驱动 -> 挂载光盘至/run/install/repo -> 启动anaconda ...

  7. 虚拟机+centOS挂载ISO步骤

    https://blog.csdn.net/u010612373/article/details/52240447

  8. CentOS配置本地yum源(使用镜像iso文件)

    本人在使用yum安装软件的时候,感觉最不爽的是网络不佳时,安装的速度特别慢.所以,个人就上网search了一下如何使用Linux的安装文件作为其yum源.经过几次尝试,已经可以成功的配置了.下面是详细 ...

  9. CentOS 6.4一键自动化安装ISO镜像光盘

    下载CentOS-6.4-x86_64-minimal.iso 1 http://mirrors.163.com/centos/6.4/isos/x86_64/CentOS-6.4-x86_64-mi ...

随机推荐

  1. PLSQL_性能优化系列01_Oracle Index索引

    2014-06-01 Created By BaoXinjian

  2. PLSQL_性能优化效能跟踪工具SQL Trace分析(案例)

    2014-06-25 Created By BaoXinjian

  3. HDU 1532 (Dinic算法)

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1532 题目大意: 就是由于下大雨的时候约翰的农场就会被雨水给淹没,无奈下约翰不得不修建水沟,而且是网络 ...

  4. HDU 1272 小希的迷宫(并查集)

    题解: 首先,init,find,union操作都是模版,多敲几遍,在记记,就没问题了. 然后,本题就是多了一个flag数组,记录数据是否出现过,最后记录最小,和最大,遍历一般他们的父亲,只有一个就是 ...

  5. linux命令(8)kill命令

    kill命令: Linux中的kill命令用来终止指定的进程(terminate a process)的运行,是Linux下进程管理的常用命令.通常,终止一个前台进程可以使用Ctrl+C键,但是,对于 ...

  6. HTML5列表、块、布局

    一.列表 <ol>  无序列表  (每项前有.) <ul>  有序列表   (每项前有编号1,,2,3) <li>   列表项 <ul type=" ...

  7. GDI+ 中发生一般性错误。

    GDI+ 中发生一般性错误. “/wechat”应用程序中的服务器错误. GDI+ 中发生一般性错误. 说明: 执行当前 Web 请求期间,出现未经处理的异常.请检查堆栈跟踪信息,以了解有关该错误以及 ...

  8. 关于微信网页调用js-sdk相关接口注意事项目(一级域名与二级域名互相干扰!!!)

    不知道有没有网友遇到过同一个web应用用不同的域名(一级或二级域名)在两个公众号中调用JSSDK相关接口实现功能, 这种做法本来没有问题,问题在于用二级域名(同属一级域名下的二级域名)绑定另一个web ...

  9. Python标准库08 多线程与同步 (threading包)

    Python主要通过标准库中的threading包来实现多线程.在当今网络时代,每个服务器都会接收到大量的请求.服务器可以利用多线程的方式来处理这些请求,以提高对网络端口的读写效率.Python是一种 ...

  10. Hibernate的dialect大全

    RDBMS 方言 DB2 org.hibernate.dialect.DB2Dialect DB2 AS/400 org.hibernate.dialect.DB2400Dialect DB2 OS3 ...