build custom centos7
必读,在以下内容之前。
pre:
0. install log
推荐使用pungi
这哥们写了不少不错的文章。 还有python的设计模式。
pungi --nohash --nosource --nodebugingo -G -C -B -I --name=demo --version=1.0 --destdit=./out -c package.ks
package.ks 是需要安装的包列表。
2. cloud的部署安装
There is a script to create custom iso
3. make the ISO
https://serverfault.com/questions/517908/how-to-create-a-custom-iso-image-in-centos
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
%postto 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 -V "CentOS 7 x86_64" -R -J -v -T isolinux/. .
(Optional) Use
isohybridif you want toddthe ISO file to a bootable USB key.isohybrid /tmp/boot.iso
Add an MD5 checksum (to allow testing of media).
implantisomd5 /tmp/boot.iso- others
4. other introduce.
make-a-custom-centos-7-or-rhel-7-cd-with-kicktart-file
Make a custom CentOS-7 or RHEL-7 CD With kicktart File
红帽(Red Hat)从Enterprise Server 6.2 开始,启动镜像文件initrd.img 开始改用xz 工具进行压缩,这与以往版本是有区别的
To decompress an image, use the xz -d command. For example
How to unpack and repack an initial ramdisk (initrd/initramfs) image?
三、补充tar.lzma
由于LZMA具有优秀的压缩率及占用资源少的特点,越来越多的工具采用lzma进行打包,后缀名为:tar.lzma。
对于Fedora 11 及以后的版本,可以使用下面的命令操作:
压缩
# tar cfv backup.tar.lzma a/dir --lzma
解压:
# tar xfv backup.tar.lzma --lzma
如果是CentOS 5.3 等老版本,需要安装独立的lzma 工具或用xz 进行:
压缩:
# tar cv a/dir | lzma -c -z > backup.tar.lzma
解压(两个方式都可以):
# cat backup.tar.lzma | lzma -d | tar xv
# xz -dc backup.tar.lzma | tar xvf -
ref:
CentOS7定制封装发行版-基于CentOS minimal
cat buildiso.sh
#!/bin/bash
cd repodata
mv *-minimal*-comps.xml comps.xml
ls .|grep -v "comps.xml"|xargs -i rm -f {}
cd ../
createrepo -g repodata/comps.xml ./
declare -x discinfo=`head - .discinfo`
mkisofs -R -J -T -r -l -d -joliet-long -allow-multidot -allow-leading-dots -no-bak -o/tmp/centos7.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size -boot-info-table .
How to create a Fedora install ISO for testing
Cobbler
Cobbler自动化安装配置实践
build custom centos7的更多相关文章
- Writing custom protocol for nanomsg
http://vitiy.info/writing-custom-protocol-for-nanomsg/ nanomsg is next version of ZeroMQ lib, provid ...
- Solr: a custom Search RequestHandler
As you know, I've been playing with Solr lately, trying to see how feasible it would be to customize ...
- Ubuntu18.04安装Docker, centos7安装Docker
Ubuntu18.04安装Docker 第一种方法从Ubuntu的仓库直接下载安装: 安装比较简单,这种安装的Docker不是最新版本,不过对于学习够用了,依次执行下面命令进行安装. $ sudo a ...
- (转) [it-ebooks]电子书列表
[it-ebooks]电子书列表 [2014]: Learning Objective-C by Developing iPhone Games || Leverage Xcode and Obj ...
- .net Framework Class Library(FCL)
from:http://msdn.microsoft.com/en-us/library/ms229335.aspx 我们平时在VS.net里引用的那些类库就是从这里来的 The .NET Frame ...
- Cheatsheet: 2013 06.01 ~ 06.22
.NET Git for Visual Studio and .NET developers How to download multiple files concurrently using Web ...
- VC++编译MPIR 2.7.0
目录 第1章编译 2 1.1 简介 2 1.2 下载 3 1.3 解决方案 4 1.4 创建项目 5 1.5 复制文件树 6 1.6 不使用预编译头文件 8 ...
- Awesome Swift
Awesome Swift https://github.com/matteocrippa/awesome-swift A collaborative list of awesome Swift re ...
- Ye.云狐J2刷机笔记 | 完美切换内部存储卡和SD卡的改法.vold.fstab
================================================================================Ye.完美切换内部存储卡和SD卡成功.v ...
随机推荐
- HTML5表单及其验证
随笔- 15 文章- 1 评论- 115 HTML5表单及其验证 HTML表单一直都是Web的核心技术之一,有了它我们才能在Web上进行各种各样的应用.HTML5 Forms新增了许多新控件及其A ...
- EL的隐含对象(一)【页面上下文对象】
页面上下文对象为pageContext,用于访问JSP内置对象(例如:request.response.out.session.exception.page等)和ServletContext.在获取到 ...
- CentOS双机中Docker下安装Mysql并配置互为主从模式
CentOS双机中Docker下安装Mysql并配置互为主从模式 目录 1.搜索镜像... 1 2.拉取镜像... 1 3.绑定端口: 1 4.配置文件(修改/etc/mysql/my.cnf文件): ...
- linux网卡eth1如何修改为eth0
ifconfig看到的ip不是我想要的ip,而且显示的第一块网卡也是eth1 ,这明显是有问题的, vim /etc/sysconfig/network-script/ifcfg-eth0 看到的ip ...
- Rstudio 01 连接MySQL
> install.packages("RMySQL") also installing the dependency ‘DBI’ trying URL 'https://c ...
- Python全栈-day11-函数3
装饰器 1.开放封闭原则 通常情况下,软件一旦上线就应该遵循开放封闭原则,即对修改封闭.对扩展开放 扩展开放需遵循两个原则: 1)不修改源代码 2)不修改原函数的调用方式 2.装饰器 器指的是工具,装 ...
- 2.sklearn库中的标准数据集与基本功能
sklearn库中的标准数据集与基本功能 下面我们详细介绍几个有代表性的数据集: 当然同学们也可以用sklearn机器学习函数来挖掘这些数据,看看可不可以捕捉到一些有趣的想象或者是发现: 波士顿房价数 ...
- uva 11354 Bond
题意: 邦德在逃命!他在一个有N个城市,由M条边连接的道路网中.一条路的危险度被定义为这条路上危险度最大的边的危险度. 现在给出若干个询问,s,t,问从s到t的最小的危险度是多少. 思路: 首先可以证 ...
- [openjudge-搜索]Lake Counting(翻译及实现)
题目原文 描述 Due to recent rains, water has pooled in various places in Farmer John's field, which is rep ...
- 【Linux学习十】负载均衡带来tomcat的session不一致问题
环境 虚拟机:VMware 10 Linux版本:CentOS-6.5-x86_64 客户端:Xshell4 FTP:Xftp4 tomcat7 jdk7 session不一致是指web服务器(tom ...