Re: [GENERAL] Replication and fsync

2013-10-29 Thread Kevin Grittner
Tomas Vondra wrote: > I think it's safe as long as you don't try to reuse the cluster > after a crash (be it due to OS error, power outage, ...). If the > primary crashes for any reasons, you have to start from scratch, > otherwise there might be silent corruption as you've described. I agree. 

Re: [GENERAL] Replication and fsync

2013-10-26 Thread Tomas Vondra
Hi, On 24.10.2013 23:18, Alban Hertroys wrote: > On Oct 24, 2013, at 18:10, maillis...@gmail.com wrote: > >> Thank you for the answers. I'm still confused. If fsync is not >> replicated to the slave, then how is replication affected by a >> corrupt master? If the master dies and there's a commit

Re: [GENERAL] Replication and fsync

2013-10-25 Thread Albe Laurenz
DDT wrote: > According to manual, when you set "synchronous_commit" to on, the transaction > commits will wait until > master and slave flush the commit record of transaction to the physical > storage, so I think even if > turn off the fsync on master is safe for data consistency and data will no

Re: [GENERAL] Replication and fsync

2013-10-24 Thread DDT
wal.html#GUC-FSYNC fsync and synchronous_commit http://www.postgresql.org/docs/current/static/wal-intro.html -- Original -- From: "maillists0";; Date: Thu, Oct 24, 2013 09:39 AM To: "pgsql-general"; Subject: [GENERAL] Replication and fsyn

Re: [GENERAL] Replication and fsync

2013-10-24 Thread Alban Hertroys
On Oct 24, 2013, at 18:10, maillis...@gmail.com wrote: > Thank you for the answers. I'm still confused. If fsync is not replicated to > the slave, then how is replication affected by a corrupt master? If the > master dies and there's a commit recorded in the wal log that didn't actually > happe

Re: [GENERAL] Replication and fsync

2013-10-24 Thread Jeff Janes
On Wed, Oct 23, 2013 at 6:39 PM, wrote: > Newb question. > > I'm running 9.1 with a slave using streaming replication. A coworker wants > to turn off fsync on the master and insists that the slave will still be in > a usable state if there is a failure on the master. > This would only be safe if

Re: [GENERAL] Replication and fsync

2013-10-24 Thread maillists0
Thank you for the answers. I'm still confused. If fsync is not replicated to the slave, then how is replication affected by a corrupt master? If the master dies and there's a commit recorded in the wal log that didn't actually happen, wouldn't the slave still be expected to be in a sane state, with

Re: [GENERAL] Replication and fsync

2013-10-24 Thread Alban Hertroys
On 24 October 2013 15:04, Fujii Masao wrote: > On Thu, Oct 24, 2013 at 10:39 AM, wrote: >> Am I wrong? If I'm wrong, is there still danger to the slave >> in this kind of setup? > > No, I think. Corruption due to fsync being off on the master will be replicated to the slave, or - if corruption

Re: [GENERAL] Replication and fsync

2013-10-24 Thread Fujii Masao
On Thu, Oct 24, 2013 at 10:39 AM, wrote: > Newb question. > > I'm running 9.1 with a slave using streaming replication. A coworker wants > to turn off fsync on the master and insists that the slave will still be in > a usable state if there is a failure on the master. We all know that turning > o

[GENERAL] Replication and fsync

2013-10-23 Thread maillists0
Newb question. I'm running 9.1 with a slave using streaming replication. A coworker wants to turn off fsync on the master and insists that the slave will still be in a usable state if there is a failure on the master. We all know that turning off fsync is a bad idea, but I was under the impression