LE10 network boot (PXE) with Pi4/B 4GB doesn't work

  • I have a running setup booting the RasPi 4 Model B 4GB with Debian from my DHCP/TFTP/NFS environment.
    Trying to do the same thing with LE10 doesn't work. There are repeating tftp-requests for files like
    start4.elf, start.elf, config.txt, vl805.sig, pieeprom.sig, recover4.elf and more,

    files which are part of the Debian boot partition but not in LE10.

    As cmdline.txt is not requested there is no NFS access from the Pi.

    Is there a special bootcode.bin for Pi4, LE10 and PXE available or where is my problem located?

    Thanks, Devlin

  • Go to Best Answer
  • It's possible that PXE boot is not yet part of the RPi4B firmware.

    You could double-check at the Raspberry Pi forums/devs to hear what the status on network booting is.

    It's possible since ~2yrs and I have a running Debian installation for the same box booting from network. So PXE boot with Pi4 works.
    But all available examples tell me just to move bootcode.bin to tftp and probably cmdline.txt which contains the referral to the NFS server. All additional files should then be loaded via NFS.
    It seems as if bootcode.bin requests different files when booting from network.

  • RPi4 doesn't need bootcode.bin or a SD card, everything's in the boot eeprom - just make sure it's up-to-date and network boot is enabled in BOOT_ORDER.

    Copying the contents of the FAT partition on the SD card to a directory served via TFTP and NFS and creating a NFS share for the storage partition is enough - the bootloader in eeprom will fall back to start.elf if start4.elf can't be found.

    so long,

    Hias

  • RPi4 doesn't need bootcode.bin or a SD card, everything's in the boot eeprom - just make sure it's up-to-date and network boot is enabled in BOOT_ORDER.

    Copying the contents of the FAT partition on the SD card to a directory served via TFTP and NFS and creating a NFS share for the storage partition is enough - the bootloader in eeprom will fall back to start.elf if start4.elf can't be found.

    so long,

    Hias

    That's exactly what I tried to describe. Pi4 boots from eeprom, connects to the tftpserver and requests a bunch of files like start4.elf, start.elf, config.txt, vl805.sig, pieeprom.sig, recover4.elf and more. start.elf and config.txt exist in LE10, but not the others.

    And cmdline.txt is never requested, so no try to access anything via NFS.
    I still have no clue where my error is located. DHCP and tft work, Debian is able to boot in that environment but not LE10.

    Any idea?

  • How did you populate the TFTP directory?

    In general copying all files from the FAT partition of the SD card should just work (after adjusting cmdline.txt). If you populated it from the contents of the tarball you'll need to rename KERNEL to kernel.img.

    Netbooting LE10 on RPi4s is working fine here, I've been doing that for a while now for easy development testing.

    I chose to organize TFTP and NFS directories using the RPi4 serial number at the top level, RPi4 firmware looks there first when TFTP-booting (and then falls back to TFTP root dir). This makes it easy to serve different (LE) versions to different RPis and the LE init script also supports that quite well, it substitutes "@UID@" in boot/disk with the serial - so I can use an identical cmdline.txt for all installations. The relevant part of cmdline.txt looks like this here:

    Code
    ip=dhcp boot=NFS=192.168.1.20:/wd/srv/tftp/@UID@ disk=NFS=192.168.1.20:/wd/srv/le-storage/@UID@

    TFTP root directory (I'm using atftpd here) is /wd/srv/tftp and /wd/srv is exported via NFS, and my DHCP server announces the TFTP server via option 66 (tftp in dnsmasq) in DHCP replies.

    Check your tftp logs, also for missing files. For reference here's the tftp log output from a boot here:

    so long,

    Hias

  • Hi Hias,

    I have pretty the same setup, but for ease of debug I have a flat structure.

    cmdline.txt looks like this

    Code
    boot=NFS=192.168.1.231:/export/le-system/5c5e0a58 disk=NFS=192.168.1.231:/export/le-storage/5c5e0a58 ssh ip=dhcp rootwait elevator=deadline debugging

    tftp-dir has the same content as /export/le-system, both are simply a copy of /flash of the running LE10 booting from sdcard. With modifed cmdline.txt of course.

    But my tftp-log looks different. I'm running bootloader 1b43d5b6 from March, 18th 2021, update-ts 1612279788, bootmode network mode 2 order 21, fw start4.elf fixup4.elf and my tftp-log looks different to yours:

    At this point it restarts the next boot loop.

    Thanks for your help, Dev

  • Hmm, I use the same bootloader version but with a flat layout (firmware etc in TFTP root) it looks very different. I see one request to SERIAL/start4.elf and another one to SERIAL/start.elf, then bootloader falls back to root:

    Your log however shows SERIAL/start4.elf requests repeating in 2 second intervals - and tftpd serving it (?)

    Might be worth digging into the tftp config/setup, something seems to be odd there (maybe permissions or timeouts).

    For reference here's my bootloader config (basically default settings, except for boot uart and order)

    so long,

    Hias

  • This was my original eeprom-config:

    I've changed it to exactly your config but no differenc when booting from net. It still directly accesses the UID-subdir within tftp.

    And there is no obvious permission problem as the Pi can load start.elf and config.txt successfully. All other requested files simply don't exist.

    I still can't understand why your Pi requests a totally different set of files.

    Thanks, urle

  • Which tftp server are you using, is it by chance the netkit one ("tftpd" package in debian/raspbian)? If yes, don't use it, it doesn't work (just tested that here locally) and even the package description warns that it has issues:

    Code
    hias@camel2:~$ apt-cache show tftpd
    ...
     Warning: Does not support 'tsize', which is required by some tftp clients,
     especially PXE, and various other network boot clients. For those, use atftpd
     or tftpd-hpa.
    ...

    Both atftpd (which I usually use) and tftpd-hpa work fine here.

    so long,

    Hias

  • Which tftp server are you using, is it by chance the netkit one ("tftpd" package in debian/raspbian)? If yes, don't use it, it doesn't work (just tested that here locally) and even the package description warns that it has issues:

    Code
    hias@camel2:~$ apt-cache show tftpd
    ...
     Warning: Does not support 'tsize', which is required by some tftp clients,
     especially PXE, and various other network boot clients. For those, use atftpd
     or tftpd-hpa.
    ...

    Both atftpd (which I usually use) and tftpd-hpa work fine here.

    so long,

    Hias

    Hello Hias,

    switching over to atftpd worked finally.

    Thanks so much for your patience!

    Best, Dev