From owner-freebsd-net@FreeBSD.ORG Tue Aug 26 20:03:19 2003 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9270116A4BF for ; Tue, 26 Aug 2003 20:03:19 -0700 (PDT) Received: from pixies.tirloni.org (pixies.tirloni.org [200.203.183.37]) by mx1.FreeBSD.org (Postfix) with ESMTP id 007E643FD7 for ; Tue, 26 Aug 2003 20:03:19 -0700 (PDT) (envelope-from tirloni@tirloni.org) Received: by pixies.tirloni.org (Postfix, from userid 1000) id 907871E14FD; Wed, 27 Aug 2003 00:03:16 -0300 (BRT) Date: Wed, 27 Aug 2003 00:03:15 -0300 From: "Giovanni P. Tirloni" To: freebsd-net@freebsd.org Message-ID: <20030827030314.GJ40033@pixies.tirloni.org> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline X-Info: http://www.tirloni.org User-Agent: Mutt/1.5.3i Subject: mbuf usage for an idle machine X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Aug 2003 03:03:19 -0000 Hi, I've been reading about mbufs and how they're used for holding network packets and socket buffers and the output of 'netstat -m' for a idle machine I've here made me curious about how FreeBSD handles it in -CURRENT. Why is it using so many mbufs when it's idle? My small kwnowledge doesn't permit me to answer this question yet ;) root@gate:~# netstat -m mbuf usage: GEN cache: 0/0 (in use/in pool) CPU #0 cache: 130/288 (in use/in pool) Total: 130/288 (in use/in pool) Mbuf cache high watermark: 512 Maximum possible: 9856 Allocated mbuf types: 130 mbufs allocated to data 2% of mbuf map consumed mbuf cluster usage: GEN cache: 0/8 (in use/in pool) CPU #0 cache: 128/256 (in use/in pool) Total: 128/264 (in use/in pool) Cluster cache high watermark: 128 Maximum possible: 4928 5% of cluster map consumed 600 KBytes of wired memory reserved (48% in use) 0 requests for memory denied 0 requests for memory delayed 0 calls to protocol drain routines root@gate:~# sockstat -4c USER COMMAND PID FD PROTO LOCAL ADDRESS FOREIGN ADDRESS bs2 sshd 2085 4 tcp4 192.168.200.1:22 200.200.200.200:1405 root sshd 2082 4 tcp4 192.168.200.1:22 200.200.200.200:1405 root@gate:~# sockstat -4l USER COMMAND PID FD PROTO LOCAL ADDRESS FOREIGN ADDRESS root mpd 635 14 tcp4 192.168.200.1:1723 *:* nobody squid 614 4 udp4 *:49184 *:* nobody squid 614 20 tcp4 127.0.0.1:3128 *:* root dhcpd 469 6 udp4 *:67 *:* root sendmail 432 3 tcp4 127.0.0.1:25 *:* root sshd 426 3 tcp4 *:22 *:* root ntpd 407 4 udp4 *:123 *:* root ntpd 407 5 udp4 192.168.0.254:123 *:* root ntpd 407 6 udp4 192.168.200.1:123 *:* root ntpd 407 7 udp4 127.0.0.1:123 *:* bind named 292 4 udp4 *:49152 *:* bind named 292 20 udp4 192.168.0.254:53 *:* bind named 292 21 tcp4 192.168.0.254:53 *:* bind named 292 22 udp4 127.0.0.1:53 *:* bind named 292 23 tcp4 127.0.0.1:53 *:* FreeBSD gate 5.1-CURRENT FreeBSD 5.1-CURRENT #4: Wed Jul 23 \ 11:22:55 BRT 2003 root@gate:/usr/src/sys/i386/compile/ \ GATE i386 It has 2 ethernet interfaces (192.168.200.1 and 192.168.0.254) I'll be happy to provide any additional information if it's needed. -- Giovanni P. Tirloni http://www.tirloni.org