kickstart+ftp+tftp+dhcp+PXE

##########yum

less install.log  #看安装log

yum install system-config-kickstart* -y

yum install tftp* -y  #TFTP

yum install dhcp* -y  #DHCP

yum install vsftp* -y  #ftp

yum install lftp* -y  #lftp

##########network

/etc/sysconfig/network-script/ifcfg-eth0

IPADDR=192.168.1.251

GATEWAY=192.168.1.250

DNS1=180.76.76.76

service network restart

##########DHCP

vim /etc/dhcp/dhcpd.conf

1  :r /usr/share/doc/dhcp*/dhcp.conf.sample 

2  subnet; range; option route;

3  next-server  192.168.0.251  filename  "pxelinux.0"

service dhcpd restart

###########KICKSTART  

1  system-config-kickstart

2  vim %pre  %post

3  save to /var/ftp/pub/

###########FTP

1  cd /var/ftp/pub

2  mount /dev/sdb4 /media

3  ln -s /media /var/ftp/pub/

###########TFTP

1  cp /usr/share/syslinux/pxeconfig.0 /var/lib/tftpboot/

1.1 cd /var/lib/tftpboot/

1.2 mkdir pxelinux.cfg

1.3 cp isolinux.cfg pxelinux.cfg/default

1.4 vim pxelinux.cfg/default

1.5 append xxxxxx  ks=ftp://192.168.1.251/ks.cfg

2  cd /media/isolinux/

2.1 cp -rf * /var/lib/tftpboot/

############OTHER

1  iptables -F     #firewall off

2  setenforce 0 #selinux warn

3  service vsftpd restart

4  service dhcpd restart

5  chkconfig xinetd on

5.1 chkconfig tftp on

5.2 service xinetd restart

上一篇:PXE+Kickstart+DHCP+TFTP实现无人值守安装操作系统


下一篇:dhcp、tftp及pxe简介