isolinux.cfg文件
default vesamenu.c32
timeout 600display boot.msg# Clear the screen when exiting the menu, instead of leaving the menu displayed.
# For vesamenu, this means the graphical background is still displayed without
# the menu itself for as long as the screen remains in graphics mode.
menu clear
menu background splash.png
menu title CentOS 7
menu vshift 8
menu rows 18
menu margin 8
#menu hidden
menu helpmsgrow 15
menu tabmsgrow 13# Border Area
menu color border * #00000000 #00000000 none# Selected item
menu color sel 0 #ffffffff #00000000 none# Title bar
menu color title 0 #ff7ba3d0 #00000000 none# Press [Tab] message
menu color tabmsg 0 #ff3a6496 #00000000 none# Unselected menu item
menu color unsel 0 #84b8ffff #00000000 none# Selected hotkey
menu color hotsel 0 #84b8ffff #00000000 none# Unselected hotkey
menu color hotkey 0 #ffffffff #00000000 none# Help text
menu color help 0 #ffffffff #00000000 none# A scrollbar of some type? Not sure.
menu color scrollbar 0 #ffffffff #ff355594 none# Timeout msg
menu color timeout 0 #ffffffff #00000000 none
menu color timeout_msg 0 #ffffffff #00000000 none# Command prompt text
menu color cmdmark 0 #84b8ffff #00000000 none
menu color cmdline 0 #ffffffff #00000000 none# Do not display the actual menu unless the user presses a key. All that is displayed is a timeout message.menu tabmsg Press Tab for full configuration options on menu items.menu separator # insert an empty line
menu separator # insert an empty linelabel linuxmenu label ^Install AISAmenu defaultkernel vmlinuzappend vga=normal initrd=initrd.img inst.ks=hd:LABEL=AISA:/isolinux/ks.cfg inst.stage2=hd:LABEL=AISA ramdisk_size=65536 net.ifnames=0 biosdevname=0 ipv6.disable=1 rdloaddriver=igb nomodeset xdriver=vesa brokenmoudles=ast quietmenu end
下半部分是需要修改的,此外还删除了一些多余的选项,这些选项将会指引到安装何种系统上;
照着这个改吧,反正要注意这个AISA也要改对了
label linuxmenu label ^Install AISAmenu defaultkernel vmlinuzappend vga=normal initrd=initrd.img inst.ks=hd:LABEL=AISA:/isolinux/ks.cfg inst.stage2=hd:LABEL=AISA ramdisk_size=65536 net.ifnames=0 biosdevname=0 ipv6.disable=1 rdloaddriver=igb nomodeset xdriver=vesa brokenmoudles=ast quietmenu end
其中指向了了另一个引导文件是ks.cfg
ks.cfg文件,有删改避免泄漏
# File Managed by Puppetinstall # ==系统安装阶段==
lang en_US.UTF-8 # 设置系统语言
keyboard us # 设置键盘
skipx #
text
reboot
rootpw --iscrypted $1$xxxxxx$eeee # 设置密码
authconfig --enableshadow --enablemd5
selinux --disabled
timezone Asia/Shanghai # 设置时区%packages # ==需要的安装包==
@core
@base
@mail-server
-dovecot
-system-config-httpd
-system-config-printer-gui
-system-config-nfs
-system-config-samba
-ivtv-firmware
@Development tools
ncurses-devel
ntp
%end # ==所需的安装包范围结束==%post --nochroot --log=/mnt/sysimage/root/ks-post.log # ==拷贝文件必须在这个阶段==
#!/bin/sh
server_file=/mnt/install/repo/software/server.zip # U盘目录一定是这/mnt/install/repo/
if [ -e ${server_file} ]; thencp -f ${server_file} /mnt/sysimage/root/
elseecho "server.zip not exist!"
fimgr_file=/mnt/install/repo/software/mgr.zip
if [ -e ${mgr_file} ]; thencp -f ${mgr_file} /mnt/sysimage/root/
elseecho "mgr.zip not exist!"
fi%end # ==拷贝文件阶段结束==%post # 安装阶段,在这里写安装的那些命令
#!/bin/shsed -i 's/net.ifnames=0/net.ifnames=0 rdloaddriver=igb/g' /etc/default/grub
sed -i 's/crashkernel=auto/crashkernel=128M/g' /etc/default/grub
grub2-mkconfig -o /boot/grub2/grub.cfgsystemctl disable systemd-networkd-wait-online.service
systemctl disable multipathd.serviceif [ -e /root/server.zip ]; thenunzip -d /root/install -PrdN06360Ndr /root/server.ziprm -f /root/server.zip
elseecho "/root/server.zip not exist!"
fiif [ -e /root/mgr.zip ]; thenunzip -d /root/install -PrdN06360Ndr /root/mgr.zip rm -f /root/mgr.zip
fiset -x -v -e
exec < /dev/tty3 > /dev/tty3
chvt 3
(echoexport PATH=/usr/local/bin:$PATHif [ -d /root/install/ ]; thenchmod 777 /root/install/kylin_install.shecho "* * * * * root source ~/.bashrc && nohup /root/install/kylin_install.sh >> /root/install_detail 2>&1 &" > /etc/crontabelseecho "/root/install/ not exist"fi) 2>&1 | tee /root/post-kickstart.log%end