Trying to boot my Raspberry Pi 4 from netboot

Network Setup

Mikrotik router at 10.10.10.1, serving DHCP for 10.10.10.0/24.
A server at 10.10.10.11 with TFTP and NFS.

Attempts so far

1st Attempt: Using external TFTP server at 10.10.10.11

Configured the DHCP server on Mikrotik with:
Option 67 (boot-file-name): ‘start4.elf’
Option 66 (next-server): ‘10.10.10.11’ (raw value: 0a0a0a0b).
Verified that the Raspberry Pi receives:
VI_ADDR: 10.10.10.17
SI_ADDR: 10.10.10.11.
However, the Raspberry Pi does not download any files from the TFTP server at 10.10.10.11.
Verified that TFTP server works by downloading files from another computer without issues.

2nd Attempt: Using Mikrotik’s built-in TFTP server

Removed next-server configuration from the DHCP server and enabled Mikrotik’s TFTP:

/ip tftp print
    Columns: IP-ADDRESSES, REQ-FILENAME, REAL-FILENAME, ALLOW, READ-ONLY, ALLOW-ROLLOVER, HITS
    # IP-ADDRESSES   REQ-FILENAME  REAL-FILENAME  ALLOW  READ-ONLY  ALLOW-ROLLOVER  HITS
    0 10.10.10.0/24  .*            /usb1-part1/   yes    yes        no                22

Tried downloading files from Mikrotik’s TFTP server:
Using a TFTP client on my laptop, I can connect to 10.10.10.1.
Small files like cmdline.txt (84 bytes) download successfully.
Larger files like start4.elf (2,916.4 KiB) and config.txt (1,529 bytes) fail.
Adjusted max block size on the Mikrotik TFTP server:
Tried 512 and 1454, but neither resolved the issue.

Current Issues

Raspberry Pi receives DHCP Offer correctly (with boot-file-name and next-server), but:
It does not initiate a download from the TFTP server (start4.elf or any other file).
Mikrotik’s built-in TFTP server:
Works for small files.
Fails to serve larger files like start4.elf.

What I Need Help With

Why is the Raspberry Pi not downloading files from the TFTP server, even though it receives the correct SI_ADDR ?
How i check if boot-file-name is well recived by Raspberry Pi?
Are there any limitations or known issues with Mikrotik’s TFTP server for serving larger files?
Is there any specific configuration required on the Raspberry Pi for it to work with Mikrotik’s TFTP server?

Additional Notes

The Raspberry Pi bootloader has been updated to the latest version (April 15, 2024).
Routeros is 7.16.2
TFTP from Mikrotik’s server works partially (only for small files).
All configurations and tests were validated using tcpdump on both the Raspberry Pi and the server.

Would it. It be easier to run dhcp from your boot server? Less moving parts.

Are you sure the bootloader in the pi is updated? As in have you got another working setup you can test on?

dhcp offer
i don t see dchp offer in the last reply now i see it but still have not success

maybe useful, maybe not:
http://forum.mikrotik.com/t/liebert-is-webcard-hid9-ups-monitoring-card-dhcp-compatibility-issue/172372/6

Are you able to put the Pi on it’s own interface into the MikroTik? You can torch the interface and see what’s going on then during the boot process.
You should see dst 69’s for the TFTP going to it then maybe some dst 111’s if you’re booting from an image on nfs?

that should help to figure out where the problem is coming from.

Did you find solution to this ? I am trying on rpi5 with no luck

Hello, i was trying to netboot my rpi4 and the solution to do this is to add these lines to your dhcp server config (i'm using dnsmasq):
dhcp-match=set:client_is_a_pi,97,0:52:50:69:34
dhcp-match=set:client_is_a_pi,97,0:34:69:50:52
pxe-service=tag:client_is_a_pi,0,"Raspberry Pi Boot"

rpi4 dhcp-match client contains special bytes in GUID (97). The first one is for RPI4 (0:52:50).

Try to set next-server in DHCP network, not in option66. I sucked a lot with it and this is the only way I can boot my server with pxeboot. Server is easily download a 15MByte initramfs from the mikrotik TFTP server.

I have the same problem. I can boot RPI5 from dnsmasq, but I cannot from the DHCP server on RouterOS.

This is the dnsmasq.conf:

#Disable DNS server (we only need DHCP/TFTP)

port=0

#DHCP settings

dhcp-authoritative
dhcp-range=10.25.0.100,10.25.0.150,255.255.255.0,24h
dhcp-option=3,10.25.0.1  # Gateway (router IP)
dhcp-option=6,10.25.0.1  # DNS servers
dhcp-option=66,10.25.0.2

#TFTP settings

enable-tftp
tftp-root=/btrfs/kart-infra/tftp-data

log-dhcp
log-facility=/var/log/dnsmasq.log

This is the log from correct booting of RPI5 from dnsmasq-acquired offer:

Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 available DHCP range: 10.25.0.100 -- 10.25.0.150
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 vendor class: PXEClient:Arch:00000:UNDI:002001
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 DHCPDISCOVER(enp3s0) 88:a2:9e:49:ab:36
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 tags: enp3s0
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 DHCPOFFER(enp3s0) 10.25.0.117 88:a2:9e:49:ab:36
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 requested options: 1:netmask, 3:router, 43:vendor-encap, 60:vendor-class,
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 requested options: 66:tftp-server, 67:bootfile-name, 128, 129,
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 requested options: 130, 131, 132, 133, 134, 135
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 next server: 10.25.0.2
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 1 option: 53 message-type 2
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 54 server-identifier 10.25.0.2
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 51 lease-time 1d
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 58 T1 12h
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 59 T2 21h
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 1 netmask 255.255.255.0
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 28 broadcast 10.25.0.255
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 10 option: 66 tftp-server 10.25.0.2
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 3 router 10.25.0.1
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 available DHCP range: 10.25.0.100 -- 10.25.0.150
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 vendor class: PXEClient:Arch:00000:UNDI:002001
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 DHCPREQUEST(enp3s0) 10.25.0.117 88:a2:9e:49:ab:36
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 tags: enp3s0
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 DHCPACK(enp3s0) 10.25.0.117 88:a2:9e:49:ab:36
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 server name: 10.25.0.2
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 next server: 10.25.0.2
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 1 option: 53 message-type 5
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 54 server-identifier 10.25.0.2
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 51 lease-time 1d
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 58 T1 12h
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 59 T2 21h
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 1 netmask 255.255.255.0
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 28 broadcast 10.25.0.255
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 6 dns-server 10.25.0.1
Apr 1 11:30:20 dnsmasq-dhcp[2847]: 355390610 sent size: 4 option: 3 router 10.25.0.1
Apr 1 11:30:21 dnsmasq-tftp[2847]: file /btrfs/kart-infra/tftp-data/25bd8c7d/config.txt not found for 10.25.0.117
Apr 1 11:30:21 dnsmasq-tftp[2847]: sent /btrfs/kart-infra/tftp-data/config.txt to 10.25.0.117

This is DHCP config at RouterOS (I have tried to push the ‘next-server‘ option in every way possible):

/ip dhcp-server option
add code=43 name=43 value="'Raspberry Pi Boot'"
add code=60 name=60 value="'PXEClient'"
add code=66 force=yes name=66 value="'10.25.0.2'"
add code=67 name=67 value="'bootcode.bin'"
/ip dhcp-server option sets
add name=rpi options=66
/ip dhcp-server
add add-arp=yes address-pool=dhcp_pool0 always-broadcast=yes bootp-support=dynamic dhcp-option-set=rpi
interface=bridge lease-time=10m name=dhcp1 use-reconfigure=yes
/ip dhcp-server network
add address=10.25.0.0/24 dhcp-option=66 dhcp-option-set=rpi gateway=10.25.0.1 next-server=10.25.0.2

And this is the DHCP log from RouterOS:


2026-04-01 11:45:01 interface,info ether2 link up (speed 1G, full duplex)
2026-04-01 11:45:08 dhcp,debug dhcp1 received discover id 2938253077 from 0.0.0.0 ''
2026-04-01 11:45:08 dhcp,debug,packet     ciaddr = 0.0.0.0
2026-04-01 11:45:08 dhcp,debug,packet     chaddr = 88:A2:9E:49:AB:36
2026-04-01 11:45:08 dhcp,debug,packet     Msg-Type = discover
2026-04-01 11:45:08 dhcp,debug,packet     Parameter-List = Subnet-Mask,Router,Vendor-Specific,Class-Id,Unk
nown(66),Unknown(67),Unknown(128),Unknown(129),Unknown(130),Unknown(131),Unknown(132),Unknown(133),Unknown
(134),Unknown(135)
2026-04-01 11:45:08 dhcp,debug,packet     Class-Id = "PXEClient:Arch:00000:UNDI:002001"
2026-04-01 11:45:08 dhcp,debug,packet     Unknown(93) = 00-00
2026-04-01 11:45:08 dhcp,debug,packet     Unknown(94) = 01-02-01
2026-04-01 11:45:08 dhcp,debug,packet     Unknown(97) = 00-35-69-50-52-71-41-B0-00-9E-49-AB-36-7D-8C-BD-25

2026-04-01 11:45:08 dhcp,debug lease not found, new lease, acquire
2026-04-01 11:45:08 dhcp,debug ping 10.25.0.250
2026-04-01 11:45:08 dhcp,debug ping done 10.25.0.250
2026-04-01 11:45:08 dhcp,debug dhcp1 on bridge sending offer with id 2938253077 from 10.25.0.1:67 (04:F4:1
C:D5:03:DF) to 255.255.255.255:68 (FF:FF:FF:FF:FF:FF)
2026-04-01 11:45:08 dhcp,debug,packet     ciaddr = 0.0.0.0
2026-04-01 11:45:08 dhcp,debug,packet     yiaddr = 10.25.0.250
2026-04-01 11:45:08 dhcp,debug,packet     siaddr = 10.25.0.2
2026-04-01 11:45:08 dhcp,debug,packet     chaddr = 88:A2:9E:49:AB:36
2026-04-01 11:45:08 dhcp,debug,packet     Subnet-Mask = 255.255.255.0
2026-04-01 11:45:08 dhcp,debug,packet     Router = 10.25.0.1
2026-04-01 11:45:08 dhcp,debug,packet     Address-Time = 600
2026-04-01 11:45:08 dhcp,debug,packet     Msg-Type = offer
2026-04-01 11:45:08 dhcp,debug,packet     Server-Id = 10.25.0.1
2026-04-01 11:45:08 dhcp,debug,packet     Unknown(66) = 0A-19-00-02

The Raspberry Pi displays the SI_ADDR, but with the RouterOS, it doesn’t proceed with TFTP download.