| От | Tom Lane |
|---|---|
| Тема | Re: Cost of XLogInsert CRC calculations |
| Дата | |
| Msg-id | 17708.1117652628@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: Cost of XLogInsert CRC calculations (Greg Stark <gsstark@mit.edu>) |
| Список | pgsql-hackers |
Greg Stark <gsstark@mit.edu> writes:
> It occurs to me that at least on some OSes the WAL logs are being synced with
> O_SYNC or its ilk. In those cases the writes should be guaranteed to be
> written out in the order postgres wrote them. So if the tail end of the WAL
> entry is there (is there any sort of footer?) then the entire entry must be
> there. In that case is there any need to calculate the CRC at all?
Sure. How else do you know that the entry is all there *and is valid*?
There's no "footer", and if there were it might still be garbage (eg
left over from a prior cycle).
Also, I doubt that O_SYNC could do anything to guarantee write order of
the individual sectors within a page.
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера