Automatic PXE Installation

Source: Internet
Author: User

First, we need to use the Linux desktop mode. If there is no desktop mode, please install it consciously.

Required support environment, DHCP, TFTP, and vsftp.

1. Create an FTP shared CD directory first

mkdir -p /var/ftp/centos6

2. Copy the CD to the directory.

cp -rp /media/cdrom/* /var/ftp/centos6

3. Install TFTP-Server

yum -y install tftp-server

4. Modify the TFTP configuration file.

vim /etc/xinetd.d/tftp

Others remain unchanged

Open the xinetd service

 /etc/init.d/xinetd start

Change it to start

chkconfig tftp on

5. Prepare the kernel distribution file.

cp /var/ftp/centos6/isolinux/vmlinuz initrd.img /var/lib/tftpboot/

We also need to install syslinux

yum -y install syslinux

Copy another kernel file after installation.

cp /usr/share/syslinux/pxelinux.0 /var/lib/tftpboot/

Another one should be admitted to the CD source.

 cp /var/ftp/centos6/isolinux/isolinux.cfg /var/lib/tftpboot/

In this way, the kernel is ready to distribute files, a total of four

Then we need to downgrade and modify something.

chmod 644 /var/lib/tftpboot/isolinux.cfg
vim /var/lib/tftpboot/isolinux.cfg

Change the file to the image.

Comment out all menu headers.

Let me throw this file to the/var/lib/tftpboot/pxelinux. cfg directory and rename it default.

cd /var/lib/tftpboot/mkdir pxelinux.cfgmv isolinux.cfg pxelinux.cfg/defaul

Then we install DHCP and modify the configuration file.

Yum-y install dhcpvim/etc/DHCP/DHCPD. conf
Copy the Template
CP/usr/share/doc/DHCP */DHCPD. conf. Sample/etc/DHCP
Import
CAT/etc/DHCP/DHCPD. conf. Sample>/etc/DHCP/DHCPD. conf

Change to the following

 

Note that all the changes end with a block number. If there is no block number, it is wrong.

Start the service,

Download vsftpd and start it.

yun -y install vsftpd/etc/init.d/vsftpd start

Install system-config-kickstart

yum -y install system-config-kickstart

On the desktop.

 

 

Restart the three services.

Copy the KS configuration script to FTP.

[[email protected] ~]# cp ks.cfg /var/ftp/[[email protected] ~]# chmod 777 /var/ftp/ks.cfg 

Modify boot file

 vim /var/lib/tftpboot/pxelinux.cfg/default

Add a sentence inside

In the self-installed configuration script, modify it to all automatically installed

 

 

 

 

Automatic PXE Installation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.