Skip site navigation (1) Skip section navigation (2)

Re: Bug #807: Sequence currupted on recovery after kill -9

From: Robert Hentosh <hentosh(at)io(dot)com>
To: mthomp(at)tierfleet(dot)com, <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: Bug #807: Sequence currupted on recovery after kill -9
Date: 2002-10-29 17:18:23
Message-ID: Pine.LNX.4.44.0210291115220.10093-100000@eris.io.com (view raw or flat)
Thread:
Lists: pgsql-bugs
On Tue, 29 Oct 2002 pgsql-bugs(at)postgresql(dot)org wrote:

> Matt Thompson (mthomp(at)tierfleet(dot)com) reports a bug with a severity of 2
> The lower the number the more severe it is.
> 
> Short Description
> Sequence currupted on recovery after kill -9
> 
> Long Description
> If you create a file with an implied sequence and do a couple of inserts, then do a kill -9, when you start up again, the sequence will have a corrupted next_value field.  In the example, the value of last_value is 4 before the kill -9 and 34 when it comes back up.
> 


The purpose of a sequence is not to insure that the numbers are 
consecutive, only to insure that they are unique. If you have failed 
inserts, you will see holes also.

I don't know off the top of my head how to do consecutive numbers.  Maybe 
only with a table lock.

- robert



In response to

Responses

pgsql-bugs by date

Next:From: Tom LaneDate: 2002-10-29 17:49:34
Subject: Re: Bug #807: Sequence currupted on recovery after kill -9
Previous:From: Darcy BuskermolenDate: 2002-10-29 16:38:55
Subject: Re: Bug #807: Sequence currupted on recovery after kill -9

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group