From owner-freebsd-hackers Fri Aug 9 12:15:25 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AAF8937B400; Fri, 9 Aug 2002 12:15:19 -0700 (PDT) Received: from mail.wrs.com (unknown-1-11.windriver.com [147.11.1.11]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2327543E4A; Fri, 9 Aug 2002 12:15:19 -0700 (PDT) (envelope-from Qing.Li@windriver.com) Received: from heavygear (qing3.isi.com [192.103.54.234]) by mail.wrs.com (8.9.3/8.9.1) with SMTP id MAA16843; Fri, 9 Aug 2002 12:15:08 -0700 (PDT) From: "Qing Li" To: "FreeBSD Net" , "FreeBSD Hackers" Subject: problems with "route add -host" Date: Fri, 9 Aug 2002 12:14:21 -0700 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2911.0) Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG My interface xl0 is assigned 147.11.38.218. ========== Routing tables Internet: Destination Gateway Flags Refs Use Netif Expire default 147.11.38.1 UGSc 4 0 xl0 127.0.0.1 127.0.0.1 UH 1 22 lo0 147.11.38/24 link#5 UC 2 0 xl0 147.11.38.1 00:00:0c:07:ac:26 UHLW 5 0 xl0 783 147.11.38.15 147.11.38.218 UGHS 0 3 xl0 147.11.38.218 127.0.0.1 UGHS 1 0 lo0 147.11.38.254 00:02:7e:23:fa:80 UHLW 0 0 xl0 49 ========== Now I add a host route: "route add -host 147.11.38.15 147.11.38.218" Then ping> "ping 147.11.38.15" fails. This is due to the "G" flag in that static route entry. This route addition should be allowed as a place holder to be filled in later, similar to of an entry with RTF_LLINFO flag. I put in the fixes, here is what the routing table shows after the fix using the same route command, =========== 147.11.38.15 link#5 UHLS 0 3 xl0 =========== "ping 147.11.38.15" now succeeds, that route entry is modified to be =========== 147.11.38.15 8:0:20:d1:64:c6 UHLS 0 3 xl0 =========== This problem exists for IPv6, too. But the fix there is slightly different than the v4 fix. Unlike "ping", "ping6" returns -1 with an error message of "No route to host". I am ready to submit a couple of bug reports with my fixes. I'd like to know if anyone had any comments. My version is: FreeBSD 4.6 compiled on June 17, 2002. -- Qing To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message