码迷,mamicode.com
首页 > 其他好文 > 详细

centos6.6-6.8的cobbler的kickstarts文件

时间:2018-07-10 21:39:25      阅读:177      评论:0      收藏:0      [点我收藏+]

标签:com   --   ima   arp   ati   gen   efault   swa   run   

author:headsen chen
date: 2018-07-10 19:14:39

1,普通的mbr版的kickstarts的配置文件:
[root@cobbler-server ~]# cat /var/lib/cobbler/kickstarts/CentOS-6.8-x86_64.cfg 
技术分享图片
#platform=x86, AMD64, or Intel EM64T
# System authorization information
auth  --useshadow  --enablemd5
# System bootloader configuration
bootloader --location=mbr
# Partition clearing information
clearpart --all --initlabel
#Partition information
part /boot --fstype ext4 --size 1024 --ondisk sda
part swap --size=1500
part / --fstype ext4 --size 1 --grow --ondisk sda
  
# Use text mode install
text
# Firewall configuration
firewall --disable
# Run the Setup Agent on first boot
firstboot --disable
# System keyboard
keyboard us
# System language
lang en_US
# Use network installation
url --url=$tree
# If any cobbler repo definitions were referenced in the kickstart profile, include them here.
$yum_repo_stanza
# Network information
$SNIPPET(network_config)
#network --bootproto=dhcp   --device=em1
# Reboot after installation
reboot
 
#Root password
rootpw --iscrypted $default_password_crypted
# SELinux configuration
selinux --disabled
# Do not configure the X Window System
skipx
# System timezone
timezone   Asia/Shanghai
# Install OS instead of upgrade
install
# Clear the Master Boot Record
zerombr
  
%packages
@base
@compat-libraries
@debugging
@development
tree
nmap
sysstat
lrzsz
dos2unix
telnet

%pre
$SNIPPET(log_ks_pre)
$SNIPPET(kickstart_start)
$SNIPPET(pre_install_network_config)
# Enable installation monitoring
$SNIPPET(pre_anamon)
  
%post

%end
View Code

   2,uefi版的kickstarts的配置文件

[root@cobbler-server ~]# cat /var/lib/cobbler/kickstarts/CentOS-6.8-x86_64.cfg 
技术分享图片
#platform=x86, AMD64, or Intel EM64T
# System authorization information
auth  --useshadow  --enablemd5
unsupported_hardware

# System bootloader configuration
bootloader --append "crashkernel=auto" --location mbr 

# Partition clearing information
clearpart --all --initlabel

#Partition information
part /boot/efi --fstype efi --ondisk sda --size 1024 --fsoptions "defaults,uid=0,gid=0,umask=0077,shortname=winnt"
part /app --fstype ext4 --size 20480
part swap --fstype swap --size 1500
part / --fstype ext4 --size 1 --grow --ondisk sda
part /boot --fstype ext4 --size 1024

unsupported_hardware

# Use text mode install
text
# Firewall configuration
firewall --disable
# Run the Setup Agent on first boot
firstboot --disable
# System keyboard
keyboard us
# System language
lang en_US
# Use network installation
url --url=$tree
# If any cobbler repo definitions were referenced in the kickstart profile, include them here.
$yum_repo_stanza
# Network information
$SNIPPET(network_config)
#network --bootproto=dhcp   --device=em1
# Reboot after installation
reboot
 
#Root password
rootpw --iscrypted $default_password_crypted
# SELinux configuration
selinux --disabled
# Do not configure the X Window System
skipx
# System timezone
timezone   Asia/Shanghai
# Install OS instead of upgrade
install
# Clear the Master Boot Record
zerombr
  
%packages
@base
@compat-libraries
@debugging
@development
tree
nmap
sysstat
lrzsz
dos2unix
telnet

%pre
$SNIPPET(log_ks_pre)
$SNIPPET(kickstart_start)
$SNIPPET(pre_install_network_config)
# Enable installation monitoring
$SNIPPET(pre_anamon)
  
%post

%end
View Code
系统成功后的系统分区如下:
[root@localhost ~]# df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda3        95G  1.5G   89G   2% /       # --------------------------> 自定义的根分区,剩下的空间全分这里 
tmpfs           494M     0  494M   0% /dev/shm  # --------------------------> 物理内存的一般,一种赞存的
/dev/sda4        20G   44M   19G   1% /app   # --------------------------> 定义的app分区大小 20g
/dev/sda2       976M   33M  893M   4% /boot    # ---------------------------> 定义的/boot分区大小 1024
/dev/sda1      1022M  268K 1022M   1% /boot/efi  # ---------------------------》定义的efi分区的大小 1024

 

     以上两种配置文件,在客户端完成按下电源键后,中途不用操作任何命令:实现效果图如下:

技术分享图片


3,centos7的配置文件如下:

centos6.6-6.8的cobbler的kickstarts文件

标签:com   --   ima   arp   ati   gen   efault   swa   run   

原文地址:https://www.cnblogs.com/kaishirenshi/p/9291072.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!