From nobody@FreeBSD.org  Fri Oct  8 07:28:14 2004
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id C9AEE16A4CE
	for <freebsd-gnats-submit@FreeBSD.org>; Fri,  8 Oct 2004 07:28:14 +0000 (GMT)
Received: from www.freebsd.org (www.freebsd.org [216.136.204.117])
	by mx1.FreeBSD.org (Postfix) with ESMTP id BDF9243D41
	for <freebsd-gnats-submit@FreeBSD.org>; Fri,  8 Oct 2004 07:28:14 +0000 (GMT)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.12.11/8.12.11) with ESMTP id i987SEQW042261
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 8 Oct 2004 07:28:14 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.12.11/8.12.11/Submit) id i987SEMq042260;
	Fri, 8 Oct 2004 07:28:14 GMT
	(envelope-from nobody)
Message-Id: <200410080728.i987SEMq042260@www.freebsd.org>
Date: Fri, 8 Oct 2004 07:28:14 GMT
From: Katsushi Kobayashi <ikob@FreeBSD.org>
To: freebsd-gnats-submit@FreeBSD.org
Subject: Not increment ifp->if_snd.ifq_drops when discarding queue check in ip_output.c
X-Send-Pr-Version: www-2.3

>Number:         72440
>Category:       kern
>Synopsis:       [netinet] [patch] Not increment ifp->if_snd.ifq_drops when discarding queue check in ip_output.c
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    glebius
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Oct 08 07:30:20 GMT 2004
>Closed-Date:    Wed Dec 28 13:40:23 GMT 2005
>Last-Modified:  Wed Dec 28 13:40:23 GMT 2005
>Originator:     Katsushi Kobayashi
>Release:        4.1.10
>Organization:
National Institute of Communications Technology
>Environment:
FreeBSD eeyore.koganei.wide.ad.jp 4.10-RELEASE FreeBSD 4.10-RELEASE #3: Thu Oct  7 20:17:39 JST 2004     ikob@eeyore.koganei.wide.ad.jp:/usr/home/ikob/sys/compile/PR  i386
>Description:
I was trying to make a FreeBSD box having 2 network i/f as a IP router. We made
a heavy congestion point in my lab. with one i/f as 100BaseTX and another one
as 10BaseT. We expected to increase send queue counter using "netstat -i -d ".
However, the drop count for congested interface did not increase ever.
>How-To-Repeat:
      netstat -i -d

>Fix:
I guess the following patch could be useful for this issue:

*** ip_output.c.orig    Fri Oct  8 16:22:02 2004
--- ip_output.c Fri Oct  8 16:23:49 2004
***************
*** 426,431 ****
--- 426,432 ----
                ifp->if_snd.ifq_maxlen) {
                        error = ENOBUFS;
                        ipstat.ips_odropped++;
+                       ifp->if_snd.ifq_drops += (ip->ip_len / ifp->if_mtu + 1);
                        goto bad;
        }
  

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->patched 
State-Changed-By: glebius 
State-Changed-When: Tue Dec 6 11:02:57 GMT 2005 
State-Changed-Why:  
Committed to HEAD. 


Responsible-Changed-From-To: freebsd-bugs->glebius 
Responsible-Changed-By: glebius 
Responsible-Changed-When: Tue Dec 6 11:02:57 GMT 2005 
Responsible-Changed-Why:  
I'll handle this. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=72440 
State-Changed-From-To: patched->closed 
State-Changed-By: glebius 
State-Changed-When: Wed Dec 28 13:40:03 UTC 2005 
State-Changed-Why:  
Merged to RELENG_5 and RELENG_6. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=72440 
>Unformatted:
