Re: Commit(?) overhead

Поиск
Список
Период
Сортировка
От Duncan Kinnear
Тема Re: Commit(?) overhead
Дата
Msg-id 1463709613.1724361.1554849753257.JavaMail.zimbra@mccarthy.co.nz
обсуждение исходный текст
Ответ на Re: Commit(?) overhead  (Andres Freund <andres@anarazel.de>)
Ответы Re: Commit(?) overhead  (Laurenz Albe <laurenz.albe@cybertec.at>)
Список pgsql-performance
----- On 10 Apr, 2019, at 10:23 AM, Andres Freund andres@anarazel.de wrote:

> On 2019-04-09 17:12:27 -0500, Justin Pryzby wrote:
>> You could test that's the issue by comparing with fsync=off (please read what
>> that means and don't run your production cluster like that).
>> https://www.postgresql.org/docs/current/runtime-config-wal.html#GUC-FSYNC
> 
> I suggest testing it with synchronous_commit=off instead. That's about
> as fast for this type of workload, doesn't have cluster corruption
> issues, the window of a transaction not persisting in case of a crash is
> very small, and it can just set by any user in individual sessions.

Bingo! Adding 'SET LOCAL synchronous_commit TO OFF;' to my 'BEGIN; UPDATE ....; COMMIT;' block has given me sub-1ms
timings!Thanks Andres.
 

I'll probably leave the setting as that on my local machine. The option appears to be relatively safe, but my machine
isjust a dev test machine anyway.
 


Regards, 

Duncan Kinnear 



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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: Commit(?) overhead
Следующее
От: Daulat Ram
Дата:
Сообщение: PostgreSQL upgrade.