Support syncing WAL log to disk using either fsync(), fdatasync(),
Tom Lane <tgl@sss.pgh.pa.us>
Support syncing WAL log to disk using either fsync(), fdatasync(), O_SYNC, or O_DSYNC (as available on a given platform). Add GUC parameter to control sync method. Also, add defense to XLogWrite to prevent it from going nuts if passed a target write position that's past the end of the buffers so far filled by XLogInsert.
Files
| Path | Change | +/− |
|---|---|---|
| doc/src/sgml/runtime.sgml | modified | +20 −3 |
| doc/src/sgml/wal.sgml | modified | +19 −10 |
| src/backend/access/transam/xlog.c | modified | +205 −26 |
| src/backend/utils/misc/guc.c | modified | +28 −22 |
| src/backend/utils/misc/postgresql.conf.sample | modified | +2 −0 |
| src/include/access/xlog.h | modified | +13 −1 |