今天锤锤酱为大家带来手动创建启动菜单的教程
首先,我们需要下载ISO镜像,然后解压到除C盘以外的分区根目录
这里我们拿D盘举例子(实际操作非D盘记得修改命令)
然后运行bcdedit命令添加一条PE的启动信息到当前配置文件。
命令如下:
bcdedit /create /d "Windows PE" /device
然后会自动生成一个GUID,格式为{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx},根据此ID执行后续命令
bcdedit /set {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx} ramdisksdidevice partition=d:
bcdedit /set {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx} ramdisksdipath \boot\boot.sdi
bcdedit /create /d "Windows PE" /application osloader
这样就会生成另一个GUID,格式为{yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} ,根据此ID和上面的ID执行后续命令,这里我们要注意区分上面的GUID号码!
bcdedit /set {yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} device ramdisk=[d:]\sources\boot.wim,{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}
bcdedit /set {yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} osdevice ramdisk=[d:]\sources\boot.wim,{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}
bcdedit /set {yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} path \windows\system32\boot\winload.exe
bcdedit /set {yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} systemroot \windows
bcdedit /set {yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} detecthal yes
bcdedit /set {yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} winpe yes
bcdedit /set {yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} nx optin
bcdedit /displayorder {yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} /addlast
安装完会在启动菜单上留下残留,运行msconfig命令删除多余启动项
删除启动显示PE菜单 bcdedit /delete {yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy} /cleanup
文章评论