Re: Feature proposal

Поиск
Список
Период
Сортировка
От Adrian von Bidder
Тема Re: Feature proposal
Дата
Msg-id 201008262130.26040@fortytwo.ch
обсуждение исходный текст
Ответ на Feature proposal  (wstrzalka <wstrzalka@gmail.com>)
Список pgsql-general
Heyho!

On Wednesday 25 August 2010 09.15:33 wstrzalka wrote:
> I'm currently playing with very large data import using COPY from
> file.
>
> As this can be extremely long operation (hours in my case) the nice
> feature would be some option to show operation progress - how many
> rows were already imported.

Recently, I've found (on Linux, don't know if other OSs export this
information) /proc/<pid>/fdinfo/<fd> extremely helpful.  It tells you the
position of the file pointer of file number <fd> in process <pid> (I guess
for a COPY import this would be the postgresql backend handling your import
session.)

Unlike other options, you can also use this if you only notice that the
process is long-running after you've already started it.

Of course it probably will not work if the file is mmapped or otherwise not
read in a sequential fashion.

cheers
-- vb

--
All Hail Discordia!

Вложения

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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: WAL Archive Log
Следующее
От: Mike Christensen
Дата:
Сообщение: Is your data okay?