From nobody Fri May 31 16:23:01 2024 X-Original-To: freebsd-virtualization@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VrT236xHQz5N8D7 for ; Fri, 31 May 2024 16:23:23 +0000 (UTC) (envelope-from freebsd@ny-central.org) Received: from mail2.ny-central.com (mail2.ny-central.com [173.212.246.2]) by mx1.freebsd.org (Postfix) with ESMTP id 4VrT20482Sz4336 for ; Fri, 31 May 2024 16:23:20 +0000 (UTC) (envelope-from freebsd@ny-central.org) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=ny-central.org header.s=202405 header.b=x0tEMvY9; dmarc=pass (policy=none) header.from=ny-central.org; spf=pass (mx1.freebsd.org: domain of freebsd@ny-central.org designates 173.212.246.2 as permitted sender) smtp.mailfrom=freebsd@ny-central.org X-Virus-Scanned: amavisd-new at ny-central.com DKIM-Filter: OpenDKIM Filter v2.10.3 mail2.ny-central.com 633381AF16D DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=ny-central.org; s=202405; t=1717172588; bh=laF6IIv0ErfBSK9GZ87cetKFfzlBLqriQZuVqRhwFu4=; h=Date:From:To:Subject; z=Date:=20Fri,=2031=20May=202024=2018:23:01=20+0200=20(CEST)|From:= 20Chris=20Moerz=20|To:=20FreeBSD=20Virtual ization=20Mailing=20List=20|Su bject:=20PXE=20boot=20with=20bhyve; b=x0tEMvY9mlr8jBP1/7822aIjSWSJgCuBxjHErj+vc/4ANv59Ce9f/M+qn2fsPXGoT gm68Yg1AiGkaiKlZKDuQL1zZwVbmO6I9rm5tjMAF8U5ugzY+tHk1Nw2iA1yjeG+0sJ W+mWGxBuv/jBNnk/by0eTvJei4fdJKB2ZcmNTJMstJGsyZ/Yi4Q0kYRxuBneou58lz j4LfRmuAg5MYNfRwRGpgdl7+KTeqnujAQE+M5+fV5tv8WSjD3Z3kusatjKqruwU1Ra SK8CnqYbd570A3agiczjCGTkIBCzixRkiTp1rMwHq4DwFndW1Ryfqcej7uQXNtiVHd kR1SL0OrEyEmqvdcBXxt8bR42CvX02I2OZFzdVRO/d4fKEKio8u3Q7fprV5KULUkXe aqE5pfxCvbKy6G6DddE45pw/1u6U9EiiRjVcJRhMZFlmYFgvYBg0GfUguL3O2TBLBk 7oM2iUMRBlzqQ/4HDlf5cj4sp0ak5rbHf80lBxMmYcli/MJMmUQG1VVnpnIOkVUZ6d +q95V/FpR0vA0iJCLzm7n8GOfC2mogJFK5XPyvQjLW2ApnlNOiYI23Ora3FmX9O/Qo 4PbvzHY1gXyUYLVpaYQHmh8ObB/J6M3KzXdHaYDS7GacGkK29B2+TF/9pWC1SGaToo 3auqMkZNwmMK+kA7exBun1HI= Received: from tenforward.ny-central.local (unknown [192.168.11.104]) by mail2.ny-central.com (Postfix) with ESMTPSA id 633381AF16D for ; Fri, 31 May 2024 18:22:57 +0200 (CEST) Date: Fri, 31 May 2024 18:23:01 +0200 (CEST) From: Chris Moerz To: FreeBSD Virtualization Mailing List Subject: PXE boot with bhyve Message-ID: List-Id: Discussion List-Archive: https://lists.freebsd.org/archives/freebsd-virtualization List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: freebsd-virtualization@freebsd.org Sender: owner-freebsd-virtualization@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on mail2.ny-central.com X-Spamd-Bar: --- X-Spamd-Result: default: False [-3.90 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-0.999]; DMARC_POLICY_ALLOW(-0.50)[ny-central.org,none]; R_DKIM_ALLOW(-0.20)[ny-central.org:s=202405]; R_SPF_ALLOW(-0.20)[+a]; MIME_GOOD(-0.10)[text/plain]; RCVD_NO_TLS_LAST(0.10)[]; MIME_TRACE(0.00)[0:+]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FROM_HAS_DN(0.00)[]; RCVD_COUNT_ONE(0.00)[1]; ARC_NA(0.00)[]; ASN(0.00)[asn:51167, ipnet:173.212.240.0/21, country:DE]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-virtualization@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; TO_DN_ALL(0.00)[]; MISSING_XM_UA(0.00)[]; MLMMJ_DEST(0.00)[freebsd-virtualization@freebsd.org]; DKIM_TRACE(0.00)[ny-central.org:+] X-Rspamd-Queue-Id: 4VrT20482Sz4336 Hi everyone, I've attempted to boot a diskless guest via PXE. Unfortunately, it's not working for me. Here's what I have done and tested successfully. All involved systems are FreeBSD 14.0-RELEASE: - NFSv3 setup on guest 1 "NFS server" exports /nfs and all subdirectories with -maproot=0 base.txz, kernel.txz both extracted into /nfs/vmname duplicated the guest's /boot dir onto /nfs/vmname/boot for testing - TFTP set up via inetd on guest 1 "NFS server" /tftpboot contains copy of /boot/pxeboot alternatively, I also recompiled pxeboot without ZFS support - DHCP set up on host, listening on the bridge that all guests are on announces the relevant BOOTP options option root-path "xxx.xxx.xxx.xxx:/nfspath/vmname" filename "pxeboot" - Booted a test guest 2 "NFS client" confirmed NFS mount is working, files can be written onto NFS mount confirmed TFTP download is working - Booted a diskless guest 3 "Diskless client" PXE starts, gets DHCP announcement, downloads "pxeboot" and then fails Here's what I see on guest 3 serial console: >>Start PXE over IPv4. Station IP address is 10.193.167.3 Server IP address is 10.193.167.2 NBP filename is pxeboot NBP filesize is 415744 Bytes Downloading NBP file... NBP file downloaded successfully. BdsDxe: failed to load Boot0001 "UEFI PXEv4 (MAC:000000FFFF03)" from PciRoot(0x0)/Pci(0x4,0x0)/MAC(000000FFFF03,0x1)/IPv4(0.0.0.0,0x0,DHCP,0.0.0.0,0.0.0.0,0.0.0.0): Not Found >>Start PXE over IPv6 - Ran a tcpdump on the bridge and investigated the dump with wireshark I can see that the DHCP packet looks good and contains all relevant options, including the root path to the NFS server. Now, I've established that everything works up to the point when pxeboot should take over and load the kernel. However, there's never any NFS access. How do I troubleshoot this? I've got the feeling that the pxeboot is not really getting launched? The fact that I'm getting IPv4(0.0.0.0... looks like I'm also not getting the relevant network settings into the execution process? Any suggestion is very much appreciated. Let me know if you have any questions that may help shed more light into this. Thanks chris