Re: [HACKERS] Quick idea for reducing VACUUM contention

2007-07-31 Thread Decibel!
On Jul 30, 2007, at 1:47 PM, Alvaro Herrera wrote: Jim Nasby wrote: On Jul 27, 2007, at 1:49 AM, Alvaro Herrera wrote: ITAGAKI Takahiro wrote: It would be cool if we could do something like sweep a range of pages, initiate IO for those that are not in shared buffers, and while that is runni

Re: [HACKERS] Quick idea for reducing VACUUM contention

2007-07-31 Thread Alvaro Herrera
Decibel! wrote: > On Jul 30, 2007, at 8:00 PM, Alvaro Herrera wrote: >> ITAGAKI Takahiro wrote: >>> Alvaro Herrera <[EMAIL PROTECTED]> wrote: > I think we might need additional "freezing-xmax" operations to avoid > XID-wraparound in the first path of vacuum, though it hardly occurs. >>

Re: [HACKERS] Quick idea for reducing VACUUM contention

2007-07-31 Thread Decibel!
On Jul 30, 2007, at 8:00 PM, Alvaro Herrera wrote: ITAGAKI Takahiro wrote: Alvaro Herrera <[EMAIL PROTECTED]> wrote: I think we might need additional "freezing-xmax" operations to avoid XID-wraparound in the first path of vacuum, though it hardly occurs. I'm not sure I follow. Can you ela

Re: [HACKERS] Quick idea for reducing VACUUM contention

2007-07-30 Thread Alvaro Herrera
ITAGAKI Takahiro wrote: > > Alvaro Herrera <[EMAIL PROTECTED]> wrote: > > > > I think we might need additional "freezing-xmax" operations to avoid > > > XID-wraparound in the first path of vacuum, though it hardly occurs. > > > > I'm not sure I follow. Can you elaborate? Do you mean storing a

Re: [HACKERS] Quick idea for reducing VACUUM contention

2007-07-30 Thread ITAGAKI Takahiro
Alvaro Herrera <[EMAIL PROTECTED]> wrote: > > I think we might need additional "freezing-xmax" operations to avoid > > XID-wraparound in the first path of vacuum, though it hardly occurs. > > I'm not sure I follow. Can you elaborate? Do you mean storing a > separate relfrozenxmax for each tabl

Re: [HACKERS] Quick idea for reducing VACUUM contention

2007-07-30 Thread Alvaro Herrera
Jim Nasby wrote: > On Jul 27, 2007, at 1:49 AM, Alvaro Herrera wrote: >> ITAGAKI Takahiro wrote: >>> "Simon Riggs" <[EMAIL PROTECTED]> wrote: >>> Read the heap blocks in sequence, but make a conditional lock for cleanup on each block. If we don't get it, sleep, then try again when we

Re: [HACKERS] Quick idea for reducing VACUUM contention

2007-07-28 Thread Jim Nasby
On Jul 27, 2007, at 1:49 AM, Alvaro Herrera wrote: ITAGAKI Takahiro wrote: "Simon Riggs" <[EMAIL PROTECTED]> wrote: Read the heap blocks in sequence, but make a conditional lock for cleanup on each block. If we don't get it, sleep, then try again when we wake up. If we fail the second time,

Re: [HACKERS] Quick idea for reducing VACUUM contention

2007-07-27 Thread Alvaro Herrera
ITAGAKI Takahiro wrote: > "Simon Riggs" <[EMAIL PROTECTED]> wrote: > > > Read the heap blocks in sequence, but make a conditional lock for > > cleanup on each block. If we don't get it, sleep, then try again when we > > wake up. If we fail the second time, just skip the block completely. It would

Re: [HACKERS] Quick idea for reducing VACUUM contention

2007-07-26 Thread ITAGAKI Takahiro
"Simon Riggs" <[EMAIL PROTECTED]> wrote: > Read the heap blocks in sequence, but make a conditional lock for > cleanup on each block. If we don't get it, sleep, then try again when we > wake up. If we fail the second time, just skip the block completely. When we allow some skips in removing dead