PXELINUX的执行过程之1

通过PXE方式引导的服务器从网卡引导的第一步是获取一个ip地址,并获得nextserver 和pxelinux.0这个引导程序,pxelinux.0会以下列的方式寻找他的配置文件

PXELINUX operates in many ways like SYSLINUX. If you are not familiar with SYSLINUX, read the SYSLINUX FAQ first, since this documentation only explains the differences.

On the TFTP server, create the directory "/tftpboot", and copy pxelinux.0 (from the SYSLINUX distribution) and any kernel or initrd images that you want to boot.

Finally, create the directory "/tftpboot/pxelinux.cfg". The configuration file (equivalent of syslinux.cfg -- see the SYSLINUX FAQ for the options here) will live in this directory. Because more than one system may be booted from the same server, the configuration file name depends on the IP address of the booting machine. PXELINUX will search for its config file on the boot server in the following way:

  • First, it will search for the config file using the hardware type (using its ARP type code) and address, all in lower case hexadecimal with dash separators; for example, for an Ethernet (ARP type 1) with address 88:99:AA:BB:CC:DD it would search for the filename 01-88-99-aa-bb-cc-dd.
  • Next, it will search for the config file using its own IP address in upper case hexadecimal, e.g. 192.0.2.91 -> C000025B (you can use the included progam gethostip to compute the hexadecimal IP address for any host). If that file is not found, it will remove one hex digit and try again. Ultimately, it will try looking for a file named default (in lower case). As an example, if the boot file name is /mybootdir/pxelinux.0, the Ethernet MAC address is `88:99:AA:BB:CC:DD` and the IP address 192.0.2.91, it will try following files (in that order):

    /mybootdir/pxelinux.cfg/01-88-99-aa-bb-cc-dd
    /mybootdir/pxelinux.cfg/C000025B
    /mybootdir/pxelinux.cfg/C000025
    /mybootdir/pxelinux.cfg/C00002
    /mybootdir/pxelinux.cfg/C0000
    /mybootdir/pxelinux.cfg/C000
    /mybootdir/pxelinux.cfg/C00
    /mybootdir/pxelinux.cfg/C0
    /mybootdir/pxelinux.cfg/C
    /mybootdir/pxelinux.cfg/default

Note that all filename references are relative to the directory pxelinux.0 lives in. PXELINUX generally requires that filenames (including any relative path) are 127 characters or shorter in length.

PXELINUX does not support MTFTP, and I have no immediate plans of doing so. It is of course possible to use MTFTP for the initial boot, if you have such a setup. MTFTP server setup is beyond the scope of this document.

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
PXE(Preboot Execution Environment)是一种网络引导技术,可以通过网络从服务器上安装操作系统。PXE安装Windows操作系统的过程如下: 1. 配置PXE服务器:首先需要搭建一个PXE服务器,可以使用软件如TFTP、DHCP等来实现。在服务器上准备好Windows操作系统的安装文件。 2. 配置DHCP服务器:在DHCP服务器上配置PXE服务器的IP地址和启动文件名。当客户端启动时,会通过DHCP获取到PXE服务器的IP地址和启动文件名。 3. 准备引导文件:在PXE服务器上准备好引导文件,通常是通过网络引导文件(如pxelinux.0)来启动客户端。 4. 配置引导文件:在引导文件中配置好要安装的Windows操作系统的镜像文件路径和参数。 5. 客户端启动:将需要安装Windows操作系统的客户端设置为通过网络引导,并启动客户端。 6. 客户端连接PXE服务器:客户端启动后会通过DHCP获取到PXE服务器的IP地址和启动文件名,并连接到PXE服务器。 7. 下载引导文件:客户端会下载引导文件(如pxelinux.0)并执行,根据配置的参数找到要安装的Windows操作系统的镜像文件。 8. 下载镜像文件:客户端会下载Windows操作系统的镜像文件,并进行安装过程。 9. 安装操作系统:根据镜像文件进行Windows操作系统的安装过程,包括选择安装位置、设置用户信息等。 10. 完成安装:安装完成后,客户端会重启并进入已安装的Windows操作系统。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值