Re: autovacuum process (PID ...) was terminated by signal 11

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Brian Hirt <bhirt(at)mobygames(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Subject: Re: autovacuum process (PID ...) was terminated by signal 11
Date: 2006-01-04 18:47:49
Message-ID: 4428.1136400469@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Brian Hirt <bhirt(at)mobygames(dot)com> writes:
> I was just writing to let you know I created an easily reproducible
> test case too, but I guess you don't need that now.

Does your test case agree with my description of the problem?
(If you're not sure, crank up log_min_messages and watch the log
to see what autovacuum does before it crashes.)

The problem I'm seeing seems to be that vacuum() exits with a
transaction started but no snapshot set (StartTransactionCommand will
leave ActiveSnapshot set to NULL), if it's in use_own_xacts mode.
autovac thinks it only has to set the snapshot once, but that's really
not the case given this behavior.

I'm unsure whether to fix this by adding a CopySnapshot operation right
in vacuum(), or in autovacuum.c. The former is probably cleaner but it
clutters vacuum.c with something only autovac really needs. Any
opinions?

> Also, if a patch is produced, I'd love to get a copy of it. We just
> upgraded our production servers to 8.1.1 this morning (this issue
> never came up during testing) and I'l like to get this in there
> because it's likely to happen again.

Definitely a big risk of that :-(. It'll be a one-liner patch in any
case, we just have to decide where ...

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Robert Osowiecki 2006-01-04 19:10:37 Re: BUG #2143: Indexes incorrectly created from database dump
Previous Message Robert Osowiecki 2006-01-04 18:40:06 Re: BUG #2143: Indexes incorrectly created from database dump