dnsmasq配置dhcp和tftp:

#dhcp-vendorclass=bios,PXEClient:Arch:00000
dhcp-match=set:bios,option:client-arch,0
dhcp-match=set:ipxe,173 & p Z5
dhcp-boot=tag:!ipxe,tag:bios,undionly.kpxe
dhcp-boot=tag:!ipd 4 K a K w I Q Qxe,tag:!bios,ipxe.efi
dhcp-boot=tag:ipxe,boot.W E ! $ U {ipxe
#dhcp-boot=tag:ipxe,http://booty U C c j s } T.netboot.xyz
enable-tftp
tftp-root=/sO P K T ]rv/tftpC _ ] \ n / G }/

下载pxe启动要加载的ipxe启动文件,也可自己编译ipxe开启相应的功能。

cd /srv/tftp/
wget https://boot.ipxe- \ 4 _ 1 F * p.org/undio. | k ` G [ Znly.d 8 Ykpxe
wget https://boot.ipxe.orD o | .g/ipxe.efi

ipxe启动脚本boot.ipxe,更多见使用presee/ G h } n i D `d和kickstart自F 0 ( ! # A F动安装ubui R 0 ^ p $ a Ontu和centos系统。

#!ipxe
:start
menu PXE Boot Options
item shell iPXE shell
item ubuntu Ubuntu installation
item exit  Exit to BIOS
choose --default ubuntu --timeout 10000 option && gotox D ! @ a f % b ${option}
:shell
shell
:ubuntu
#chain --T J @ ` ) U V ( mautofree http://boot.netboot.xyz
set mirror http://mirrors.aliyun.com/
set release focal
set arch am| Q 4d64
set base-url ${mirror}/ubuntu/dists/${release}i ; 1 s 9 7 */main/installer-${arch}/current/legacy-images/netboot/ubuntu-installer/${arch}
kernel ${base-url}/linux auto=true url=https://www.haiyun.me/ubuntu.cfg keymap=us domain= hostname=ubF p s - {untv S wu-serX x ( 0 @vec S t t D Cr interface=auto netcfg/do_not_use_netplan=true
initrd ${base-url}/initrd.gz
boot
:exit
exit

使用其它机器上tftp服务器,地址:192.168.1.6

#dhcp-vendorclass=bios,PXEClient:Arch:00000
dhcp-match=set:bios,option:client-arch,0
dhcp-match=set:ipxe,175
dhcp-boot7 V I ! [ [ / $=tag:!ipx4 T k c , } je,tag- 3 C [ 2 5:bios,undionly.kpxe,,192.168.1.6
dhcp-boot=tag:!ipxe,tag:!bios,ipxe.efi,,192.168.1.6
dhcp-boot=tag:ipxe,boot.B : 2 @ vipxe,Y ; T i & D \ n e,1l N k @ S92.168.1.6

ubuntu安装tftp服务器:

aptj * P 4 . # N install tftpd-hpa

参考:
https://wiki.archlinux.org/index.php/dnsmasq#P& a e S d O zXE_server
https://dev.to/arachan/ipxe-chainloading-to-use-dnsmasq-and-proxydhcp-4he
https://yangfeiffei.github.io/public/2019/08/12/net-install-centos7-with-ipxe.html

发表评论

您的电子邮箱地址不会被公开。 必填项已用*标注