vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| The following patch disables WAL backup pages when fsync is off. -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 359-1001 + If your life is a hard drive, | 13 Roberts Road + Christ can be your backup. | Newtown Square, Pennsylvania 19073 Index: src/backend/access/transam/xlog.c ================================================== ================= RCS file: /cvsroot/pgsql/src/backend/access/transam/xlog.c,v retrieving revision 1.205 diff -c -c -r1.205 xlog.c *** src/backend/access/transam/xlog.c 30 Jun 2005 00:00:50 -0000 1.205 --- src/backend/access/transam/xlog.c 3 Jul 2005 02:52:57 -0000 *************** *** 593,599 **** { /* OK, put it in this slot */ dtbuf[i] = rdt->buffer; ! if (XLogCheckBuffer(rdt, &(dtbuf_lsn[i]), &(dtbuf_xlg[i]))) { dtbuf_bkp[i] = true; rdt->data = NULL; --- 593,601 ---- { /* OK, put it in this slot */ dtbuf[i] = rdt->buffer; ! /* If fsync is off, no need to backup pages. */ ! if (enableFsync && ! XLogCheckBuffer(rdt, &(dtbuf_lsn[i]), &(dtbuf_xlg[i]))) { dtbuf_bkp[i] = true; rdt->data = NULL; ---------------------------(end of broadcast)--------------------------- TIP 6: Have you searched our list archives? http://archives.postgresql.org |
| |||
| Bruce Momjian <pgman@candle.pha.pa.us> writes: > The following patch disables WAL backup pages when fsync is off. This is a good idea why? regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 2: you can get off all lists at once with the unregister command (send "unregister YourEmailAddressHere" to majordomo@postgresql.org) |
| ||||
| Tom Lane wrote: > Bruce Momjian <pgman@candle.pha.pa.us> writes: > > The following patch disables WAL backup pages when fsync is off. > > This is a good idea why? There is no need to write backup pages if fsync is off. Our TODO has: * Turn off after-change writes if fsync is disabled If fsync is off, there is no purpose in writing full pages to WAL Basically, with fsync off, you are saying you don't care about crash recovery, so why write those pages? -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 359-1001 + If your life is a hard drive, | 13 Roberts Road + Christ can be your backup. | Newtown Square, Pennsylvania 19073 ---------------------------(end of broadcast)--------------------------- TIP 7: don't forget to increase your free space map settings |