Automatic installation of PXE in Linux

Source: Internet
Author: User
Anyone who has installed linux knows that it is easy to install linux on only one machine. we only need to put the optical drive in, and install it step by step! But when we install multiple machines in one data center at the same time, it is impossible to do so. Is there a simple way? With the development of the current technology, basically all NICs support pxe. now we can use remote network installation. here we use ftp installation technical materials: start the PXE protocol of the RedHatLinux installer from the network on the PC. anyone who needs to install linux knows that it is easy to install linux on only one machine, we only need to put the optical drive in, step by step installation is OK! But when we install multiple machines in one data center at the same time, it is impossible to do so. Is there a simple way? With the development of the current technology, basically all NICs support pxe. now we can use remote network installation. here we use ftp installation technical materials:

Start the PXE protocol of the Red Hat Linux installer from the network on the PC, and the tftp service is required.
PXE (Pre-boot Execution Environment) is a protocol designed by Intel that enables computers to start over the network. The protocol is divided into two ends: client and server. The PXE client is in the ROM of the NIC. when the computer boots, the BIOS transfers the PXE client to the memory for execution and displays the command menu. after the user selects the client, the PXE client downloads the operating system on the remote end to the local computer for running.


To successfully run the PXE protocol, you must solve the following two problems:

Since it is transmitted over the network, who will configure the IP address of the computer when it is started, and what protocol will be used to download the Linux kernel and the root file system?

The first problem can be solved through the DHCP Server. the DHCP server assigns an IP address to the PXE client. the DHCP Server is a protocol used to dynamically allocate IP addresses to the DHCP Client, however, because the IP address is assigned to the PXE Client, you need to add a specific PXE configuration when configuring the DHCP Server.


As for the second problem, TFTP client already exists in the ROM where the PXE Client is located. PXE Client uses the TFTP Client to download the required files to the TFTP Server through the TFTP protocol.


The linux kernel startup file bootstrap is available in the TFTP root directory, so that the system can be started.

The network installation function provided by Red Hat Linux installer (that is, the network access to the installation media) requires the nfs service.
The ks. cfg file specifies the location of the installation media. If this file is not available, you must manually specify it.


Unattended installation provided by Red Hat Linux installer
/Tftpboot/pxelinux. ks is defined in the cfg/default file. position of the cfg file, and ks. cfg specifies the configuration selection information during the installation process. The best way to learn ks is to find the installed


1. mount the optical drive and install dhcp and vsftp services.


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.