Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2014-03-12 Thread Heikki Linnakangas
On 03/12/2014 02:05 PM, Robert Haas wrote: On Wed, Mar 12, 2014 at 4:23 AM, Heikki Linnakangas wrote: The attached patch doesn't apply any more, but it looks like this issue still exists. Fixed. Did you forget to push? Yep. Pushed now. - Heikki -- Sent via pgsql-hackers mailing list (p

Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2014-03-12 Thread Robert Haas
On Wed, Mar 12, 2014 at 4:23 AM, Heikki Linnakangas wrote: >> The attached patch doesn't apply any more, but it looks like this >> issue still exists. > > Fixed. Did you forget to push? -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company -- Sent via pgs

Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2014-03-12 Thread Heikki Linnakangas
On 03/10/2014 09:44 PM, Robert Haas wrote: On Mon, Apr 30, 2012 at 1:34 PM, Noah Misch wrote: When GIN changes a metapage, we WAL-log its ex-header content and never use a backup block. This reduces WAL volume since the vast majority of the metapage is unused. However, ginRedoUpdateMetapage()

Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2014-03-10 Thread Robert Haas
On Mon, Apr 30, 2012 at 1:34 PM, Noah Misch wrote: > When GIN changes a metapage, we WAL-log its ex-header content and never use a > backup block. This reduces WAL volume since the vast majority of the metapage > is unused. However, ginRedoUpdateMetapage() only restores the WAL-logged > content

Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2012-05-03 Thread Tom Lane
Robert Haas writes: > Are you planning to commit Noah's patch? I wasn't intending to do so personally in the near future; I've got other things on my to-do list. I won't object if somebody else commits it though. regards, tom lane -- Sent via pgsql-hackers mailing list

Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2012-05-03 Thread Robert Haas
On Thu, May 3, 2012 at 12:16 AM, Tom Lane wrote: > Having said all that, I wasn't really arguing that this was a guaranteed > safe thing for us to rely on; just pointing out that it's quite likely > that the issue hasn't been seen in the field because of this type of > consideration. Well, we do

Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2012-05-02 Thread Tom Lane
Daniel Farina writes: > On Wed, May 2, 2012 at 6:06 PM, Noah Misch wrote: >> Can we indeed assume that all support-worthy filesystems align the start of >> every file to a physical sector? I know little about modern filesystem >> design, but these references leave me wary of that assumption: >>

Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2012-05-02 Thread Daniel Farina
On Wed, May 2, 2012 at 6:06 PM, Noah Misch wrote: > Can we indeed assume that all support-worthy filesystems align the start of > every file to a physical sector?  I know little about modern filesystem > design, but these references leave me wary of that assumption: > > http://www.mail-archive.com

Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2012-05-02 Thread Noah Misch
On Mon, Apr 30, 2012 at 02:35:20PM -0400, Tom Lane wrote: > Noah Misch writes: > > When GIN changes a metapage, we WAL-log its ex-header content and never use > > a > > backup block. This reduces WAL volume since the vast majority of the > > metapage > > is unused. However, ginRedoUpdateMetapa

Re: [HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2012-04-30 Thread Tom Lane
Noah Misch writes: > When GIN changes a metapage, we WAL-log its ex-header content and never use a > backup block. This reduces WAL volume since the vast majority of the metapage > is unused. However, ginRedoUpdateMetapage() only restores the WAL-logged > content if the metapage LSN predates the

[HACKERS] Torn page hazard in ginRedoUpdateMetapage()

2012-04-30 Thread Noah Misch
When GIN changes a metapage, we WAL-log its ex-header content and never use a backup block. This reduces WAL volume since the vast majority of the metapage is unused. However, ginRedoUpdateMetapage() only restores the WAL-logged content if the metapage LSN predates the WAL record LSN. If a metap