Re: Low throughput of binary inserts from windows to linux

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Low throughput of binary inserts from windows to linux
Дата
Msg-id 21549.1165886726@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Low throughput of binary inserts from windows to linux  ("Axel Waggershauser" <awagger@web.de>)
Ответы Re: Low throughput of binary inserts from windows to linux
Re: Low throughput of binary inserts from windows to linux
Список pgsql-performance
"Axel Waggershauser" <awagger@web.de> writes:
> I tested different sizes on linux some time ago and found that 64KB
> was optimal. But playing with different sizes again revealed that my
> windows->linux problem seems to be solved if I use _any_ other
> (reasonable - meaning something between 4K and 512K) power of two ?!?

I think this almost certainly indicates a Nagle/delayed-ACK
interaction.  I googled and found a nice description of the issue:
http://www.stuartcheshire.org/papers/NagleDelayedAck/

Note that there are no TCP connections in which message payloads are
exact powers of two (and no, I don't know why they didn't try to make
it so).  You are probably looking at a situation where this particular
transfer size results in an odd number of messages where the other sizes
do not, with the different overheads between Windows and everybody else
accounting for the fact that it's only seen with a Windows sender.

If you don't like that theory, another line of reasoning has to do with
the fact that the maximum advertiseable window size in TCP is 65535 ---
there could be some edge-case behaviors in the Windows and Linux stacks
that don't play nicely together for 64K transfer sizes.

            regards, tom lane

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

Предыдущее
От: "Axel Waggershauser"
Дата:
Сообщение: Re: Low throughput of binary inserts from windows to linux
Следующее
От: Michael Stone
Дата:
Сообщение: Re: New to PostgreSQL, performance considerations