From owner-freebsd-net@FreeBSD.ORG Sat Oct 20 13:20:38 2007 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0AC2B16A418 for ; Sat, 20 Oct 2007 13:20:38 +0000 (UTC) (envelope-from ndenev@gmail.com) Received: from rv-out-0910.google.com (rv-out-0910.google.com [209.85.198.191]) by mx1.freebsd.org (Postfix) with ESMTP id 4B73213C461 for ; Sat, 20 Oct 2007 13:20:35 +0000 (UTC) (envelope-from ndenev@gmail.com) Received: by rv-out-0910.google.com with SMTP id l15so625692rvb for ; Sat, 20 Oct 2007 06:20:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; bh=6k/3RNwrbLrdbGBpoLler4O/HUGGQOjrN6hyXPfTrCE=; b=fKqkHoupxUosdpLI78O0+fY0gkJ0/rj1/Rk1Udhxbe/YBkGDUaSB4mL4gEE9+FIRsafZtrwewjxALQ5wNWmI32yC24z/OJArhQLI8nUJrdjySXvLWwZU1uT3Wb1ih2P3CZ1+XBVWf6aLdtUsxMdI16qwm7hcLoRT3AwDtUrRNlc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; b=JcnkZx394F5bECLAK9YOZExlwBNUZ3GvIq5glH1xs+aZwGAInE5B6Yj1KZXsjvV8hu43ypbTBhdN4v3mpSO+6BYrXBlaDX6MfytiCNG7NfcK8tdUobIz96ga6xcx9DSmPanHyMERMz6QmpZrBw4o7nUCdA2t31DrFErJRYsyCYo= Received: by 10.141.162.16 with SMTP id p16mr1538231rvo.1192886434392; Sat, 20 Oct 2007 06:20:34 -0700 (PDT) Received: by 10.140.192.2 with HTTP; Sat, 20 Oct 2007 06:20:34 -0700 (PDT) Message-ID: <2e77fc10710200620q4d6d33d5ta389d1ea32bf8417@mail.gmail.com> Date: Sat, 20 Oct 2007 16:20:34 +0300 From: "Niki Denev" Sender: ndenev@gmail.com To: Netan In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <4718EDF1.7080200@seclark.us> X-Google-Sender-Auth: fcc50a0f061981e1 Cc: freebsd-net@freebsd.org Subject: Re: Dump kernel routing table X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Oct 2007 13:20:38 -0000 On 10/20/07, Netan wrote: > On 10/19/07, Stephen Clark wrote: > > > > Netan wrote: > > > > >Hello > > > > > >I am using the CURRENT release. I wish to dump the kernel routing table. > > I > > >think there was a sysctl interface in 4.x FreeBSD release to print it > > from > > >userspace. Is there a way to do it now ?.. > > > > > >Sunny > > > > > > > > netstat -rn > > > > All these all the rtentry's in the radix trie ? Or they distilled during > netstat -rn output ? > > Sunny > > -- > > > > "They that give up essential liberty to obtain temporary safety, > > deserve neither liberty nor safety." (Ben Franklin) > > > > "The course of history shows that as a government grows, liberty > > decreases." (Thomas Jefferson) > > > > > > > > Maybe you need "-A" switch? netstat -r [-AanW] [-f address_family] [-M core] [-N system] Display the contents of all routing tables, or a routing table for a particular address_family. If -A is also present, show the contents of the internal Patricia tree structures; used for debugging. If -a is also present, show protocol-cloned routes (routes generated by an RTF_PRCLONING parent route); normally these routes are not shown. When -W is also present, show the path MTU for each route, and print interface names with a wider field size. hth, niki