git: ba54c352da - main - Handbook - Advanced networking - Improve Diskless Operation with PXE

From: Cheng Cui <cc_at_FreeBSD.org>
Date: Mon, 04 Dec 2023 22:26:52 UTC
The branch main has been updated by cc:

URL: https://cgit.FreeBSD.org/doc/commit/?id=ba54c352dabab58cc28f8b085caa472ec05cc27a

commit ba54c352dabab58cc28f8b085caa472ec05cc27a
Author:     Cheng Cui <cc@FreeBSD.org>
AuthorDate: 2023-11-24 17:03:51 +0000
Commit:     Cheng Cui <cc@FreeBSD.org>
CommitDate: 2023-12-04 17:26:38 +0000

    Handbook - Advanced networking - Improve Diskless Operation with PXE
    
    Summary: PR:            274976
    Reviewed by: carlavilla
    Test Plan: see PR 274976
    
    Differential Revision: https://reviews.freebsd.org/D42766
---
 .../en/books/handbook/advanced-networking/_index.adoc   | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/documentation/content/en/books/handbook/advanced-networking/_index.adoc b/documentation/content/en/books/handbook/advanced-networking/_index.adoc
index b9194449cd..1a6e239cf7 100644
--- a/documentation/content/en/books/handbook/advanced-networking/_index.adoc
+++ b/documentation/content/en/books/handbook/advanced-networking/_index.adoc
@@ -1961,6 +1961,12 @@ After the host computer receives this information, it downloads the boot loader
 In FreeBSD, the boot loader file is [.filename]#/boot/pxeboot#.
 After [.filename]#/boot/pxeboot# executes, the FreeBSD kernel is loaded and the rest of the FreeBSD bootup sequence proceeds, as described in crossref:boot[boot,The FreeBSD Booting Process].
 
+[NOTE]
+====
+For UEFI PXE based boot, the actual boot loader file to use is [.filename]#/boot/loader.efi#.
+See the below section crossref:advanced-networking[_debugging_pxe_problems,Debugging PXE Problems] on how to use [.filename]#/boot/loader.efi#.
+====
+
 This section describes how to configure these services on a FreeBSD system so that other systems can PXE boot into FreeBSD.
 Refer to man:diskless[8] for more information.
 
@@ -2025,11 +2031,12 @@ inetd_enable="YES"
 +
 [.programlisting]
 ....
-tftp dgram udp wait root /usr/libexec/tftpd tftpd -l -s /b/tftpboot
+tftp dgram udp wait root /usr/libexec/tftpd tftpd blocksize 1468 -l -s /b/tftpboot
 ....
 +
 [NOTE]
 ====
+The specified tftp blocksize, e.g. 1468 bytes, replaces the default size 512 bytes.
 Some PXE versions require the TCP version of TFTP.
 In this case, uncomment the second `tftp` line which contains `stream tcp`.
 ====
@@ -2180,6 +2187,14 @@ The `BUGS` sections in man:tftpd[8] and man:tftp[1] document some limitations wi
 ....
 # mount -t nfs 192.168.0.1:/b/tftpboot/FreeBSD/install /mnt
 ....
++
+. For UEFI PXE based booting, replace the [.filename]#boot/pxeboot# file with the [.filename]#boot/loader.efi# file:
+[source,shell]
+....
+# chroot ${NFSROOTDIR}
+# mv boot/pxeboot boot/pxeboot.original
+# cp boot/loader.efi boot/pxeboot
+....
 ****
 
 [[carp]]