pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: PFC <lists@peufeu.com>
To: Ross J. Reedstrom <reedstrm@rice.edu>
To: pgsql-performance <pgsql-performance@postgresql.org>
Subject: Re: TCP network cost
Date: Thu, 19 Feb 2009 14:09:04 +0100
Message-ID: <op.upln5emacigqcu@soyouz> (raw)
In-Reply-To: <20090217211454.GB23707@cooker>
References: <20090217070403.GB2486@cooker>
	<1ca1c1410902171013q478f2620n13fcd68cb8b3d911@mail.gmail.com>
	<3FAF940B-9B0B-4DBA-8728-6096022129DF@infogears.com>
	<alpine.DEB.1.10.0902170032440.25606@asgard.lang.hm>
	<20090217200416.GA23707@cooker>
	<B7A2E4DA-A137-46F5-8643-2EF3772F4D2C@infogears.com>
	<20090217211454.GB23707@cooker>


> python w/ psycopg (or psycopg2), which wraps libpq. Same results w/
> either version.

	I've seen psycopg2 saturate a 100 Mbps ethernet connection (direct  
connection with crossover cable) between postgres server and client during  
a benchmark... I had to change the benchmark to not retrieve a large TEXT  
column to remove this bottleneck... this was last year so versions are  
probably different, but I don't think this matters a lot...

> Note the 'bare' transfer times added above. Nothing to write home about
> (~3Mb/sec) but another order of magnitude faster than the postgresql
> transfer.

	You should test with sending a large (>100 MB) amount of data through  
Netcat. This should give you your maximum wire speed. Use /dev/null as the  
test file, and use "pv" (pipe viewer) to measure throughput :

box 1 : pv < /dev/zero | nc -lp 12345
box 2 : nc (ip) 12345 >/dev/null

	On gigabit lan you should get 100 MB/s, on 100BaseT about 10 MB/s. If you  
dont get that, there is a problem somewhere (bad cable, bad NIC, slow  
switch/router, etc). Monitor CPU during this test (vmstat). Usage should  
be low.




view thread (23+ messages)  latest in thread

Message-ID: <op.upln5emacigqcu@soyouz>
Permalink:  ../op.upln5emacigqcu@soyouz/
Also on:    postgresql.org/message-id/op.upln5emacigqcu@soyouz

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: lists@peufeu.com, reedstrm@rice.edu
  Subject: Re: TCP network cost
  In-Reply-To: <op.upln5emacigqcu@soyouz>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox