Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id 8040C39B90C for ; Sun, 1 Apr 2012 19:02:06 -0300 (ADT) Received: from nm24-vm0.bullet.mail.sp2.yahoo.com ([98.139.91.226]) by makus.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1SESqZ-0001Yh-R8 for pgsql-performance@postgresql.org; Sun, 01 Apr 2012 22:02:05 +0000 Received: from [98.139.91.63] by nm24.bullet.mail.sp2.yahoo.com with NNFMP; 01 Apr 2012 22:01:50 -0000 Received: from [98.139.91.4] by tm3.bullet.mail.sp2.yahoo.com with NNFMP; 01 Apr 2012 22:01:50 -0000 Received: from [127.0.0.1] by omp1004.mail.sp2.yahoo.com with NNFMP; 01 Apr 2012 22:01:50 -0000 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 356246.13623.bm@omp1004.mail.sp2.yahoo.com Received: (qmail 70468 invoked by uid 60001); 1 Apr 2012 22:01:50 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1333317709; bh=0krlG4dIhN6Y2YUjtSc0/NazfaHKifhILXa6s6MMyDc=; h=X-YMail-OSG:Received:X-Mailer:References:Message-ID:Date:From:Reply-To:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=Ka/FZlgQISgw2DgRArXeU7sD9YbsRWe3rFU64+Mdlo+PU1fTve0RZ25N7mQXo8qhDo+jli8RLIuJHpYN3TGd7zoQZxzY8v/7fK7UYTbvojlKeCHnvrXw5yWfGfrNLHon2vOsZ6B4PVLkOSuWk2iKqQAcaE0jdI7u9G+tKwvyNks= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:X-Mailer:References:Message-ID:Date:From:Reply-To:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=0NA0kjGGobru+TPYrZuQF5wSj4p9ViD/QV0U5r4g4PJx4mRXpgzpBFTNWXWLPwe7uewpS28EWcCklJ3qwTiUl2TDUi4l/f3LHmA0dLh95RRjen9bHphi9GxNV/orFB8mzAIwvS37woJRDQhykbKMHAaA/12w1ipV1deIl8A12aE=; X-YMail-OSG: siyU4AwVM1lwHNQ0KcsL36YnyJIsGj1uRbufPJQaU6ivW3V ARE98ysGqZjRi1YfVJUbbG4vncCKcxk9w0iKZDKWs1ZcT33uXkNNa6Hl4Wab fnjABHfjpQ7UewazDgNdLUcmn2.U2xOTAuIqo.2PR6exbyO0Y_8lc9Mxh5RP z5JJcvar0joRingIV3svWJXey.U0ySnliF1eCq6du7t3gCmOYTbEYPmPoYy6 Kv_mDXYraW8esoLY4ahNWL59ZVPDWM.NI_xhj4J1zTbVHawtKkw6pzuE6i7k nrD5Uzk6WvfXBvc3ykJxK9GhBGziHv6kVZbUlJOBZs7IxCID9DIPWNLtGTsH 21mFkCTW78rCluAQZKMLzfaZhfJ99pvI0UJMZWPO8L0TJUU5ci8vPH22_3_. 9PiTdVo6hmrPULRjWPYJvQVKmKCl4T9H3IGabtj47TIymS_L2V4drJ8ZF8x_ zEG11csD3vdxbcmKKu4GPX4ton.7JNV4Vddbki_LnfslO6lVRWLYqrFIDq.d hEFcDmKCQpJebs6Nbe8UZiRIYNcozGloWqWoasDSIvDcM8_n_5eHcCmr7Ti2 zZjcLR_QMq0mp9cI8Zl2KEb0UeWpY0X0bWB3xBOy3kucn Received: from [24.34.119.122] by web111301.mail.gq1.yahoo.com via HTTP; Sun, 01 Apr 2012 15:01:49 PDT X-Mailer: YahooMailWebService/0.8.117.340979 References: <217DDBC2BB1E394CA9E7446337CBDEF20102DEDB4A58@il-ex01.ad.checkpoint.com> Message-ID: <1333317709.70394.YahooMailNeo@web111301.mail.gq1.yahoo.com> Date: Sun, 1 Apr 2012 15:01:49 -0700 (PDT) From: Andy Reply-To: Andy Subject: Re: TCP Overhead on Local Loopback To: Ofer Israeli , "pgsql-performance@postgresql.org" In-Reply-To: <217DDBC2BB1E394CA9E7446337CBDEF20102DEDB4A58@il-ex01.ad.checkpoint.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="2046195254-459994212-1333317709=:70394" X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201204/2 X-Sequence-Number: 46648 --2046195254-459994212-1333317709=:70394 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable You could try using Unix domain socket and see if the performance improves.= A relevant link:=0A=0Ahttp://stackoverflow.com/questions/257433/postgresql= -unix-domain-sockets-vs-tcp-sockets=0A=0A=0A=0A____________________________= ____=0A From: Ofer Israeli =0ATo: "pgsql-performance@= postgresql.org" =0ASent: Sunday, April 1= , 2012 4:24 PM=0ASubject: [PERFORM] TCP Overhead on Local Loopback=0A =0A= =0AHi =0Aall,=0A=A0=0AWe are running =0Aperformance tests using PG 8.3 on a= Windows 2008 R2 machine connecting locally =0Aover TCP.=0AIn our tests, we= =0Ahave found that it takes ~3ms to update a table with ~25 columns and 60= K =0Arecords, with one column indexed.=0AWe have reached this =0Anumber aft= er many tweaks of the database configuraiton and one of the changes we =0Am= ade was to perform the updates in batches of 5K as opposed to the pervious = =0Atransaction per event.=A0 Note that our use of batches is to have only o= ne =0Atransaction, but still each of the 5K events is independently SELECTi= ng and =0AUPDATEing records, i.e. it is not all contained in a stored proce= dure or =0Asuch.=0A=A0=0AStill these times =0Aare too high for us and we ar= e looking to lower them and I am wondering about =0Athe TCP/IP overhead of = passing the information back and forth.=A0 Does anyone =0Ahave any numbers = in what the TCP could cost in the configuration mentioned above =0Aor point= ers on how to test it?=0A=A0=0A=A0=0AMany =0Athanks,=0AOfer --2046195254-459994212-1333317709=:70394 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable
You could = try using Unix domain socket and see if the performance improves. A relevan= t link:


<= div style=3D"font-size: 12pt; font-family: 'times new roman', 'new york', t= imes, serif; ">

From: Ofer Israeli= <oferi@checkpoint.com>
To:= "pgsql-performance@postgresql.org" <pgsql-performance@postgresql.org>= ;
Sent: Sunday, April= 1, 2012 4:24 PM
Subject:<= /b> [PERFORM] TCP Overhead on Local Loopback

=0A=0A=0A =0A =0A
=0A
Hi =0Aall,
=0A
 
=0A
We are running= =0Aperformance tests using PG 8.3 on a Windows 2008 R2 machine connecting = locally =0Aover TCP.
=0A
In our tests, we =0Aha= ve found that it takes ~3ms to update a table with ~25 columns and 60K =0Ar= ecords, with one column indexed.
=0A
We have re= ached this =0Anumber after many tweaks of the database configuraiton and on= e of the changes we =0Amade was to perform the updates in batches of 5K as = opposed to the pervious =0Atransaction per event.  Note that our use o= f batches is to have only one =0Atransaction, but still each of the 5K even= ts is independently SELECTing and =0AUPDATEing records, i.e. it is not all = contained in a stored procedure or =0Asuch.
=0A
 
=0A
Still these times =0Aare too high f= or us and we are looking to lower them and I am wondering about =0Athe TCP/= IP overhead of passing the information back and forth.  Does anyone = =0Ahave any numbers in what the TCP could cost in the configuration mention= ed above =0Aor pointers on how to test it?
=0A
=  
=0A
 
=0A
Many =0Athanks,
=0A
Ofer
=
=0A


--2046195254-459994212-1333317709=:70394--