挂载
cdrom方式挂载:mount /dev/cdrom /mnt iso镜像拷贝到系统本地:mount CentOS-6.5-x86_64-bin-DVD1.iso -o loop /mnt
导入镜像到cobbler
cobbler import --path=/mnt/ --name=CentOS-7-x86_64 --arch=x86_64
说明:cobber把镜像导入到该目录下:/var/www/cobbler/ks_mirror/
添加ks文件
cd /var/lib/cobbler/kickstarts cp sample.ks centos7.ks
# This kickstart file should only be used with RHEL 4, 5 and Fedora < 8. # For newer distributions please use the sample_end.ks #platform=x86, AMD64, or Intel EM64T # System authorization information auth --useshadow --enablemd5 # System bootloader configuration bootloader --location=mbr # Partition clearing information clearpart --all --initlabel # 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') # 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 # Allow anaconda to partition the system as needed #autopart part /boot --fstype=ext4 --size=200 --ondisk=sda --asprimary part swap --size 1024 part / --fstype ext4 --size=1 --grow --ondisk sda --asprimary %packages $SNIPPET('func_install_if_enabled') $SNIPPET('puppet_install_if_enabled') @base @core @debugging @development %end
把镜像和对应的kickstart文件关联在一起
cobbler profile list cobbler profile edit --name=CentOS-7-x86_64 --kickstart=/var/lib/cobbler/kickstarts/centos7.ks cobbler sync cobbler profile report
检测kickstart配置文件是否有错误
cobbler validateks
(二)cobbler添加centos7
猜你喜欢
转载自www.cnblogs.com/lovelinux199075/p/8876772.html
今日推荐
周排行