From owner-freebsd-net@FreeBSD.ORG Mon Sep 15 01:24:45 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 7F23616A4BF for ; Mon, 15 Sep 2003 01:24:45 -0700 (PDT) Received: from xorpc.icir.org (xorpc.icir.org [192.150.187.68]) by mx1.FreeBSD.org (Postfix) with ESMTP id C37D043F85 for ; Mon, 15 Sep 2003 01:24:44 -0700 (PDT) (envelope-from rizzo@xorpc.icir.org) Received: from xorpc.icir.org (localhost [127.0.0.1]) by xorpc.icir.org (8.12.8p1/8.12.3) with ESMTP id h8F8OikN057870; Mon, 15 Sep 2003 01:24:44 -0700 (PDT) (envelope-from rizzo@xorpc.icir.org) Received: (from rizzo@localhost) by xorpc.icir.org (8.12.8p1/8.12.3/Submit) id h8F8OhSf057856; Mon, 15 Sep 2003 01:24:43 -0700 (PDT) (envelope-from rizzo) Date: Mon, 15 Sep 2003 01:24:43 -0700 From: Luigi Rizzo To: Eugene Grosbein Message-ID: <20030915012443.A49336@xorpc.icir.org> References: <3F6546C1.41B7143@kuzbass.ru> <20030914221343.A25641@xorpc.icir.org> <3F654BBB.9240465B@kuzbass.ru> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <3F654BBB.9240465B@kuzbass.ru>; from eugen@kuzbass.ru on Mon, Sep 15, 2003 at 01:18:51PM +0800 cc: net@freebsd.org Subject: Re: ipfw: pullup failed 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: Mon, 15 Sep 2003 08:24:45 -0000 On Mon, Sep 15, 2003 at 01:18:51PM +0800, Eugene Grosbein wrote: > Luigi Rizzo wrote: > > > > My router that uses ipfw2 for WF2Q+ sometimes writes in log: > > > > > > Sep 15 00:00:00 gw2 newsyslog[51667]: logfile turned over > > > Sep 15 06:20:27 gw2 /kernel: ipfw: pullup failed > > > Sep 15 07:00:42 gw2 /kernel: ipfw: pullup failed > > > Sep 15 07:58:55 gw2 /kernel: ipfw: pullup failed > > > Sep 15 08:23:13 gw2 /kernel: ipfw: pullup failed > > > Sep 15 10:14:38 gw2 /kernel: ipfw: pullup failed > > > Sep 15 11:50:53 gw2 /kernel: ipfw: pullup failed > > > > a possibility is that it has run out of mbufs. what does netstat -m say ? > > 669/1920/65536 mbufs in use (current/peak/max): > 654 mbufs allocated to data > 15 mbufs allocated to packet headers > 472/712/16384 mbuf clusters in use (current/peak/max) ok, another one is that the packet was too short for the desired length (supposedly, as a result of a collision). You could perhaps try the following patch and see if it tells you something more interesting. cheers luigi static int ipfw_chk(struct ip_fw_args *args) { + int desired_len = -1; /* * Local variables hold state during the processing of a packet. * * IMPORTANT NOTE: to speed up the processing of rules, there ... #define PULLUP_TO(len) \ do { \ if ((m)->m_len < (len)) { \ args->m = m = m_pullup(m, (len)); \ - if (m == 0) \ + if (m == 0) { \ + desired_len = (len); \ goto pullup_failed; \ + } \ ip = mtod(m, struct ip *); \ } \ } while (0) ... pullup_failed: if (fw_verbose) - printf("pullup failed\n"); + printf("pullup failed have %d want %d\n", m->m_len,desired_len); return(IP_FW_PORT_DENY_FLAG); } > 1904 Kbytes allocated to network (3% of mb_map in use) > 0 requests for memory denied > 0 requests for memory delayed > 0 calls to protocol drain routines