Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-09 Thread Heikki Linnakangas
While testing this, I noticed another serious bug in the OldSerXidSLRU handling: we never set the dirty-flag on any page. I believe the reason we haven't bumped into this in testing before is that when a new page is initialized, it's marked as dirty, so everything goes smoothly when we modify

Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-09 Thread Kevin Grittner
Heikki Linnakangas wrote: While testing this, I noticed another serious bug in the OldSerXidSLRU handling: we never set the dirty-flag on any page. Arg. I never noticed that there was such a thing, although in retrospect I should have suspected it and gone hunting for it. I believe the

Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-09 Thread Alvaro Herrera
Excerpts from Heikki Linnakangas's message of jue jun 09 04:56:41 -0400 2011: Fortunately the fix is very simple, we just need to set the page_dirty flag whenever we modify an slru page. But clearly this slru stuff needs more testing. It's pretty hard to write good repeatable test cases for

Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-09 Thread Kevin Grittner
Alvaro Herrera alvhe...@commandprompt.com wrote: Excerpts from Heikki Linnakangas's message of jue jun 09 04:56:41 -0400 2011: Fortunately the fix is very simple, we just need to set the page_dirty flag whenever we modify an slru page. But clearly this slru stuff needs more testing. It's

Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-09 Thread Heikki Linnakangas
On 08.06.2011 22:40, Kevin Grittner wrote: Heikki Linnakangasheikki.linnakan...@enterprisedb.com wrote: On 08.06.2011 03:28, Kevin Grittner wrote: We had a report of the subject message during testing a while back and attempted to address the issue. It can result in a LOG level message

Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-09 Thread Kevin Grittner
Heikki Linnakangas heikki.linnakan...@enterprisedb.com wrote: I've committed your patch for now. Thanks! I don't see it yet on the public git repo, nor on the -commiters list. I'll keep an eye out for it. as far as I can see it's harmless except for the small waste of disk space. We

Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-09 Thread Heikki Linnakangas
On 09.06.2011 21:15, Kevin Grittner wrote: Heikki Linnakangasheikki.linnakan...@enterprisedb.com wrote: I've committed your patch for now. Thanks! I don't see it yet on the public git repo, nor on the -commiters list. I'll keep an eye out for it. Oh, rats! Forgot to push.. Will do so

Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-09 Thread Kevin Grittner
Heikki Linnakangas heikki.linnakan...@enterprisedb.com wrote: I also fixed the broken warning logic. Please double-check that too when you get a chance. As usual, I like your code better than mine. I don't think my code was broken in the sense that it would generate different results than

Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-08 Thread Heikki Linnakangas
On 08.06.2011 03:28, Kevin Grittner wrote: We had a report of the subject message during testing a while back and attempted to address the issue. It can result in a LOG level message and the accumulation of files in the pg_serial SLRU subdirectory. We haven't seen a recurrence, until I hit it

Re: [HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-08 Thread Kevin Grittner
Heikki Linnakangas heikki.linnakan...@enterprisedb.com wrote: On 08.06.2011 03:28, Kevin Grittner wrote: We had a report of the subject message during testing a while back and attempted to address the issue. It can result in a LOG level message and the accumulation of files in the pg_serial

[HACKERS] could not truncate directory pg_serial: apparent wraparound

2011-06-07 Thread Kevin Grittner
We had a report of the subject message during testing a while back and attempted to address the issue. It can result in a LOG level message and the accumulation of files in the pg_serial SLRU subdirectory. We haven't seen a recurrence, until I hit it during testing of the just-posted patch for