Re: pgsql: Adjust initdb to also not consider fsync'ing failures fatal.

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: pgsql: Adjust initdb to also not consider fsync'ing failures fatal.
Дата
Msg-id 55691D1C.2050905@gmx.net
обсуждение исходный текст
Ответ на Re: pgsql: Adjust initdb to also not consider fsync'ing failures fatal.  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-committers
On 5/29/15 4:06 PM, Tom Lane wrote:
> Peter Eisentraut <peter_e@gmx.net> writes:
>> On 5/29/15 1:05 PM, Tom Lane wrote:
>>> Adjust initdb to also not consider fsync'ing failures fatal.
>
>> This introduces a failure in the initdb tests, which expect that
>>     initdb -S -D /notthere
>> returns a nonzero exit code.
>
> Hm, I guess we don't run anything else that touches the DB directory
> in this case?  In the backend case we'd have failed much earlier.

Yeah, in the backend, there are various checks earlier that the data
directory exists.

> I'm not 100% convinced that the test case's expectation is necessarily
> the right thing, though.

Well, I think a tool

    do_something DIRECTORY

that just prints out error messages and says "ok" without an error code
when the directory doesn't exist is a pretty crappy behavior.

The premise of this change was that we don't know what all the files in
the data directory might be, but we do know what the top-level directory
is, so we should treat that properly.



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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: pgsql: Remove special cases for ETXTBSY from new fsync'ing logic.
Следующее
От: Peter Eisentraut
Дата:
Сообщение: pgsql: Make Python tests more portable