Re: Re: pg_restore fails on Windows

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Re: pg_restore fails on Windows
Дата
Msg-id 1178.1219079897@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: pg_restore fails on Windows  (Tom Tom <cobold@seznam.cz>)
Список pgsql-general
=?us-ascii?Q?Tom=20Tom?= <cobold@seznam.cz> writes:
> Magnus Hagander wrote:
>> Attached is a pg_restore.exe off CVS tip today, which should include the
>> patch. Please try this one.

> I tested the restore using the provided pg_restore.exe. The output is:

> pg_restore: [archiver (db)] could not execute query: could not send data to server: No buffer space available
(0x00002747/10055)

According to
http://support.microsoft.com/kb/201213
this is an acknowledged bug that's been broken since Windows 95, so
I suppose we should conclude that M$ is unwilling or incompetent to
fix it.

Possibly the best workaround is something like

+ #ifndef WIN32
        sent = pqsecure_write(conn, ptr, len);
+ #else
+         /* Windows tends to fail on large sends, see KB 20213 */
+         sent = pqsecure_write(conn, ptr, Min(len, 65536));
+ #endif

in pqSendSome().  The backend seems to not be subject to a similar
problem because it's already filtering its output through a limited-size
buffer.

            regards, tom lane

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

Предыдущее
От: "Scott Marlowe"
Дата:
Сообщение: Re: failed to re-find parent key in "..."
Следующее
От: "Francisco Figueiredo Jr."
Дата:
Сообщение: Re: Postres.exe Processes Hang