From owner-cvs-all@FreeBSD.ORG Sun Jul 10 18:00:37 2005 Return-Path: X-Original-To: cvs-all@FreeBSD.ORG Delivered-To: cvs-all@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A585316A41C; Sun, 10 Jul 2005 18:00:37 +0000 (GMT) (envelope-from sobomax@portaone.com) Received: from www.portaone.com (support.portaone.com [195.70.151.35]) by mx1.FreeBSD.org (Postfix) with ESMTP id 017EC43D60; Sun, 10 Jul 2005 18:00:30 +0000 (GMT) (envelope-from sobomax@portaone.com) Received: from [192.168.0.254] ([192.168.2.2]) (authenticated bits=0) by www.portaone.com (8.12.11/8.12.11) with ESMTP id j6AI0Sd5067828 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 10 Jul 2005 20:00:28 +0200 (CEST) (envelope-from sobomax@portaone.com) Message-ID: <42D16238.7010206@portaone.com> Date: Sun, 10 Jul 2005 21:00:24 +0300 From: Maxim Sobolev Organization: Porta Software Ltd User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Pawel Jakub Dawidek References: <200507082128.j68LSQlp096358@repoman.freebsd.org> In-Reply-To: <200507082128.j68LSQlp096358@repoman.freebsd.org> Content-Type: text/plain; charset=KOI8-U; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV 0.83/974/Fri Jul 8 23:09:18 2005 on www.portaone.com X-Virus-Status: Clean Cc: cvs-src@FreeBSD.ORG, src-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/sbin/ggate/ggatec Makefile ggatec.c src/sbin/ggate/ggated Makefile ggated.c src/sbin/ggate/shared ggate.c ggate.h X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Maxim.Sobolev@portaone.com List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Jul 2005 18:00:37 -0000 Great work, Pawel! Unrelated question, but I wonder if it would be a good idea to base ggate on some industry-standart remote-storage protocol instead (iSCSI being an obvious choice) or at least add a support for it. -Maxim Pawel Jakub Dawidek wrote: > pjd 2005-07-08 21:28:26 UTC > > FreeBSD src repository > > Modified files: > sbin/ggate/ggatec Makefile ggatec.c > sbin/ggate/ggated Makefile ggated.c > sbin/ggate/shared ggate.c ggate.h > Log: > Reimplement ggatec/ggated applications. > > Change communication protocol to be much more resistant on network > problems and to allow for much better performance. > > Better performance is achieved by creating two connections between > ggatec and ggated one for sending the data and one for receiving it. > Every connection is handled by separeted thread, so there is no more > synchronous data flow (send and wait for response), now one threads > sends all requests and another receives the data. > > Use two threads in ggatec(8): > - sendtd, which takes I/O requests from the kernel and sends them to the > ggated daemon on the other end; > - recvtd, which waits for ggated responses and forwards them to the kernel. > > Use three threads in ggated(8): > - recvtd, which waits for I/O requests and puts them onto incoming queue; > - disktd, which takes requests from the incoming queue, does disk operations > and puts finished requests onto outgoing queue; > - sendtd, which takes finished requests from the outgoing queue and sends > responses back to ggatec. > > Because there were major changes in communication protocol, there is no > backward compatibility, from now on, both client and server has to run > on 5.x or 6.x (or at least ggated should be from the same FreeBSD version > on which ggatec is running). > > For Gbit networks some buffers need to be increased. I use those settings: > kern.ipc.maxsockbuf=16777216 > net.inet.tcp.sendspace=8388608 > net.inet.tcp.recvspace=8388608 > and I use '-S 4194304 -R 4194304' options for both, ggatec and ggated. > > Approved by: re (scottl) > > Revision Changes Path > 1.5 +2 -2 src/sbin/ggate/ggatec/Makefile > 1.5 +322 -192 src/sbin/ggate/ggatec/ggatec.c > 1.4 +3 -0 src/sbin/ggate/ggated/Makefile > 1.6 +631 -237 src/sbin/ggate/ggated/ggated.c > 1.5 +71 -11 src/sbin/ggate/shared/ggate.c > 1.3 +65 -13 src/sbin/ggate/shared/ggate.h > > >