From fvw@var.cx  Thu Jul 26 17:31:42 2001
Return-Path: <fvw@var.cx>
Received: from ion.var.cx (e166066.upc-e.chello.nl [213.93.166.66])
	by hub.freebsd.org (Postfix) with ESMTP id BEECD37B403
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 26 Jul 2001 17:31:40 -0700 (PDT)
	(envelope-from fvw@var.cx)
Received: (from fvw@localhost)
	by ion.var.cx (8.11.3/8.11.3) id f6R2ZVR18145;
	Fri, 27 Jul 2001 02:35:32 GMT
	(envelope-from fvw)
Message-Id: <200107270235.f6R2ZVR18145@ion.var.cx>
Date: Fri, 27 Jul 2001 02:35:32 GMT
From: fvw@var.cx
Reply-To: fvw@var.cx
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: natd forgets about udp connections
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         29253
>Category:       bin
>Synopsis:       natd(8) forgets about udp connections
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Jul 26 17:40:01 PDT 2001
>Closed-Date:    
>Last-Modified:  Sun Jul 01 15:59:35 UTC 2012
>Originator:     Frank v Waveren
>Release:        FreeBSD 4.3-RELEASE i386
>Organization:
none
>Environment:
>Description:

I have a problem where natd appears to be losing entries from it's
table of forwarded connections... I have the sysctl
net.inet.ipf.fr_udptimeout set to 864000, and yet, once in a while, 
natd forgets about the previous traffic all together, as illustrated
by the following tcpdumps (this is icq traffic):

on ed0 (the public interface):
13:30:26.085447 fes-d006.icq.aol.com.4000 > e166066.upc-e.chello.nl.1026: udp 21 (DF)
13:30:50.033977 fes-d006.icq.aol.com.4000 > e166066.upc-e.chello.nl.1026: udp 70 (DF)
13:30:50.038764 e166066.upc-e.chello.nl.1026 > fes-d006.icq.aol.com.4000: udp 28
13:32:03.114457 fes-d006.icq.aol.com.4000 > e166066.upc-e.chello.nl.1026: udp 70 (DF)
13:32:03.116865 e166066.upc-e.chello.nl > fes-d006.icq.aol.com: icmp: e166066.upc-e.chello.nl udp port 1026 unreachable (DF)
13:32:09.117458 fes-d006.icq.aol.com.4000 > e166066.upc-e.chello.nl.1026: udp 70 (DF)
13:32:09.119853 e166066.upc-e.chello.nl > fes-d006.icq.aol.com: icmp: e166066.upc-e.chello.nl udp port 1026 unreachable (DF)

on ed1 (on the local net):

13:30:26.086744 fes-d006.icq.aol.com.4000 > hypnos.1026: udp 21 (DF)
13:30:50.035364 fes-d006.icq.aol.com.4000 > hypnos.1026: udp 70 (DF)
13:30:50.036130 hypnos.1026 > fes-d006.icq.aol.com.4000: udp 28
13:32:25.976894 ...

In these examples, e166066.upc-e.chello.nl is the public ip of the nat
box, hypnos is the host from which the traffic is coming (this host is
behind the nat box).

>How-To-Repeat:
Just run natd and do udp traffic.

>Fix:
Unknown.
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->ru 
Responsible-Changed-By: kris 
Responsible-Changed-When: Sat Jul 28 00:46:30 PDT 2001 
Responsible-Changed-Why:  
Ruslan has worked on natd in the past 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=29253 

From: Ruslan Ermilov <ru@FreeBSD.ORG>
To: fvw@var.cx
Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: Re: bin/29253: natd forgets about udp connections
Date: Mon, 6 Aug 2001 14:38:08 +0300

 On Fri, Jul 27, 2001 at 02:35:32AM +0000, fvw@var.cx wrote:
 > 
 > I have a problem where natd appears to be losing entries from it's
 > table of forwarded connections... I have the sysctl
 > net.inet.ipf.fr_udptimeout set to 864000, and yet, once in a while, 
 > natd forgets about the previous traffic all together, as illustrated
 > by the following tcpdumps (this is icq traffic):
 > 
 This is because libalias has different idea about this timeout:
 
 /* Timeouts (in seconds) for different link types */
 #define ICMP_EXPIRE_TIME             60
 #define UDP_EXPIRE_TIME              60
 #define PROTO_EXPIRE_TIME            60
 
 Unfortunately, you don't currently have the way to change these
 timeouts from within natd(8), at run-time.  You should manually
 edit these values in src/lib/libalias/alias_db.c, recompile and
 reinstall libalias library, then recompile and reinstall natd.
 
 I will eventually add this feature to libalias and natd.
 
 
 Cheers,
 -- 
 Ruslan Ermilov		Oracle Developer/DBA,
 ru@sunbay.com		Sunbay Software AG,
 ru@FreeBSD.org		FreeBSD committer,
 +380.652.512.251	Simferopol, Ukraine
 
 http://www.FreeBSD.org	The Power To Serve
 http://www.oracle.com	Enabling The Information Age
Responsible-Changed-From-To: ru->freebsd-bugs 
Responsible-Changed-By: ru 
Responsible-Changed-When: Fri Apr 16 23:15:49 PDT 2004 
Responsible-Changed-Why:  
ENOTIME. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=29253 
State-Changed-From-To: open->analyzed 
State-Changed-By: mav 
State-Changed-When: Sun Jun 22 22:18:56 UTC 2008 
State-Changed-Why:  
Ruslan Ermilov sounded the source of problem. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=29253 
State-Changed-From-To: analyzed->open 
State-Changed-By: eadler 
State-Changed-When: Sun Jul 1 15:59:34 UTC 2012 
State-Changed-Why:  
unowned PRs should not be in analyzed state 

http://www.freebsd.org/cgi/query-pr.cgi?pr=29253 
>Unformatted:
 >System: FreeBSD ion.var.cx 4.3-RELEASE FreeBSD 4.3-RELEASE #27: Tue May 8 03:18:16 GMT 2001 fvw@noi.var.cx:/usr/src/sys/compile/NOI i386
