From owner-freebsd-hackers Tue Dec 2 00:32:25 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id AAA11450 for hackers-outgoing; Tue, 2 Dec 1997 00:32:25 -0800 (PST) (envelope-from owner-freebsd-hackers) Received: from implode.root.com (implode.root.com [198.145.90.17]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id AAA11439 for ; Tue, 2 Dec 1997 00:32:21 -0800 (PST) (envelope-from root@implode.root.com) Received: from implode.root.com (localhost [127.0.0.1]) by implode.root.com (8.8.5/8.8.5) with ESMTP id AAA15970; Tue, 2 Dec 1997 00:34:30 -0800 (PST) Message-Id: <199712020834.AAA15970@implode.root.com> To: Amancio Hasty cc: Charles Mott , hackers@FreeBSD.ORG Subject: Re: ftp server on ftp.cdrom.com In-reply-to: Your message of "Mon, 01 Dec 1997 20:50:47 PST." <199712020450.UAA01727@rah.star-gate.com> From: David Greenman Reply-To: dg@root.com Date: Tue, 02 Dec 1997 00:34:30 -0800 Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk >> On Mon, 1 Dec 1997, Amancio Hasty Jr wrote: >> > >> > Actually, I was thinking more along the lines of state machine with >> > the functionality to share data transfers you know to avoid the >> > case of hundreds of users opening a single file N times. >> > >> > Most network engineers are familiar with an event or a state machine >> > driven network server . >> > >> > Cheers, >> > Amancio >> > >> >> Initially, I was thinking that port 20 data transfers (as opposed to port >> 21 control traffic) had to be either separate processes or threads, but >> now I think you are right -- everything could be done by a synchronous >> state machine in a single user process, but this might be inefficient. > >You can do it as you have suggested also the thing to keep in mind is the >cost of per connection and memory. For instance a process context switch >plus the over head of a process is not a very efficient mechanism for >large scale ftp servers. Oh? Are you speaking as an authority on this subject? :-) Actually, context switch overhead is not a problem. Processes in FreeBSD are fairly light weight in terms of memory as well and most of the memory is consumed by socket and disk buffers, not by the overhead of a process (at least in my implementation of ftpd). Anyway, I don't mean to squelch the conversation regarding this, but I do ask that people not make silly assumptions without first actually studying the problem. -DG David Greenman Core-team/Principal Architect, The FreeBSD Project