Re: pgsql: Speed up CREATE DATABASE by deferring the fsyncs until after

Поиск
Список
Период
Сортировка
От Greg Stark
Тема Re: pgsql: Speed up CREATE DATABASE by deferring the fsyncs until after
Дата
Msg-id 407d949e1002220215l6fe8816al6703a5dc79e24894@mail.gmail.com
обсуждение исходный текст
Ответ на Re: pgsql: Speed up CREATE DATABASE by deferring the fsyncs until after  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Re: pgsql: Speed up CREATE DATABASE by deferring the fsyncs until after  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-committers
On Mon, Feb 22, 2010 at 2:54 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Actually, that code had *multiple* problems including stat'ing the wrong
> file entirely, not to mention that this last commit failed to even
> compile.  I also think it should scan the todir not the fromdir, just on
> general principles to avoid any possibility of race conditions.

Argh. I'll be less careless in the future, I promise.

I had concluded that scanning the original directory was odd but
better because it served to double-check that all the original files
actually made it and also because if there were any unrelated files
present there was no need to fsync them. But I agree it's odd and not
very general for copydir if we decide to use it elsewhere other than
create database.




--
greg

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: pgsql: Speed up CREATE DATABASE by deferring the fsyncs until after
Следующее
От: heikki@postgresql.org (Heikki Linnakangas)
Дата:
Сообщение: pgsql: Move documentation of all recovery.conf option to a new chapter.