Thread: Re: [QUESTIONS] MySQL benchmark page

Re: [QUESTIONS] MySQL benchmark page

From
The Hermit Hacker
Date:

Nobody likes to take the time to move discussions, do they?  And ya, I'm
about as guilty *sigh*

Move to pgsql-hackers@postgresql.org...


On Tue, 3 Feb 1998, Herouth Maoz wrote:

> At 15:01 +0200 on 2/2/98, The Hermit Hacker wrote:
>
> I think the garbage collection should be separated from the statistics.
> Garbage collection needs a write lock, statistics only a read lock. If they
> are not done at the same time, the various tables would be locked for
> shorter periods.

    Hrmmmm...good point, I think.  Bruce?  Vadim?  When vacuum'ng a
large table, how much time is spend 'garbage collecting' vs 'statistics'?
I thought that 'vacuum analyze' *was* the statistics aspect of it?  Where
just 'vacuum' was only garbage collection...?



Re: [HACKERS] Re: [QUESTIONS] MySQL benchmark page

From
Bruce Momjian
Date:
>
>
>
> Nobody likes to take the time to move discussions, do they?  And ya, I'm
> about as guilty *sigh*
>
> Move to pgsql-hackers@postgresql.org...
>
>
> On Tue, 3 Feb 1998, Herouth Maoz wrote:
>
> > At 15:01 +0200 on 2/2/98, The Hermit Hacker wrote:
> >
> > I think the garbage collection should be separated from the statistics.
> > Garbage collection needs a write lock, statistics only a read lock. If they
> > are not done at the same time, the various tables would be locked for
> > shorter periods.
>
>     Hrmmmm...good point, I think.  Bruce?  Vadim?  When vacuum'ng a
> large table, how much time is spend 'garbage collecting' vs 'statistics'?
> I thought that 'vacuum analyze' *was* the statistics aspect of it?  Where
> just 'vacuum' was only garbage collection...?

This is correct.  Vacuum is fast, vacuum analyze is pretty slow.  We
could separate them, I guess, and that would eliminate the write-lock
and be only a readlock.

--
Bruce Momjian
maillist@candle.pha.pa.us

Re: [HACKERS] Re: [QUESTIONS] MySQL benchmark page

From
The Hermit Hacker
Date:
On Tue, 3 Feb 1998, Bruce Momjian wrote:

> > On Tue, 3 Feb 1998, Herouth Maoz wrote:
> >
> > > At 15:01 +0200 on 2/2/98, The Hermit Hacker wrote:
> > >
> > > I think the garbage collection should be separated from the statistics.
> > > Garbage collection needs a write lock, statistics only a read lock. If they
> > > are not done at the same time, the various tables would be locked for
> > > shorter periods.
> >
> >     Hrmmmm...good point, I think.  Bruce?  Vadim?  When vacuum'ng a
> > large table, how much time is spend 'garbage collecting' vs 'statistics'?
> > I thought that 'vacuum analyze' *was* the statistics aspect of it?  Where
> > just 'vacuum' was only garbage collection...?
>
> This is correct.  Vacuum is fast, vacuum analyze is pretty slow.  We
> could separate them, I guess, and that would eliminate the write-lock
> and be only a readlock.

    Possible to slip it in for v6.3?  Would make it so that an analyze
could be done nightly, to keep statistics up, and then a vacuum once a
week or so just for garbage collection...?



Re: [HACKERS] Re: [QUESTIONS] MySQL benchmark page

From
Bruce Momjian
Date:
> > This is correct.  Vacuum is fast, vacuum analyze is pretty slow.  We
> > could separate them, I guess, and that would eliminate the write-lock
> > and be only a readlock.
>
>     Possible to slip it in for v6.3?  Would make it so that an analyze
> could be done nightly, to keep statistics up, and then a vacuum once a
> week or so just for garbage collection...?

When I added analyze, I did not understand the issues, so I was able to
work from Vadim's code in vacuum.  I put it on the TODO list.  Don't
know if it can make 6.3.  I am working on cleaning up the cacheoffset
code right now.

--
Bruce Momjian
maillist@candle.pha.pa.us