Re: how to fix problem then when two queries run at the same time, it takes longer to complete then if run in sequence

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: how to fix problem then when two queries run at the same time, it takes longer to complete then if run in sequence
Дата
Msg-id 20080723193048.GB3580@alvh.no-ip.org
обсуждение исходный текст
Ответ на how to fix problem then when two queries run at the same time, it takes longer to complete then if run in sequence  (Miernik <public@public.miernik.name>)
Список pgsql-performance
Miernik wrote:
> I have a PostgreSQL database on a very low-resource Xen virtual machine,
> 48 MB RAM. When two queries run at the same time, it takes longer to
> complete then if run in sequence. Is there perhaps a way to install
> something like a query sequencer, which would process queries in a FIFO
> manner, one at a time, even if a new query comes before the last one
> running is finished, it would not give the new query to the server
> before the one running now finishes? That would greatly improve
> performance.

One idea I just had was to have a connection pooler (say pgpool) and
allow only one connection slot.  If the pooler is capable to be
configured to block new connections until the slot is unused, this would
do what you want.  (I don't know whether poolers allow you to do this).

--
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

В списке pgsql-performance по дате отправления:

Предыдущее
От: "Scott Marlowe"
Дата:
Сообщение: Re: how to fix problem then when two queries run at the same time, it takes longer to complete then if run in sequence
Следующее
От: "Jeffrey Baker"
Дата:
Сообщение: Re: Samsung 32GB SATA SSD tested