From owner-freebsd-i386@freebsd.org Sun Apr 10 12:01:00 2016 Return-Path: Delivered-To: freebsd-i386@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 23C43B015D5 for ; Sun, 10 Apr 2016 12:01:00 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id F3D8B1001 for ; Sun, 10 Apr 2016 12:00:59 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id u3AC0xcI098423 for ; Sun, 10 Apr 2016 12:00:59 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-i386@FreeBSD.org Subject: [Bug 208669] Improvement of pxeboot using Linux NFS servers. Date: Sun, 10 Apr 2016 12:00:59 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: arm X-Bugzilla-Version: 10.2-STABLE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: zen-freebsd-users@suzuki.que.ne.jp X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-arm@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter cc Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-i386@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: I386-specific issues for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Apr 2016 12:01:00 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D208669 Bug ID: 208669 Summary: Improvement of pxeboot using Linux NFS servers. Product: Base System Version: 10.2-STABLE Hardware: i386 OS: Any Status: New Severity: Affects Only Me Priority: --- Component: arm Assignee: freebsd-arm@FreeBSD.org Reporter: zen-freebsd-users@suzuki.que.ne.jp CC: freebsd-i386@FreeBSD.org CC: freebsd-i386@FreeBSD.org I tried to boot by pxeboot using some Linux nfs servers. But, I could not boot by using Linux nfs servers.=20 I tested using CentOS6.7 and CentOS7.1 as a dhcp,tftp,NFS server. The pxeboot of FreeBSD9.3 and 10.2 correctly downloaded by TFTP from Linux server. At second stage , the pxeboot will mount to load kernel by nfs. But, pxeboot was failed to mount nfs. I monitored a packet using tcpdump. It was as below. 14:12:47.658036 IP 192.168.8.215.1023 > 192.168.8.2.sunrpc: UDP,length 76 14:12:47.658349 IP 192.168.8.2.sunrpc > 192.168.8.215.1023: UDP,length 28 ... reapeat infinity .... I checked a source file of pxeboot at FreeBSD 9.3, then I was succeed to b= oot using Linux NFS Server. My improvement is as below. *** /sys/boot/i386/libi386/pxe.c.orig 2014-12-14 13:47:38.000000000 +0900 --- /sys/boot/i386/libi386/pxe.c 2016-04-10 20:24:13.000000000 +0900 *************** *** 673,679 **** uh =3D (struct udphdr *) pkt - 1; bzero(udpread_p, sizeof(*udpread_p)); ! udpread_p->dest_ip =3D h->myip.s_addr; udpread_p->d_port =3D h->myport; udpread_p->buffer_size =3D len; udpread_p->buffer.segment =3D VTOPSEG(data_buffer); --- 673,679 ---- uh =3D (struct udphdr *) pkt - 1; bzero(udpread_p, sizeof(*udpread_p)); ! udpread_p->src_ip =3D h->destip.s_addr; udpread_p->d_port =3D h->myport; udpread_p->buffer_size =3D len; udpread_p->buffer.segment =3D VTOPSEG(data_buffer); The Intel's document of pxe says=20 DestIP: Only accept packets sent to this IP address. If this is zero, packets sent to any IP address are accepted http://www.intel.com/design/archives/wfm/downloads/pxespec.htm I remove line of udpread_p->dest_ip... , And added the line udpread_p->src_ip... for security. I wonder why NFS Server of FreeBSD is success at the code of current. Unfortunately a reason isn't understood. --- my test enviroment Boot server CentOS6.7 and CentOS7.1. Diskless client FreeBSD-9.3 Hardware1: virtual machin of VMware ESXi 6.0 Hardware2: M/B SuperMicro X8SIL-F (IntelPXE) --=20 You are receiving this mail because: You are on the CC list for the bug.=