Skip site navigation (1) Skip section navigation (2)

Re: how to improve performance in libpq?

From: Tony Liao <tonyliao(at)yuehetone(dot)com>
To: Eddy Ernesto Baños Fernández <eebanos(at)estudiantes(dot)uci(dot)cu>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: how to improve performance in libpq?
Date: 2009-05-14 05:24:01
Message-ID: 8f750b7c0905132224o72f3280hdecc97c5e3504bed@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-admin
Thanks,Eddy
       I try to reduce the max_connections,but seems nothing improved.
       I made a large max_connections because I have to increase the number
of connection pools.In requirement,the access or query may suddenly increase
to 3000 or more.so in next, I would tested with more connection pools.
       thanks for your document,I would read ASAP.
2009/5/14 Eddy Ernesto Baños Fernández <eebanos(at)estudiantes(dot)uci(dot)cu>

>  Take a look of the attachment.  I hope it helps.
>
> You must configure your postgresql.conf in the right way, 3000
> max_connections it´s a big mistake…. Try reduce the max_connections and use
> a pooling service instead, then run your tests again.
>
>
>
>
>
>
>
> *De:* pgsql-admin-owner(at)postgresql(dot)org [mailto:
> pgsql-admin-owner(at)postgresql(dot)org] *En nombre de *Tony Liao
> *Enviado el:* miércoles, 13 de mayo de 2009 22:39
> *Para:* pgsql-admin(at)postgresql(dot)org
> *Asunto:* [ADMIN] how to improve performance in libpq?
>
>
>
> Hi,All,
>
>      I have a question in libpq.the postgresql dadabase about 32MB(base on
> backup),and I tried to analyze query as :EXPLAIN ANALYZE SELECT
> .........where id=123 ,got the total actual time is 2.882ms.
>
>      Now,I start a test programe base on ../src/test/examples/testlibpq.c
> ,which has 900 connection pools,and the id will be to increase for each
> query.In total I test 160000 queries, used time 1012s. That seems a greate
> different with 2.88ms/each query.    any idea?
>
>      test environment      :
>
>      database hardware    CUP  2*Xeon 5405
>
>                                     MEMORY  DDR2 16GB/800 with DIMM
>
>                                     HARDISK   160GB/8M SATA
>
>       network :LAN 1Gbps
>
>
>
>
>
>       configuration files:
>
>          max_connections = 3000
>
>          shared_buffers = 64MB
>
>          work_mem = 4MB
>
>          maintenance_work_mem = 4MB
>          max_stack_depth = 1MB
>          the others as default.
>
>
>
>         any idea?
>
>         I hope you can understand,thanks.
>

In response to

pgsql-admin by date

Next:From: S ArvindDate: 2009-05-14 09:27:16
Subject: pg_top problem
Previous:From: Tony LiaoDate: 2009-05-14 02:38:56
Subject: how to improve performance in libpq?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group