无忧启动论坛

 找回密码
 注册
搜索
系统gho:最纯净好用系统下载站广告联系 微信:wuyouceo QQ:184822951
查看: 3346|回复: 9
打印 上一主题 下一主题

[原创] Padavan路由器PXE自动判断BiOS与UEFI

[复制链接]
跳转到指定楼层
1#
发表于 2022-4-16 15:42:43 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
本帖最后由 minchengan 于 2022-4-18 16:09 编辑

玩了几天路由器PXE,我用的是Padavan固件,这个固件可以自定义配置文件 "dnsmasq.conf",修改里面的内容可以实现自动判断BIOS或UEFI,然后分别下载相应的引导程序,这里面的内容如下:我就不上图了,很简单的,有这个路由器的可以玩一下,我在路由器上开了ftp和http,http在扩展功能里

具体内容见4楼,是修改后的版本,可以自定义菜单名


2#
 楼主| 发表于 2022-4-16 15:50:03 | 只看该作者
使用的ipxe.efi能默认下载菜单文件menu.ipxe,但只支持efi引导,灰大师的那个ipxe.pxe可以同时支持BIOS和UEFI(在TinyPXE中测试的),但是不知道是否有默认下载菜单功能,测试了很久都没有弄清楚那个默认菜单文件名是否存在。lpxelinux.0是centos8里的,对BIOS支持的较好
回复

使用道具 举报

3#
发表于 2022-4-16 20:40:33 | 只看该作者
这些英文是某个文件还是要输入的命令啊?看不懂

点评

自定义配置文件 "dnsmasq.conf  发表于 2022-4-17 00:47
回复

使用道具 举报

4#
 楼主| 发表于 2022-4-17 20:01:18 | 只看该作者
本帖最后由 minchengan 于 2022-4-18 16:06 编辑

下面的配置解决了不能自动加载菜单脚本文件的问题:参考了这个帖子,vmware下测试成功:http://bbs.wuyou.net/forum.php?m ... 16744&extra=&page=1

# Custom user conf file for dnsmasq
# Please add needed params only!

### Web Proxy Automatic Discovery (WPAD)
dhcp-option=252,"\n"

### Set the limit on DHCP leases, the default is 150
#dhcp-lease-max=150

### Add local-only domains, queries are answered from hosts or DHCP only
#local=/router/localdomain/

### Examples:

### Enable built-in TFTP server
enable-tftp

### Set the root directory for files available via TFTP.
#tftp-root=/opt/srv/tftp
tftp-root=/media/AiDisk_a1/pxe
#tftp-root=/media/o_p_t_img/wwwroot/default/pxe

### Make the TFTP server more secure
#tftp-secure

### Set the boot filename for netboot/PXE
#dhcp-boot=pxelinux.0
#dhcp-boot=ipxe.efi
#dhcp-boot=ipxe.pxe
#dhcp-boot=grldr
#dhcp-boot=ipxegrldr
#dhcp-boot=lpxelinux.0

dhcp-match=set:iPXE,175

dhcp-vendorclass=set:flag,PXEClient:Arch:00000
dhcp-vendorclass=set:flag,PXEClient:Arch:00006
dhcp-vendorclass=set:flag,PXEClient:Arch:00007
dhcp-vendorclass=set:flag,PXEClient:Arch:00009

tag-if=set:load,tag:!iPXE,tag:flag

###手动选择====================
####pxe-prompt="Press F8 or Enter key for PXE menu.", 5
###BIOS MENU
#pxe-service=tag:load,X86PC, "BIOS ipxe undionly", undionly.kpxe
#pxe-service=tag:load,X86PC, "BIOS ipxe.pxe", ipxe.pxe
#pxe-service=tag:load,X86PC, "BIOS Microsoft PXE", pxeboot.n12
#pxe-service=tag:load,X86PC, "boot from local", 0
###UEFI MENU
#pxe-service=tag:load,IA32_EFI, "Microsoft UEFI (IA32_EFI)", bootia32.efi
#pxe-service=tag:load,X86-64_EFI, "Microsoft UEFI (X86-64_EFI)", bootx64.efi
#pxe-service=tag:load,BC_EFI, "Microsoft UEFI(BC-EFI)", bootx64.efi
#pxe-service=tag:load,6, "iPXE snponly UEFI32(6)", snponly32.efi
#pxe-service=tag:load,7, "iPXE snponly UEFI(7)", snponly.efi
#pxe-service=tag:load,9, "iPXE snponly UEFI(9)", snponly.efi
#pxe-service=tag:load,06,  "iPXE UEFI32(06)", ipxe32.efi
#pxe-service=tag:load,07,  "iPXE UEFI(07)", ipxe.efi
#pxe-service=tag:load,09,  "iPXE UEFI(09)", ipxe.efi
###手动选择==========================

###自动检测=====================================
dhcp-match=set:Intel_x86PC,option:client-arch,0
###dhcp-boot=tag:Intel_x86PC,lpxelinux.0
dhcp-boot=tag:Intel_x86PC,ipxe.pxe
dhcp-match=set:EFI_BC,option:client-arch,7
dhcp-boot=tag:EFI_BC,ipxe.efi
dhcp-match=set:EFI_x86_64,option:client-arch,9
dhcp-boot=tag:EFI_x86_64,ipxe.efi
#dhcp-match=set:EFI_Arm64,option:client-arch,11
#dhcp-boot=tag:EFI_Arm64,netbootaa64.efi
#dhcp-match=set:Mips,option:client-arch,12
###自动检测=====================================

dhcp-boot=tag:iPXE,menu.ipxe

# 过滤 IPv6(AAAA)查询请求
#filter-aaaa

回复

使用道具 举报

5#
 楼主| 发表于 2022-4-18 16:27:35 | 只看该作者
本帖最后由 minchengan 于 2022-4-18 16:41 编辑

我的menu.ipxe,可以配合前面Padavan固件里的dnsmasq来自动显示BIOS或UEFI菜单,BIOS用的是灰大师的ipxe.pxe,efi是另外找的一个ipxe.efi(不知道怎么在论坛上传附件)。内容如下:(安装系统部分没有完成,)

#!ipxe
dhcp net0
set gateway 0.0.0.0
#set keep-san 1
#sanhook iscsi:192.168.1.248:tcp:3260:0:iqn.2000-01.com.synology:test


#set boot-url http://${next-server}:81/pxe
#-------------------------------------------------------------------------
#check platform (pcbios or efi), buildarch (i386 or X86_64)
echo Platform: ${platform}
echo Buildarch: ${buildarch}


#set menu-timeout 10000


#isset ${ip} || dhcp
#isset ${next-server} || set next-server 192.168.11.1
iseq ${platform} efi && set start EFI_Start || set start BIOS_Start
goto ${start}


#>Begin iPXE uEFI Boot ===========================================
:EFI_Start
#    console --picture http://${next-server}:81/pxe/bg.png --top 100 --left 100 --right 100 --bottom 100 ||
#    console --picture http://${next-server}:81/pxe/bg.png
#    menu background http://${next-server}:81/pxe/bg.png ||
    cpuid --ext 29 && set arch X64 || set arch X86
    #iseq ${buildarch} i386 set arch X86 || set arch X64
    set menu-default EFI_WinPE_ISO
    menu iPXE uEFI Boot Menu -- ${ip}
    item --gap --                  ----------------------- uEFI WinPE & MiniLinux ------------------------
    item --key 1 EFI_WinPE_ISO     Boot WinPE ${arch} (winpe.iso) ------------------------------- Hotkey 1
    item --key 2 EFI_WinPE_WIM     Boot WinPE ${arch} (boot.wim) -------------------------------- Hotkey 2
    item --key 3 EFI_Mini_Linux    Boot MiniLinux (minilinux.iso) --------------------------- Hotkey 3
    item --key m EFI_WinPE_More    More uEFI WinPE... --------------------------------------- Hotkey m
    item --gap --
    item --gap --                  -------------------------- System Install -----------------------------
    item --key i EFI_Install       Install System... ---------------------------------------- Hotkey i
    item --gap --
###以下注释,不支持uefi引导
#    item --gap --                  ----------------------- Utilities Menu Options ------------------------
#    item --key t Tools             More Tools... -------------------------------------------- Hotkey t
#    item --key p Load_Lpxelinux    Load lpxelinux ------------------------------------------- Hotkey p
#    item --key g Load_Ipxegrldr    Load ipxegrldr ------------------------------------------- Hotkey g
#    item --gap --
    item --gap --                  -------------------------- Advanced options ---------------------------
    item --key c Config            Configure settings --------------------------------------- Hotkey c
    item --key s Shell             Drop to iPXE shell --------------------------------------- Hotkey s
    item --key r Reboot            Reboot --------------------------------------------------- Hotkey r
#    item --key h Power             Halt ----------------------------------------------------- Hotkey h
#    item --key x Exit              Exit iPXE and continue boot ------------------------------ Hotkey x
    choose --timeout ${menu-timeout} --default ${menu-default} selected
    goto ${selected}


:EFI_WinPE_ISO
sanboot --no-describe http://${next-server}:81/pxe/iso/winpe.iso
boot
goto ${start}


:EFI_WinPE_WIM
kernel http://${next-server}:81/pxe/wimboot
initrd http://${next-server}:81/pxe/boot/boot7x64.efi                                        bootx64.efi
initrd http://${next-server}:81/pxe/boot/bcd                               BCD
initrd http://${next-server}:81/pxe/boot/chs_boot.ttf        chs_boot.ttf
initrd http://${next-server}:81/pxe/boot/wgl4_boot.ttf        wgl4_boot.ttf
initrd http://${next-server}:81/pxe/boot/boot.sdi                                        boot.sdi
initrd http://${next-server}:81/pxe/iso/boot.wim                                boot.wim
boot
goto ${start}


:EFI_Mini_Linux
sanboot --no-describe http://${next-server}:81/pxe/iso/minilinux.iso
boot
goto ${start}


#============uEFI Boot More WinPE Menu Options ======
:EFI_WinPE_More
menu uEFI Boot More WinPE
#    item --key 0 WinPE7_EFI        Boot uEFI WinPE7 .. (winpe7_efi.iso) --------------------- Hotkey 0
    item --key 1 WinPE8_EFI        Boot uEFI WinPE8 .. (winpe8_efi.iso) --------------------- Hotkey 1
    item --key 2 WinPE10_EFI       Boot uEFI WinPE10 . (winpe10_efi.iso) -------------------- Hotkey 2
    item --key 3 WinPE11_EFI       Boot uEFI WinPE11 . (winpe11_efi.iso) -------------------- Hotkey 3
    item back Back to top menu...
iseq ${menu-default} menu-recovery && isset ${submenu-default} && goto menu-recovery-timed ||
choose selected && goto ${selected} || goto ${start}


:menu-recovery-timed
choose --timeout ${submenu-timeout} --default ${submenu-default} selected && goto ${selected} || goto ${start}


:WinPE7_EFI
    sanboot --no-describe http://${next-server}:81/pxe/iso/winpe7_efi.iso
    boot
    goto ${start}


:WinPE8_EFI
    sanboot --no-describe http://${next-server}:81/pxe/iso/winpe8_efi.iso
    boot
    goto ${start}


:WinPE10_EFI
    sanboot --no-describe http://${next-server}:81/pxe/iso/winpe10_efi.iso
    boot
    goto ${start}


:WinPE11_EFI
    sanboot --no-describe http://${next-server}:81/pxe/iso/winpe11_efi.iso
    boot
    goto ${start}
#<End uEFI Boot More WinPE Menu Options ===================


#============ uEFI Boot System Install Menu Options ======
:EFI_Install
menu uEFI Boot System Install
#    item --key 0 Install_Win7_EFI  Boot Install Win 7 (windows7.iso) ------------------------ Hotkey 0
    item --key 1 Install_Win8_EFI  Boot Install Win 8 (windows8.iso) ------------------------ Hotkey 1
    item --key 2 Install_Win10_EFI Boot Install Win10 (windows10.iso) ----------------------- Hotkey 2
    item --key a Install_Win11_EFI Boot Install Win11 (windows11.iso) ----------------------- Hotkey a
    item --key b Install_Linux_EFI Boot Install Linux (linux.iso) --------------------------- Hotkey b
    item back Back to top menu...
iseq ${menu-default} menu-recovery && isset ${submenu-default} && goto menu-recovery-timed ||
choose selected && goto ${selected} || goto ${start}


:menu-recovery-timed
choose --timeout ${submenu-timeout} --default ${submenu-default} selected && goto ${selected} || goto ${start}


:Install_Win7_EFI
    sanboot --no-describe http://${next-server}:81/pxe/iso/windows7.iso
    boot
    goto ${start}


:Install_Wi8_EFI
    sanboot --no-describe http://${next-server}:81/pxe/iso/windows8.iso
    boot
    goto ${start}


:Install_Win10_EFI
    sanboot --no-describe http://${next-server}:81/pxe/iso/windows10.iso
    boot
    goto ${start}


:Install_Win11_EFI
    sanboot --no-describe http://${next-server}:81/pxe/iso/windows11.iso
    boot
    goto ${start}


:Install_Linux_EFI
    sanboot --no-describe http://${next-server}:81/pxe/iso/linux.iso
    boot
    goto ${start}
#<End uEFI System Install Menu Options ===================
#<End iPXE uEFI Boot =================================




#>Begin iPXE BIOS Boot =================================
:BIOS_Start
    console --picture http://${next-server}:81/pxe/bg.png --top 100 --left 100 --right 100 --bottom 100 ||
#    console --picture http://${next-server}:81/pxe/bg.png
#    menu background http://${next-server}:81/pxe/bg.png ||
    cpuid --ext 29 && set arch X64 || set arch X86
    set menu-default WinPE_iso
    menu iPXE BIOS Boot Menu -- ${ip}
    item --gap --                  --------------------- WinPE & MiniLinux -----------------------
    item --key 1 WinPE_iso         Boot WinPE (winpe.iso) ------------------------- Hotkey 1
    item --key 2 Mini_Linux        Boot MiniLinux (minilinux.iso) ----------------- Hotkey 2
    item --key m WinPE_more        More WinPE... ---------------------------------- Hotkey m
    item --gap --
    item --gap --                  ---------------------- System Install -------------------------
    item --key i Install           Install System... ------------------------------ Hotkey i
    item --gap --
    item --gap --                  ------------------- Utilities Menu Options --------------------
    item --key t Tools             More Tools... ---------------------------------- Hotkey t
    item --key p Load_Lpxelinux    Load lpxelinux --------------------------------- Hotkey p
    item --key g Load_Ipxegrldr    Load ipxegrldr --------------------------------- Hotkey g
    item --gap --
    item --gap --                  ---------------------- Advanced options -----------------------
    item --key c Config            Configure settings ----------------------------- Hotkey c
    item --key s Shell             Drop to iPXE Shell ----------------------------- Hotkey s
    item --key r Reboot            Reboot ----------------------------------------- Hotkey r
    item --key h Power             Halt ------------------------------------------- Hotkey h
#    item --key x Exit              Exit iPXE and continue boot -------------------- Hotkey x
    choose --timeout ${menu-timeout} --default ${menu-default} selected
    goto ${selected}
   
:WinPE_iso
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/winpe.iso
    boot
    goto ${start}


:Mini_Linux
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/minilinux.iso
    boot
    goto ${start}


#============BIOS boot More WinPE Menu Options ======
:WinPE_more
menu BIOS boot More WinPE
    item --key 1 WinPEXP           Boot WinPEXP . (winpexp.iso) ------------------- Hotkey 1
    item --key 2 WinPE7            Boot WinPE7 .. (winpe7.iso) -------------------- Hotkey 2
    item --key 3 WinPE8            Boot WinPE8 .. (winpe8.iso) -------------------- Hotkey 3
    item --key 4 WinPE10           Boot WinPE10 . (winpe10.iso) ------------------- Hotkey 4
    item --key 5 WinPE11           Boot WinPE11 . (winpe11.iso) ------------------- Hotkey 5
    item back Back to top menu...
iseq ${menu-default} menu-recovery && isset ${submenu-default} && goto menu-recovery-timed ||
choose selected && goto ${selected} || goto ${start}


:menu-recovery-timed
choose --timeout ${submenu-timeout} --default ${submenu-default} selected && goto ${selected} || goto ${start}


:WinPEXP
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/winpexp.iso
    boot
    goto ${start}


:WinPE7
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/winpe7.iso
    boot
    goto ${start}


:WinPE8
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/winpe8.iso
    boot
    goto ${start}


:WinPE10
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/winpe10.iso
    boot
    goto ${start}


:WinPE11
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/winpe11.iso
    boot
    goto ${start}
#<End BIOS boot More WinPE Menu Options ===================


#============BIOS boot System Install Menu Options ======
:Install
menu BIOS boot System Install
    item --key 1 Install_WinXP     Boot Install WinXP (windowsxp.iso) ------------- Hotkey 1
    item --key 2 Install_Win7      Boot Install Win 7 (windows7.iso) -------------- Hotkey 2
    item --key 3 Install_Win8      Boot Install Win 8 (windows8.iso) -------------- Hotkey 3
    item --key 4 Install_Win10     Boot Install Win10 (windows10.iso) ------------- Hotkey 4
    item --key a Install_Win11     Boot Install Win11 (windows11.iso) ------------- Hotkey a
    item --key b Install_Linux     Boot Install Linux (linux.iso) ----------------- Hotkey b
    item back Back to top menu...
iseq ${menu-default} menu-recovery && isset ${submenu-default} && goto menu-recovery-timed ||
choose selected && goto ${selected} || goto ${start}


:menu-recovery-timed
choose --timeout ${submenu-timeout} --default ${submenu-default} selected && goto ${selected} || goto ${start}


:Install_WinXP
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/windowsxp.iso
    boot
    goto ${start}


:Install_Win7
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/windows7.iso
    boot
    goto ${start}


:Install_Win8
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/windows8.iso
    boot
    goto ${start}


:Install_Win10
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/windows10.iso
    boot
    goto ${start}


:Install_Win11
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/windows11.iso
    boot
    goto ${start}


:Install_Linux
    kernel http://${next-server}:81/pxe/memdisk iso raw
    initrd http://${next-server}:81/pxe/iso/linux.iso
    boot
    goto ${start}
#<End BIOS boot System Install Menu Options ===================
#<End iPXE BIOS Boot =================================


#============ More Tools Menu Options ==========
:Tools
    menu More Tools
    item maxdos    MaxDos
    item dgdisk    Diskgenius
    item WinPW    Windows Password Clear
    item back Back to top menu...
    iseq ${menu-default} menu-recovery && isset ${submenu-default} && goto menu-recovery-timed ||
    choose selected && goto ${selected} || goto ${start}
:menu-recovery-timed
    choose --timeout ${submenu-timeout} --default ${submenu-default} selected && goto ${selected} || goto ${start}


:maxdos
    initrd http://${next-server}:81/pxe/images/maxdos.img
    kernel http://${next-server}:81/pxe/memdisk raw || goto failed
    boot || goto failed
    goto ${start}


:dgdisk
    initrd http://${next-server}:81/pxe/images/diskgenius.img
    kernel http://${next-server}:81/pxe/memdisk raw || goto failed
    boot || goto failed
    goto ${start}


:WinPW
    initrd http://${next-server}:81/pxe/images/winpw.img
    kernel http://${next-server}:81/pxe/memdisk raw || goto failed
    boot || goto failed
    goto ${start}
#<End Utilities Menu Options ===================


:Load_Lpxelinux
    chain http://${next-server}:81/pxe/lpxelinux.0
    goto ${start}


:Load_Ipxegrldr
    chain http://${next-server}:81/pxe/ipxegrldr.0
    goto ${start}


:Failed
    echo Booting Failed, dropping to shell
    goto Shell
    goto ${start}


:Config
    config
    goto ${start}


:Shell
    echo Type 'exit' to go back to the menu.
    shell
    goto ${start}


:Power
    poweroff


:Reboot
    reboot


:Exit
    exit


回复

使用道具 举报

6#
 楼主| 发表于 2022-4-18 17:20:08 | 只看该作者
ipxegrldr用的菜单:menu.lst,只支持bios引导?好像不支持http/ftp?

timeout 30
default 0

title WINPE(winpexp.iso+tftp)
map --mem (pd)/iso/winpexp.iso (0xff)
###ipxegrldr不支持http/ftp
#map --mem http://99.99.99.1:81/pxe/iso/winpexp.iso (0xff)
map --hook
chainloader (0xff)
boot

title boot from hard disk
root (hd0,0)
chainloader +1
boot

title command line
commandline

title reboot
reboot

title halt
halt

回复

使用道具 举报

7#
 楼主| 发表于 2022-4-18 17:23:44 | 只看该作者
lpxelinux.0用的菜单:pxelinux.cfg/default,只支持BIOS引导,支持http,不支持ftp,本菜单中安装操作系统部分还没有测试完成

default vesamenu.c32
#标准菜单(默认是menu.c32蓝色菜单)
#default menu.c32
prompt 0
#timeout 100
#菜单等待时间(10秒)
ontimeout WinPE
#超时启动项
#display boot.msg
#显示描述信息(有描述信息的话)

menu clear
#自定义背景
menu background splash.png
#启动菜单抬头
menu title iPXE Boot Menu

##########配合menu.c32蓝色菜单
#   menu color screen   37;40               #80ffffff #00000000 std
#   menu color border   30;44               #400060 #00000000 std
#   menu color title   1;36;44              #20ff00 #00000000 std
#   menu color unsel   37;44                #ffff00 #00000000 std
#   menu color hotkey   1;37;44             #ffffffff #00000000 std
#   menu color sel      7;37;40             #ff0000 #20ff8000 all
#   menu color hotsel   1;7;37;40           #e0400000 #20ff8000 all
#   menu color disabled   1;30;44           #60cccccc #00000000 std
#   menu color scrollbar   30;44            #20ff00 #00000000 std
#   menu color tabmsg   31;40               #2000ff #00000000 std
#   menu color cmdmark   1;36;40            #c000ffff #00000000 std
#   menu color cmdline   37;40              #c0ffffff #00000000 std
#   menu color pwdborder   30;47            #80ffffff #20ffffff std
#   menu color pwdheader   31;47            #80ff8080 #20ffffff std
#   menu color pwdentry   30;47             #80ffffff #20ffffff std
#   menu color timeout_msg   37;40          #600000 #00000000 std
#   menu color timeout   1;37;40            #40ffff #00000000 std
#   menu color help      37;40              #c0ffffff #00000000 std
#   menu color msg07   37;40                #90ffffff #00000000 std
#########

##########配合vesamenu.c32的类似centos 8安装程序菜单
menu vshift 2
menu rows 18
menu margin 8
#menu hidden
menu helpmsgrow 21
menu tabmsgrow 19

# Border Area
menu color border * #00000000 #00000000 none
# Selected item
menu color sel 0 #ffffffff #00000000 none
# Title bar
menu color title 0 #ff7ba3d0 #00000000 none
# Press [Tab] message
menu color tabmsg 0 #ff3a6496 #00000000 none
# Unselected menu item
menu color unsel 0 #84b8ffff #00000000 none
# Selected hotkey
menu color hotsel 0 #84b8ffff #00000000 none
# Unselected hotkey
menu color hotkey 0 #ffffffff #00000000 none
# Help text
menu color help 0 #ffffffff #00000000 none
# A scrollbar of some type? Not sure.
menu color scrollbar 0 #ffffffff #ff355594 none
# Timeout msg
menu color timeout 0 #ffffffff #00000000 none
menu color timeout_msg 0 #ffffffff #00000000 none
# Command prompt text
menu color cmdmark 0 #84b8ffff #00000000 none
menu color cmdline 0 #ffffffff #00000000 none

# Do not display the actual menu unless the user presses a key. All that is displayed is a timeout message.
#menu tabmsg Press Tab for full configuration options on menu items.
menu tabmsg Press [Tab] to edit options on menu items.
#########

menu separator # insert an empty line

#WinPE启动#
label WinPE
menu default     #默认菜单
menu label [^1] WinPE ........... with HTTP or FTP-(winpe.iso)
kernel memdisk
#append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/winpe.iso
append iso raw initrd=http://99.99.99.1:81/pxe/iso/winpe.iso

label MiniLinux
menu label [^2] MiniLinux ....... with HTTP or FTP-(minilinux.iso)
kernel memdisk
#append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/minilinux.iso
append iso raw initrd=http://99.99.99.1:81/pxe/iso/minilinux.iso

menu separator # insert an empty line

# More WinPE submenu
menu begin More_WinPE
  menu title More WinPE...
  text help
        More WinPE...
  endtext

  label WinPE-XP
  menu label [^1] WinPE XP ........ with HTTP or FTP-(winpexp.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/winpexp.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/winpexp.iso

  label WinPE-Win7
  menu label [^2] WinPE Win7 ...... with HTTP or FTP-(winpe7.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/winpe7.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/winpe7.iso

  label WinPE-Win8
  menu label [^3] WinPE Win8 ...... with HTTP or FTP-(winpe8.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/winpe8.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/winpe8.iso

  label WinPE-Win10
  menu label [^4] WinPE Win10 ..... with HTTP or FTP-(winpe10.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/winpe10.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/winpe10.iso

  label WinPE-Win11
  menu label [^5] WinPE Win11 ..... with HTTP or FTP-(winpe11.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/winpe11.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/winpe11.iso

  menu separator # insert an empty line

  label returntomain
    menu label Return to ^Main menu
    menu exit
menu end

# More MiniLinux submenu
menu begin More_MiniLinux
  menu title More MiniLinux...
  text help
        More MiniLinux...
  endtext

  label MiniLinux1
  menu label [^1] MiniLinux1 ... with HTTP or FTP-(minilinux1.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/minilinux1.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/minilinux1.iso

  label MiniLinux2
  menu label [^2] MiniLinux2 ... with HTTP or FTP-(minilinux2.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/minilinux2.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/minilinux2.iso

  label MiniLinux3
  menu label [^3] MiniLinux3 ... with HTTP or FTP-(minilinux3.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/minilinux3.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/minilinux3.iso

  label MiniLinux4
  menu label [^4] MiniLinux4 ... with HTTP or FTP-(minilinux4.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/minilinux4.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/minilinux4.iso

  label MiniLinux5
  menu label [^5] MiniLinux5 ... with HTTP or FTP-(minilinux5.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/minilinux5.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/minilinux5.iso

  menu separator # insert an empty line

  label returntomain
    menu label Return to ^Main menu
    menu exit
menu end

# Install Windows submenu
menu begin Install_Windows
  menu title Install Windows...
  text help
        Install Windows...
  endtext

  label Install-Win7_x64
  menu label [^1] Install Win7_x64 .. with HTTP or FTP-(windows7.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/windows7.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/windows7.iso

  label Install-Win8_x64
  menu label [^2] Install Win8_x64 .. with HTTP or FTP-(windows8.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/windows8.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/windows8.iso

  label Install-Win10_x64
  menu label [^3] Install Win10_x64 . with HTTP or FTP-(windows10.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/windows10.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/windows10.iso

  label Install-Win11_x64
  menu label [^4] Install Win11_x64 . with HTTP or FTP-(windows11.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/windows11.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/windows11.iso

  menu separator # insert an empty line

  label returntomain
    menu label Return to ^Main menu
    menu exit
menu end

# Install Linux or Unix submenu
menu begin Install_Linux_Unix
  menu title Install Linux or Unix...
  text help
        Install Linux or Unix...
  endtext

  label Install_CentOS
  menu label [^1] Install CentOS .... with HTTP or FTP-(centos.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/centos.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/centos.iso

  label Install_Deepin
  menu label [^2] Install Deepin .... with HTTP or FTP-(deepin.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/deepin.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/deepin.iso

  label Install_Ubuntu
  menu label [^3] Install Ubuntu .... with HTTP or FTP-(ubuntu.iso)
  kernel memdisk
#  append iso raw initrd=ftp://99.99.99.1/AiDisk_a1/pxe/iso/ubuntu.iso
  append iso raw initrd=http://99.99.99.1:81/pxe/iso/ubuntu.iso

  menu separator # insert an empty line

  label returntomain
    menu label Return to ^Main menu
    menu exit
menu end


#再生龙启动,自动安装win10x64-office系统,HTTP传输#
#label clonezilla-live-2.7.3-19-amd64
menu label Install win10x64-office with HTTP
kernel http://88.88.88.160/clonezilla/vmlinuz
append initrd=http://88.88.88.160/clonezilla/initrd.img boot=live union=overlay noswap noeject nolocales vga=788 locales=zh_CN.UTF-8 keyboard-layouts=NONE method=http://88.88.88.160/clonezilla/filesystem.squashfs ocs_live_run="sudo /usr/sbin/ocs-sr -e1 auto -e2 -t -r -c -k -scr -p reboot -f sda1 restoreparts office-win10x64 sda1" ocs_repository="nfs://88.88.88.160/home/partimag/office-win10x64/"

#再生龙启动,手动安装,HTTP传输#
#label clonezilla-live-2.7.3-19-amd64
menu label clonezilla-live with HTTP
kernel http://88.88.88.160/clonezilla/vmlinuz
append initrd=http://88.88.88.160/clonezilla/initrd.img boot=live union=overlay noswap noeject nolocales vga=788 locales=zh_CN.UTF-8 keyboard-layouts=NONE method=http://88.88.88.160/clonezilla/filesystem.squashfs

#再生龙启动,手动安装,TFTP传输#
#label clonezilla-live-2.7.3-19-amd64
menu label clonezilla-live with TFTP
kernel vmlinuz
append initrd=initrd.img boot=live union=overlay noswap noeject nolocales vga=788 locales=zh_CN.UTF-8 keyboard-layouts=NONE fetch=tftp://88.88.88.160/filesystem.squashfs

#centos 安装测试#
#label install centos
menu label install centos with HTTP
kernel vmlinuz
initrd=initrd.img method=http://88.88.88.160/centos devfs=nomount

menu separator # insert an empty line

# Other Tools submenu
menu begin Other_Tools
  menu title Other Tools...
  text help
        Other Tools...
  endtext

  label maxdos
    menu label [^1] Maxdos
    kernel memdisk
#    append initrd=ftp://99.99.99.1/AiDisk_a1/pxe/images/maxdos.img
    append initrd=http://99.99.99.1:81/pxe/images/maxdos.img

  label diskgenius
    menu label [^2] Diskgenius for dos
    kernel memdisk
#    append initrd=ftp://99.99.99.1/AiDisk_a1/pxe/images/diskgenius.img
    append initrd=http://99.99.99.1:81/pxe/images/diskgenius.img

  label winpw
    menu label [^3] Windows password clear
    kernel memdisk
#    append initrd=ftp://99.99.99.1/AiDisk_a1/pxe/images/winpw.img
    append initrd=http://99.99.99.1:81/pxe/images/winpw.img

  menu separator # insert an empty line

  label returntomain
    menu label Return to ^Main menu
    menu exit
menu end

menu separator # insert an empty line

#本地启动#
label local
menu label [^L] Boot from local disk
localboot 0xffff

label reboot
menu label [^R] Reboot
menu immediate
kernel /reboot.c32

label poweroff
menu label [^H] halt
menu immediate
kernel /poweroff.c32


回复

使用道具 举报

8#
发表于 2023-8-15 13:52:43 | 只看该作者
h                                                      h
回复

使用道具 举报

9#
发表于 2023-10-28 20:17:12 | 只看该作者
提示: 作者被禁止或删除 内容自动屏蔽
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|Archiver|捐助支持|无忧启动 ( 闽ICP备05002490号-1 )

闽公网安备 35020302032614号

GMT+8, 2024-4-29 00:01

Powered by Discuz! X3.3

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表