From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10905 invoked by alias); 31 Aug 2007 14:03:20 -0000 Received: (qmail 10895 invoked by uid 22791); 31 Aug 2007 14:03:20 -0000 X-Spam-Check-By: sourceware.org Received: from mx2.lvl7.com (HELO lvl7-trend01.lvl7.com) (66.192.95.83) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 31 Aug 2007 14:03:10 +0000 Received: from lvl7in-mail01.lvl7.com ([10.240.1.18]) by lvl7-trend01.lvl7.com with InterScan VirusWall; Fri, 31 Aug 2007 10:02:49 -0400 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Date: Fri, 31 Aug 2007 14:03:00 -0000 Message-ID: References: <009401c7ebb5$65c20310$31460930$@net> <20070831122659.GA3789@lunn.ch> <009a01c7ebcc$16afe370$440faa50$@net> From: "Alok Singh" To: "Rick Davis" , "Andrew Lunn" Cc: "Ecos-Discuss" Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Subject: RE: [ECOS] network problem more info X-SW-Source: 2007-08/txt/msg00182.txt.bz2 Rick, This is already solved in current cvs code net package. Please have a look at the CVS code. regards, Alok -----Original Message----- From: ecos-discuss-owner@ecos.sourceware.org [mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Rick Davis Sent: Friday, August 31, 2007 6:10 PM To: 'Andrew Lunn' Cc: 'Ecos-Discuss' Subject: RE: [ECOS] network problem more info Andrew, I finally found the problem. Bsd_accept in net\bsd_tcpip\current\src\sys\kern\sockio.c wasn't freeing sa. Add the following at or around line 447. It has "done:" label on the "#else" portion of an "#if 0" if (sa) FREE (sa, M_SONAME); Rick Davis -----Original Message----- From: Andrew Lunn [mailto:andrew@lunn.ch]=20 Sent: Friday, August 31, 2007 8:27 AM To: Rick Davis Cc: Ecos-Discuss Subject: Re: [ECOS] network problem more info On Fri, Aug 31, 2007 at 05:57:51AM -0400, Rick Davis wrote: > To try to narrow down my memory issue. I wrote a client program that just > creates a socket, connects to port 80 and then shuts down and closes the > socket. Every time I run it 32 bytes of memory is allocated. If I keep > running the application the memory is consumed. If I let thing sit for > minutes, some of the memory is returned. This part is normal behaviour. The server socket is not closed immediately. It hangs around for a while so that it can eat any old retry packets for the connection which are still flying around the network. What you don't want is these old packets being injected into a new connection stream. What you need to do is run the test as before. Then stop the client and watch the memory usage. It should slowly decrease as these old sockets are freed after a timeout. Once it is stopped freeing, reached a steady state, you can then investigate what looks like lost memory. You probably want to go searching in the ecos mail archive, eg: http://ecos.sourceware.org/ml/ecos-discuss/2003-10/msg00380.html and http://www.cygwin.com/ml/ecos-discuss/2003-12/msg00181.html Andrew --=20 Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss