Re: slow request - Mailing list pgsql-general

From Michael Guiard
Subject Re: slow request
Date
Msg-id 59b5d0100710160538u59e0c47eq2bbd34595dd3e31f@mail.gmail.com
Whole thread Raw
In response to Re: slow request  (Frank Finner <postgresql@finner.de>)
List pgsql-general
Hi !
thanks for your answers
My network works correctly, I have no other problems. I can send/receive huge files quickly using the windows file share protocol.
Using psql tool, I have the same results ... very slow traffic ... :(
I measure these time and speeds using my watch and a free network tool : ShowTraffic (Ethereal gives me the same results).
 
I will try using another switch ...
 
On 10/9/07, Frank Finner <postgresql@finner.de> wrote:
On Tue, 09 Oct 2007 10:34:45 -0000 michael.guiard@gmail.com thought long, then sat down and wrote:

> Hi !
> I am using postgreSQL v8.1.5 with latest odbc driver v8.02.0500.
> I have very slow request between my server and my client. They are
> both on the same switch 100Mb/s. I have no particular network
> problems.
> I use the pgadmin tool to do my request.
>
> My database is compose of one table. This table has some simple fields
> (varchar & int, less than 500 bytes) and its primary key is a
> varchar(32) (CLSID). This table has 140000 records.
> I know the primary key as a clsid is not the best choice, but it is
> mine :)
>
> The request "select * from mytable" on the server takes
> approximatively 30 seconds.
> The same request on the client takes approximatively 400 seconds !
> What I do not understand is that my network traffic during this
> request on the client side is very low. It is less than 100KB/s !
>
> Why is it so slow ? I suppose that my 140000 records are retrieve one
> by one... is it true ? if yes, why ?
>
> I try to do the same thing with another table with a primary key as
> 'int4'. The result is the same : 540 secs to retrieve 150000 records
> at 45 KB/s (average speed) (132 octets/record * 150000 = 19MB / 45 KB/
> s = 430 seconds)
>
> How can I improve these performances ?
> thanks
> Mike
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 9: In versions below 8.0, the planner will ignore your desire to
>        choose an index scan if your joining column's datatypes do not
>        match


This could be a DNS related problem, if not the request itself, but the connect, is slow. How did you measure these times and speeds?

--
Frank Finner

Invenius - Lösungen mit Linux
Köpfchenstraße 36
57072 Siegen
Telefon: 0271 231 8606    Mail: frank.finner@invenius.de
Telefax: 0271 231 8608    Web:   http://www.invenius.de
Key fingerprint = 90DF FF40 582E 6D6B BADF  6E6A A74E 67E4 E788 2651



pgsql-general by date:

Previous
From: Rob Shepherd
Date:
Subject: variable in COPY TO variable
Next
From: Thomas Kellerer
Date:
Subject: Preserving view source code