您的位置:首页 > 理论基础 > 计算机网络

centos6.3配置 kickstart   无人值守安装centos6.3系统 httpd方式

2014-07-26 21:34 459 查看
centos6.3+tftp+dhcp+httpd系统环境:centos6.3*64setenforce 0 关闭 selinuxservice iptables stop 关闭iptables1 挂载镜像mount /dev/cdrom /mntcp -rf /mnt/* /var/www/html/yum install -y httpd* tftp-server-* xinetd-* system-config-kickstart-* syslinux dhcp* 安装必备软件配置tftp加载文件vim /etc/xinetd.d/tftp
service tftp{socket_type            = dgramprotocol                = udpwait                    = yesuser                    = rootserver                  = /usr/sbin/in.tftpdserver_args            = -s /tftpboot    #开机必需的程序路径(根据的tftpboot路径更改)disable                = yes      #把这边的yes改为noper_source              = 11cps                    = 100 2flags                  = IPv4}mkdir /tftpboot2  创建tftp目录cp /usr/share/syslinux/pxelinux.0 /tftpboot/cp /mnt/images/pxeboot/initrd.img /tftpboot/cp /mnt/images/pxeboot/initrd.img /tftpboot/cp /mnt/isolinux/*.msg /tftpboot/      #开机引导文件mkdir /tftpboot/pexlinux.cfgcp /mnt/isolinux/isolinux.cfg /tftpboot/pxelinux.cfg/default拷贝相关文件3  配置 DHCP servervim /etc/dhcp/dhcpd.conf
ddns-update-style interim;ignore client-updates;next-server 192.168.1.4;  #tftp server 的ip地址filename "/pxelinux.0";subnet 192.168.1.0 netmask 255.255.255.0 {option routers          192.168.1.1;#路由地址option subnet-mask      255.255.255.0;range dynamic-bootp 192.168.1.50 192.168.1.100;default-lease-time 21600;max-lease-time 43200;}
vim /etc/httpd/conf/httpd.conf找到 #ServerName www.example.com:80 这一行 ,把注释去掉4 配置ks.cfg桌面环境 运行命令 system-config-kickstart 配置ks.cfg 并拷贝到 /var/www/html 下修改 ks.cfg例子如下
#platform=x86, AMD64, 或 Intel EM64T#version=DEVEL# Firewall configurationfirewall --disabled# Install OS instead of upgradeinstall# Use network installationurl --url="http://192.168.1.4/"# Root passwordrootpw --iscrypted $1$e8wRnTe1$eaeL5kK6Zi8MllGrUtCNk.# System authorization informationauth  --useshadow  --passalgo=sha512# Use graphical installgraphicalfirstboot --disable# System keyboardkeyboard us# System languagelang zh_CN# SELinux configurationselinux --disabled# Installation logging levellogging --level=inforeboot# System timezonetimezone  Asia/Shanghai# Network informationnetwork  --bootproto=dhcp --device=eth0 --onboot=on# System bootloader configurationbootloader --location=mbr# Clear the Master Boot Recordzerombr# Partition clearing informationclearpart --all# Disk partitioning informationpart /boot --fstype="ext4" --size=200part swap --fstype="swap" --size=256part / --fstype="ext4" --size=10000part /usr/local --fstype="ext4" --size=10000%packages
chmod -R 777 /tftpboot/5vim /tftpboot/pxelinux.cfg/default
default linuxprompt 0timeout 10display boot.msgF1 boot.msgF2 options.msgF3 general.msgF4 param.msgF5 rescue.msglabel linuxkernel vmlinuzappend initrd=initrd.img ks=http://192.168.1.4/ks.cfg   #http地址,可以通过web访问验证label textkernel vmlinuzappend initrd=initrd.img textlabel kskernel vmlinuzappend ks initrd=initrd.imglabel locallocalboot 1label memtest86kernel memtestappend -
启动服务service httpd restartservice xinetd restartservice dhcpd restartchkconfig httpd onchkconfig xinetd onchkconfig dhcpd on
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  centos6.3 kickstart