pxelinux

Have you ever wished you could get the “Windows Recovery Console” running for that one maintenance procedure or program you want to use, without having to remember where you’ve forgotten the CD? HTG explains how to boot WinPE from PXE.

您是否曾经希望可以为要使用的一个维护过程或程序运行“ Windows恢复控制台”,而不必记住忘记CD的位置? HTG解释了如何从PXE引导WinPE。

Photo Credit: Alfred Hermida via Compfight cc

图片来源: Alfred Hermida通过Compfight cc

Windows Pre-execution environment (WinPE) is the version of windows that most people know as the one that boots off of the install CD. Over the years, entire projects have been created to give one the ability to have a sort of “Windows Live” environment like many Linux distros. In this guide, we will have the windows PE from the install CD boot from PXE just so we can use it to run the Dell BIOS update utility. You are encouraged to continue the exploration of this bottomless pit of geek goodness…

Windows预执行环境(WinPE)是大多数人都知道的Windows版本,它是从安装CD引导的版本。 多年来,已经创建了整个项目,以使人们能够像许多Linux发行版一样拥有一种“ Windows Live ”环境。 在本指南中,我们将从PXE的安装CD引导中获取Windows PE,以便我们可以使用它来运行Dell BIOS更新实用程序。 我们鼓励您继续探索这个极客善良的无底洞。

总览 (Overview)

We’ve shown you what PXE is and how you can easily install a server for it (and much more) with FOG, today we will be adding yet another extension to FOG. Generally today’s procedure will be:

我们已经向您展示了什么是PXE,以及如何使用FOG轻松地为其安装服务器(以及更多) ,今天我们将为FOG添加另一个扩展。 通常,今天的过程将是:

  1. Update PXElinux to v5.01 or higher, if not already installed.

    如果尚未安装,请将PXElinux更新到v5.01或更高版本。

  2. Add the wimboot module.添加wimboot模块。
  3. Copy the WIM image and supporting files from the windows install CD.从Windows安装CD复制WIM映像和支持文件。
  4. Add the menu entry.添加菜单项。
  5. Use the booted WinPE to get a working “Windows recovery console”.使用启动的WinPE获得有效的“ Windows恢复控制台”。

We are going to do the above, because going the “regular” Windows Automated Installation Kit (WAIK) way forces you, at best, to install it on your machine and go through a not so straightforward process to mangle the WIM file and its support files into their WDS/RIS form. While Linux alternatives do exists, like the UDA project’s one (which is the PXE server I used before FOG came along), using this way you simply replace some files on the PXE server once (which you probably would have eventually anyhow) and copy the unaltered WIM file and support files directly from the Windows CD into the PXE server.

我们将执行上述操作,因为采用“常规” Windows自动安装工具包(WAIK)的方式最多只能迫使您将其安装在计算机上,并经过一个不太简单的过程来处理WIM文件及其支持文件放入其WDS / RIS表单中。 尽管确实存在Linux替代方案,例如UDA项目的替代方案(这是我在FOG出现之前使用的PXE服务器),但是使用这种方式,您只需替换一次PXE服务器上的某些文件(您可能最终将无论如何都可以)并复制直接从Windows CD到PXE服务器的WIM文件和支持文件保持不变。

The one thing to note, is that while it will look like you can start the windows install procedure this way, you actually can’t complete it, and making that possible is beyond the scope of this guide.

需要注意的一件事是,虽然看起来您可以通过这种方式启动Windows安装过程,但实际上无法完成该过程,并且使之成为可能超出了本指南的范围。

Lets get cracking :)

让我们开始吧:)

将PXElinux更新到V5.01 (Update PXElinux to V5.01)

As of the time of this writing, the version of Syslinux in the Ubuntu repository is still 4.05. I’m guessing this is because the Syslinux team decided to shake things up with the V5 branch and have changed the way their COM32 modules work (now based on ELF) and changed the “core” to require a library (ldlinux.c32) for anything beyond “pure boot”. This makes it very possible to encounter breakage, for anyone who’s used to the “old way”. Don’t fret,  we will download the required files manually and make it so your FOG installation doesn’t loose a beat.

在撰写本文时,Ubuntu存储库中的Syslinux版本仍为4.05。 我猜这是因为Syslinux团队决定通过V5分支来改变现状,并更改了其COM32模块的工作方式(现在基于ELF),并且更改了“核心”,要求使用一个库(ldlinux.c32) 任何超越“纯粹的引导”。 对于那些习惯了“旧方式”的人来说,这很有可能会遇到破损。 不用担心,我们将手动下载所需的文件并进行安装,以使您的FOG安装不会动摇。

We will be using version 5.01 as it is the latest stable release from the V5 branch at the time of this writing and it is the one on which the Syslinux team worked together with the wimboot team to make this specific procedure work.

我们将使用版本5.01,因为它是撰写本文时来自V5分支的最新稳定版本,并且它是Syslinux团队与wimboot团队合作使这一特定过程正常工作的版本。

Note: Another reason that the latest version isn’t part of the Ubuntu repository yet (IMHO), is that at least on Citrix-Xen, the HVM guests can’t boot anything beyond the PXE menus. Other hypervisors like VMware, Hyper-V & VirtualBox, as well as physical machines are just fine with the new version.

注意 :最新版本尚未成为Ubuntu存储库(IMHO)的一部分的另一个原因是,至少在Citrix-Xen上,HVM guest虚拟机无法启动PXE菜单之外的任何内容 。 其他版本的虚拟机管理程序(如VMware,Hyper-V和VirtualBox)以及物理机都可以很好地适应新版本。

If the note above doesn’t affect you, proceed.

如果以上说明对您没有影响,请继续。

Obtain  version 5.01 of PXElinux directly from Kernel.org and extract it on the FOG server by:

直接从Kernel.org获得PXElinux 5.01版,并通过以下方式将其解压缩到FOG服务器上:

wget https://www.kernel.org/pub/linux/utils/boot/syslinux/syslinux-5.01.tar.bz2
tar xvhf syslinux-5.01.tar.bz2

wget https://www.kernel.org/pub/linux/utils/boot/syslinux/syslinux-5.01.tar.bz2
tar xvhf syslinux-5.01.tar.bz2

Create the directory that will hold the newly required libraries:

创建将包含新需要的库的目录:

mkdir -p /tftpboot/howtogeek/libs

mkdir -p /tftpboot/howtogeek/libs

Copy the required library files to this directory, so they will be available for the clients at runtime:

将所需的库文件复制到此目录,以便它们在运行时可供客户端使用:

cp -av syslinux-5.01/com32/lib/libcom32.c32 /tftpboot/howtogeek/libs/
cp -av syslinux-5.01/com32/libutil/libutil.c32 /tftpboot/howtogeek/libs/
cp -av syslinux-5.01/com32/modules/linux.c32 /tftpboot/howtogeek/libs/

cp -av syslinux-5.01/com32/lib/libcom32.c32 /tftpboot/howtogeek/libs/
cp -av syslinux-5.01/com32/libutil/libutil.c32 /tftpboot/howtogeek/libs/
cp -av syslinux-5.01/com32/modules/linux.c32 /tftpboot/howtogeek/libs/

Append the “path” to this directory, to the already existing “default” configuration file, by either editing it or issuing the below:

通过编辑或发出以下命令,将该目录的“路径”追加到已存在的“默认”配置文件中:

echo "PATH howtogeek/libs" >> /tftpboot/pxelinux.cfg/default

echo "PATH howtogeek/libs" >> /tftpboot/pxelinux.cfg/default

Copy the newly required ldlinux.c32 to the root of the TFTP server by issuing:

通过发出以下命令,将新需要的ldlinux.c32复制到TFTP服务器的根目录:

cp -av syslinux-5.01/com32/elflink/ldlinux/ldlinux.c32 /tftpboot/

cp -av syslinux-5.01/com32/elflink/ldlinux/ldlinux.c32 /tftpboot/

Update the graphical engine (vesamenu.c32) to correspond to this new version:

更新图形引擎(vesamenu.c32)以与此新版本相对应:

cp -av syslinux-5.01/com32/menu/vesamenu.c32 /tftpboot/

cp -av syslinux-5.01/com32/menu/vesamenu.c32 /tftpboot/

Congratulations, your PXE server is now updated to v5.01 and everything that was already working (unless you are affected by the “note” from the start of this segment) should continue to do so.

恭喜,您的PXE服务器现在已更新至v5.01,并且已经正常运行的所有功能(除非您从本节开始时受到“注释”的影响)应该继续这样做。

WIMboot (WIMboot)

This bootloader is part of the iPXE project and they describe it like so:

该引导程序是iPXE项目的一部分,他们对它的描述如下:

wimboot is a boot loader for Windows Imaging Format (.wim) files. It enables you to boot a Windows PE (WinPE) environment from a RAM disk, without wasting the memory used for the RAM disk image.

wimboot是Windows映像格式( .wim )文件的引导加载程序。 它使您可以从RAM磁盘启动Windows PE(WinPE)环境,而不会浪费用于RAM磁盘映像的内存。

Download the latest version from their site:

从他们的网站下载最新版本:

wget http://git.ipxe.org/releases/wimboot/wimboot-latest.zip

wget http://git.ipxe.org/releases/wimboot/wimboot-latest.zip

Install unzip on your FOG server if it is missing:

如果缺少,请在您的FOG服务器上安装解压缩文件:

aptitude install unzip

aptitude install unzip

Unzip the wimboot package:

解压缩wimboot软件包:

unzip wimboot-latest.zip

unzip wimboot-latest.zip

Copy the wimboot module to the “libs” directory we created in the previous segment:

将wimboot模块复制到我们在上一部分中创建的“ libs”目录中:

cp -va wimboot*/wimboot /tftpboot/howtogeek/libs/

cp -va wimboot*/wimboot /tftpboot/howtogeek/libs/

That is all. The wimboot bootloader is ready to be called upon.

就这些。 准备好调用wimboot引导加载程序。

Windows CD文件 (Windows CD files)

Create a new directory on the FOG server to hold the files we will copy over:

在FOG服务器上创建一个新目录,以保存我们将复制的文件:

mkdir -p /tftpboot/howtogeek/WinPE/

mkdir -p /tftpboot/howtogeek/WinPE/

Put the original Windows 7 install CD in your CDROM drive and copy the files listed below into this directory:

将原始的Windows 7安装CD放入CDROM驱动器中,并将下面列出的文件复制到此目录中:

\bootmgr

\ bootmgr

\boot\bcd

\ boot \ bcd

\boot\boot.sdi

\ boot \ boot.sdi

\sources\boot.wim

\ sources \ boot.wim

Yes, it is that simple and you don’t need to keep the directory structure on the CD for this to work.

是的,就是这么简单您无需在CD上保留目录结构即可工作。

Note: in order to have the Dell BIOS updates work, I’ve found it to be necessary to use a 32-bit version of Windows.

注意:为了使Dell BIOS更新正常工作,我发现有必要使用32位版本的Windows。

添加菜单项 (Add the menu entry)

Create the PXE menu entry by editing the “Utils” menu:

通过编辑“实用程序”菜单来创建PXE菜单项:

sudo vim /tftpboot/howtogeek/menus/utils.cfg

sudo vim /tftpboot/howtogeek/menus/utils.cfg

Append to it the following:

附加以下内容:

label WinPE
com32 linux.c32 howtogeek/libs/wimboot
APPEND wimboot initrdfile=/howtogeek/WinPE/bootmgr,/howtogeek/WinPE/bcd,/howtogeek/WinPE/boot.sdi,/howtogeek/WinPE/boot.wim

label WinPE
com32 linux.c32 howtogeek/libs/wimboot
APPEND wimboot initrdfile=/howtogeek/WinPE/bootmgr,/howtogeek/WinPE/bcd,/howtogeek/WinPE/boot.sdi,/howtogeek/WinPE/boot.wim

Congratulations, You now have WindowsPE on your PXE server. :)

恭喜,您现在在PXE服务器上安装了WindowsPE。 :)

Note: it may look like its hanging on the “wim” file, but it isn’t. It is actually transferring the 140MB of a file to the client over TFTP, which takes longer than the usually small files that are transferred this way.

注意:它看起来好像挂在“ wim”文件上,但事实并非如此。 实际上,它正在通过TFTP将文件的140MB传输到客户端,这比通过这种方式传输的通常较小的文件花费的时间更长。

Here is the screenshot to prove that it did happen.

这是截图证明它确实发生了。

The VM above, was run using VMware-player,  had Ubuntu installed on its HD and was PXE booted into WinPE.

上面的VM使用VMware播放器运行,并在其HD上安装了Ubuntu,并通过PXE引导到WinPE中。

Windows恢复控制台 (Windows Recovery Console)

Again, as mentioned in the overview, while it looks like you can start the windows install procedure this way, you actually can’t complete it, and making that possible is beyond the scope of this guide.

再次,如概述中所述,虽然看起来您可以通过这种方式启动Windows安装过程,但实际上无法完成该过程,并且使之成为可能超出了本指南的范围。

With that said, just to give one example of why this would be useful, we will use this environment to perform a Dell BIOS update.

话虽如此,仅举一个为什么这样做有用的示例,我们将使用此环境执行Dell BIOS更新。

Get the update you need to perform from Dell’s website and put it on a Disk-On-Key. Put the Disk on key and PXE boot the client.

从Dell网站获取您需要执行的更新,并将其放在Key-Disk-On-Key上。 将磁盘放在钥匙上,然后PXE引导客户端。

In order to reach the recovery console, in the main window as in the screenshot above, click “Next”.

为了访问故障恢复控制台,请在上面的屏幕快照中的主窗口中,单击“下一步”。

Click on “Repair your computer”.

点击“修复计算机”。

Choose “Use recovery tools” and click on “Next”.

选择“使用恢复工具”,然后单击“下一步”。

Click on “Command Prompt”.

点击“命令提示符”。

Once in the command prompt, you will have to find out what “drive letter” WinPE decided to designate to your Disk-on-Key. To do this, have the system enumerate all of the currently assigned drive-letters by issuing:

进入命令提示符后,您将必须找出WinPE决定指定给“密钥磁盘”的“驱动器号”。 为此,请让系统通过发出以下命令枚举所有当前分配的驱动器盘符:

wmic logicaldisk get name

wmic logicaldisk get name

Now excluding the letters A: and X: and perhaps even C: (though its not a given), cycle through the drive letters and look for the Disk-on-Key by issuing:

现在排除字母A:和X:甚至C :(尽管不是给定的),循环浏览驱动器字母,并通过发出以下命令查找“ Key on Disk”:

Driveletter:
dir

Driveletter:
dir

Once you’ve found the correct drive, execute the file and you should see something like the below:

找到正确的驱动器后,执行文件,您应该看到类似以下的内容:

Congratulations, you are all set to upgrade :)

恭喜,您已经准备升级:)



I Know Kung Fu…

我知道功夫…

翻译自: https://www.howtogeek.com/162070/it-geek-how-to-network-boot-pxe-the-winpe-recovery-disk-with-pxelinux-v5-wimboot/

pxelinux

pxelinux_IT怪胎:如何使用PXElinux v5和Wimboot网络引导(PXE)WinPE恢复磁盘相关推荐

  1. 《剑侠情缘V5.0》网络单机版烽火诸侯私服搭建

    <剑侠情缘V5.0>网络单机版烽火诸侯私服搭建 <剑侠情缘V5.0>私服单机架设 搭建环境: 1.winXP 2.虚拟机 3. SQL2000+SP4升级补丁 4.服务端Ser ...

  2. linux pxe启动ftp格式,FTP+DHCP+TFTP+PXElinux实现RHLINUX的网络自动安装

    (一)原理 第一步:PXE Client向DHCP发送请求 首先,将支持PXE的网络接口卡(NIC)的客户端的BIOS设置成为网络启动,通过PXE BootROM(自启动芯片)会以UDP(简单用户数据 ...

  3. Kickstart+NFS+DHCP+TFTP+PXElinux实现CentOS的网络自动安装

    作者:diege 时间:2012-05-02 第三次整理 一:准备工作 1:安装centos系统,配置好网络 二:安装各软件 1:配置yum 2:安装kickstart # yum -y instal ...

  4. pxelinux.0:winboot:网络引导(启动)wim格式的windows PE系统:配置文件写法

    关键:加载wimboot引导模块,并传入参数 todo:通过标准kenerl的append传入启动参数..........todo.todo default menu.c32label wimboot ...

  5. 在 Ubuntu 14.04 中配置 PXE 服务器

    PXE(预启动执行环境Preboot Execution Environment)服务器允许用户从网络中启动 Linux 发行版并且可以不需要 Linux ISO 镜像就能同时在数百台 PC 中安装. ...

  6. Linux DNS分离解析与Web服务器综合实验和搭建批量装机环境 、 配置PXE引导 、kickstart自动应答(SERVICE05----DAY20)

    DNS分离解析与Web服务器综合实验 一 虚拟机C构建Web服务 [root@C ~]# yum -y install httpd [root@C ~]# vim /etc/httpd/conf.d/ ...

  7. skylake服务器处理器M系列,行业——华为三大v5机架式服务器改用Skylake处理器

    原标题:行业--华为三大v5机架式服务器改用Skylake处理器 行业--华为三大v5机架式服务器改用Skylake处理器 Intel Skylake是英特尔第六代微处理器架构,2015年正式发布,采 ...

  8. 数据驱动安全架构升级---“花瓶”模型迎来V5.0(二)

    三."花瓶"模型V5.0 "花瓶"模型V5.0是从安全事件防护的角度,设计安全保障架构的.事前制定策略,部署防护措施,提高攻击门槛,阻断常规的入侵攻击:事中监控 ...

  9. 详细解读Windows8.1 Update中的WIMBoot新特性

    微软在Windows8.1 Update发布免费更新后,越来越多win8系统用户选择了升级,在Windows8.1 Update全新系统中有一项WIMBoot新技术,面对新特性很多用户还是一筹莫展,不 ...

最新文章

  1. 简单配置snmpd.conf
  2. 谷歌TensorFlow Lite支持Core ML
  3. 联想万全t260磁盘阵列_联想万全T260G3服务器安装windows2008R2系统
  4. linux源码包与RPM包的区别
  5. 力扣-572. 另一棵树的子树
  6. 在linux环境下编译运行OpenCV程序的两种方法 - woshijpfgg
  7. 《ARM Cortex-M3权威指南》--语句摘要
  8. 整理一下N年前写的java web考勤管理系统
  9. java代码生成springdao_可一键生成dao、表、controller等几十种的代码生成器源码分享...
  10. PTA-1021-Deepest Root
  11. vc2010下调用miniblink控件实现浏览器简单实例
  12. PeopleSoft 配置文件
  13. 茶饮连锁门店数字化转型
  14. layui管理后台模板
  15. ubuntu下Android开发环境的搭建:eclipse+SDK详细安装教程+常见问题及其解决方案
  16. 智能合约隐私计算之同态加密应用举例
  17. 【叶子函数分享二十三】计算两个日期之间的工作日
  18. Buffer Overflow Vulnerability Prediction from x86 executables using Static Analysis and ML
  19. 全能电子地图实时路况_全能SUV与城市SUV的区别在哪?日产奇骏对比本田皓影
  20. [转载]20行Python代码爬取王者荣耀全英雄皮肤

热门文章

  1. 2016开门红 亿赛通中标中信银行助建电子文档安全
  2. ENG Note 1 : 英语写作模板
  3. .NET自助建站系统开发框架源码 PC端+WAP端+微信端
  4. Cannot use /dev/sdc: device is rejected by filter config报错处理
  5. html给div设置宽度无效,HTML学习之给div高度设置百分比不生效的问题
  6. 花式玩转Linux集群免密登录
  7. Codeforces Round #360(div2)
  8. Spring Boot中的application.properties配置简介(二)
  9. 使用微信推送报警消息及api
  10. 【转载】采购订单中的容差