<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman",serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
{mso-style-name:msonormal;
mso-margin-top-alt:auto;
margin-right:0cm;
mso-margin-bottom-alt:auto;
margin-left:0cm;
font-size:12.0pt;
font-family:"Times New Roman",serif;}
span.EmailStyle18
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:black;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri",sans-serif;
mso-fareast-language:EN-US;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=ET link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Hi!<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Just went through setting up UEFI boot over PXE and TFTP. Of great help in figuring out what was going on was to add logging to the TFTP server:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Kill the tftp server started at boot and manually start one with<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'># /usr/sbin/in.tftpd –vvv --listen --user tftp --address 0.0.0.0:69 --secure /srv/fai<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>or similar (check the startup script of in.tftpd, add –v’s generously).<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Then you will see in the syslog, which files are being requested and whether they are actually being transmitted.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>A successful UEFI boot with grub generates about 15 TFTP requests, starting with:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Jun 30 18:22:40 server in.tftpd[11435]: RRQ from 172.24.0.68 filename fai/efi/x86_64-efi/core.efi<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Jun 30 18:22:40 server in.tftpd[11436]: RRQ from 172.24.0.68 filename /fai/efi/x86_64-efi/normal.mod<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Jun 30 18:22:40 server in.tftpd[11437]: RRQ from 172.24.0.68 filename /fai/efi/x86_64-efi/extcmd.mod<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>[…]<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>A missing or misplaced file will show up as <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Jun 30 18:22:40 server in.tftpd[11449]: RRQ from 172.24.0.68 filename /fai/efi/grub.cfg<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Jun 30 18:22:40 server in.tftpd[11449]: sending NAK (1, File not found) to 172.24.0.68<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Hoping this helps,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'>Toomas<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif;color:black;mso-fareast-language:EN-US'><o:p> </o:p></span></p><div style='border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt'><div><div style='border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif'>From:</span></b><span lang=EN-GB style='font-size:11.0pt;font-family:"Calibri",sans-serif'> linux-fai <linux-fai-bounces@uni-koeln.de> <b>On Behalf Of </b>Rémy Dernat<br><b>Sent:</b> Friday, July 6, 2018 3:28 PM<br><b>To:</b> linux-fai@uni-koeln.de<br><b>Subject:</b> UEFI + Legacy BIOS TFTP/PXELINUX<o:p></o:p></span></p></div></div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p><div><p class=MsoNormal><span lang=EN-GB>Hi,<o:p></o:p></span></p><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>I am trying to set up an UEFI boot pxe mainly because our hardware servers do not support full legacy BIOS anymore (particularly hard disk plugin on those servers).<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>Our legacy pxelinux works just fine from a while now (and thanks for it).<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>I followed this link : <a href="https://lists.uni-koeln.de/pipermail/linux-fai/2014-February/010294.html">https://lists.uni-koeln.de/pipermail/linux-fai/2014-February/010294.html</a><o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>... with no luck. I created an "UEFI" specific class to avoid the erase of DEFAULT, and put everything in that new class, because we will need to keep the pxelinux config.<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>My tftp fai folder is organised like this:<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>```<o:p></o:p></span></p></div><div><div><p class=MsoNormal><span lang=EN-GB>root@faiserv:/srv# tree -L 2<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>.<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── fai<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── config<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ └── nfsroot<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── nfs4<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>└── tftp<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB> └── fai<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div></div><div><div><p class=MsoNormal><span lang=EN-GB>root@faiserv:/srv/tftp/fai# tree -L 2<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>.<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── c2960s-universalk9-tar.150-2a.SE9.tar<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── cisco-ios-150-2a.tar -> c2960s-universalk9-tar.150-2a.SE9.tar<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── efi<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── fonts<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── grub.cfg<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── grub.cfg.nok<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── i386-pc<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── locale<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── pxelinux.cfg -> ../pxelinux.cfg<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── unicode.pf2<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ └── x86_64-efi<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── gpxelinux.0<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── initrd.img-3.16.0-4-amd64<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── initrd.img-3.16.0-6-amd64<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── ldlinux.c32<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── lpxelinux.0<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── pxelinux.0<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── pxelinux.0.back<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── pxelinux.cfg<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── 0A01FD03<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── 0A01FFF2<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5A1.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5A2.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5A3.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5A4.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5A5.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5A6.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5A7.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5A9<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5AA.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5AB.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5B0.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5B4.disable<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ ├── A226B5B8<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>│ └── default<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── syslinux.efi<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>├── vmlinuz-3.16.0-4-amd64<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>└── vmlinuz-3.16.0-6-amd64<o:p></o:p></span></p></div></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>```<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>I do not know if the UEFI is also searching for a filename matching its IP address with the hexa value, so I created a symbolic link to the pxelinux.cfg parent directory...<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>I have no problem with DHCP, and my client is loading the grub.cfg menu. However, it fails while searching for the nfsroot. The error I get (with debug=all) is (replacing sensitive informations): <o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>```<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>kern/disk.c:196 : Opening `tftp,IP.IP.IP.IP'...<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>disk/efi/efidisk.c:461 : opening tftp<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>kern/disk.c: 281: Opening `tftp,IP.IP.IP.IP' failed.<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>kern/disk.c: 295: Closing `tftp'.<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>```<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>Here is my grub.cfg config :<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>```<o:p></o:p></span></p></div><div><div><p class=MsoNormal><span lang=EN-GB>root@faiserv:/srv/tftp/fai/efi# cat grub.cfg<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>set menu_color_normal=white/black<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>set menu_color_highlight=black/light-gray<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>set timeout=5<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB># for debug:<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>#set pager=1<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>set debug=all<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>insmod efi_gop<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>insmod efi_uga<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>if loadfont ${prefix}/unicode.pf2<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>then<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB> insmod gfxterm<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB> set gfxmode=auto<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB> set gfxpayload=keep<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB> terminal_output gfxterm<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>fi<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>menuentry "Install from FAI" {<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB> linux vmlinuz-3.16.0-6-amd64 rw ip=dhcp root=/dev/nfs nfsroot=IP.IP.IP.IP:/srv/fai/nfsroot FAI_FLAGS=verbose,sshd,createvt,reboot FAI_ACTION=install server=faiserv.acme.ltd FAI_CONFIG_SRC=nfs://faiserv.acme.ltd/srv/fai/config<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB> initrd initrd.img-3.16.0-6-amd64<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>}<o:p></o:p></span></p></div></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>```<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>Any help would be greatly appreciated.<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>Thanks,<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-GB>Rémy<o:p></o:p></span></p></div></div></div></div></body></html>