pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
VACUUM Error
27+ messages / 13 participants
[nested] [flat]

* VACUUM Error
@ 2000-09-05 08:26 Hoosain Madhi <MADHIH@vodacom.co.za>
  0 siblings, 0 replies; 27+ messages in thread

From: Hoosain Madhi @ 2000-09-05 08:26 UTC (permalink / raw)
  To: pgsql-general

I tried to vaccum a table but get the following error :

NOTICE : Child itemid in update-chain marked as unused - can't continue
vc_repair frag.
VACUUM

What is the problem, and how do I over come it??

Thanks 

Hoosain Madhi	
Bsc. Engineering Elec.
Switching Engineering
VODACOM CORPORATE PARK
Tel	:	+27 11 653 5030
Fax	:	+27 11 653 5941




^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* vacuum error
@ 2003-03-12 11:48 Eric Cholet <cholet@logilune.com>
  2003-03-12 16:24 ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 1 reply; 27+ messages in thread

From: Eric Cholet @ 2003-03-12 11:48 UTC (permalink / raw)
  To: pgsql-general

I get this error when vacuuming a table:

PANIC:  open of /usr/local/pgsql/data/pg_clog/0005 failed: No such file or 
directory

using 7.3.2.


Any pointers?

--
Eric Cholet




^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2003-03-12 11:48 vacuum error Eric Cholet <cholet@logilune.com>
@ 2003-03-12 16:24 ` Tom Lane <tgl@sss.pgh.pa.us>
  2003-03-12 16:36   ` Re: vacuum error Eric Cholet <cholet@logilune.com>
  0 siblings, 1 reply; 27+ messages in thread

From: Tom Lane @ 2003-03-12 16:24 UTC (permalink / raw)
  To: Eric Cholet <cholet@logilune.com>; +Cc: pgsql-general

Eric Cholet <cholet@logilune.com> writes:
> I get this error when vacuuming a table:
> PANIC:  open of /usr/local/pgsql/data/pg_clog/0005 failed: No such file or 
> directory
> using 7.3.2.

What file names are actually present in pg_clog/ ?

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2003-03-12 11:48 vacuum error Eric Cholet <cholet@logilune.com>
  2003-03-12 16:24 ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
@ 2003-03-12 16:36   ` Eric Cholet <cholet@logilune.com>
  2003-03-12 16:40     ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 1 reply; 27+ messages in thread

From: Eric Cholet @ 2003-03-12 16:36 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; +Cc: pgsql-general

--On Wednesday, March 12, 2003 11:24:43 -0500 Tom Lane <tgl@sss.pgh.pa.us> 
wrote:

> Eric Cholet <cholet@logilune.com> writes:
>> I get this error when vacuuming a table:
>> PANIC:  open of /usr/local/pgsql/data/pg_clog/0005 failed: No such file
>> or  directory
>> using 7.3.2.
>
> What file names are actually present in pg_clog/ ?

0000    0001    0002    0003    0004

Thanks,

--
Eric Cholet




^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2003-03-12 11:48 vacuum error Eric Cholet <cholet@logilune.com>
  2003-03-12 16:24 ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
  2003-03-12 16:36   ` Re: vacuum error Eric Cholet <cholet@logilune.com>
@ 2003-03-12 16:40     ` Tom Lane <tgl@sss.pgh.pa.us>
  2003-03-12 18:18       ` Re: vacuum error Eric Cholet <cholet@logilune.com>
  0 siblings, 1 reply; 27+ messages in thread

From: Tom Lane @ 2003-03-12 16:40 UTC (permalink / raw)
  To: Eric Cholet <cholet@logilune.com>; +Cc: pgsql-general

Eric Cholet <cholet@logilune.com> writes:
> I get this error when vacuuming a table:
> PANIC:  open of /usr/local/pgsql/data/pg_clog/0005 failed: No such file
> or  directory
> using 7.3.2.
>> 
>> What file names are actually present in pg_clog/ ?

> 0000    0001    0002    0003    0004

Hm, interesting.  You had any crashes recently?  Could you show us an
"ls -l" listing of those clog files (I want to know their sizes and
mod dates...)

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2003-03-12 11:48 vacuum error Eric Cholet <cholet@logilune.com>
  2003-03-12 16:24 ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
  2003-03-12 16:36   ` Re: vacuum error Eric Cholet <cholet@logilune.com>
  2003-03-12 16:40     ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
@ 2003-03-12 18:18       ` Eric Cholet <cholet@logilune.com>
  2003-03-12 18:32         ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 1 reply; 27+ messages in thread

From: Eric Cholet @ 2003-03-12 18:18 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; +Cc: pgsql-general

--On Wednesday, March 12, 2003 11:40:39 -0500 Tom Lane <tgl@sss.pgh.pa.us> 
wrote:

> Eric Cholet <cholet@logilune.com> writes:
>> I get this error when vacuuming a table:
>> PANIC:  open of /usr/local/pgsql/data/pg_clog/0005 failed: No such file
>> or  directory
>> using 7.3.2.
>>>
>>> What file names are actually present in pg_clog/ ?
>
>> 0000    0001    0002    0003    0004
>
> Hm, interesting.  You had any crashes recently?

Yes, I've had many crashes. Always when vacuuming a largish (500 Mb) table.
I suspected faulty hardware, so I dropped and recreated the tables
several times.

> Could you show us an
> "ls -l" listing of those clog files (I want to know their sizes and
> mod dates...)

-rw-------  1 postgres  wheel  262144 Dec 30 03:49 0000
-rw-------  1 postgres  wheel  262144 Jan  2 19:12 0001
-rw-------  1 postgres  wheel  262144 Feb 12 12:30 0002
-rw-------  1 postgres  wheel  262144 Mar 10 06:51 0003
-rw-------  1 postgres  wheel  253952 Mar 12 17:53 0004

Thanks,

--
Eric Cholet




^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2003-03-12 11:48 vacuum error Eric Cholet <cholet@logilune.com>
  2003-03-12 16:24 ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
  2003-03-12 16:36   ` Re: vacuum error Eric Cholet <cholet@logilune.com>
  2003-03-12 16:40     ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
  2003-03-12 18:18       ` Re: vacuum error Eric Cholet <cholet@logilune.com>
@ 2003-03-12 18:32         ` Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 27+ messages in thread

From: Tom Lane @ 2003-03-12 18:32 UTC (permalink / raw)
  To: Eric Cholet <cholet@logilune.com>; +Cc: pgsql-general

Eric Cholet <cholet@logilune.com> writes:
> I get this error when vacuuming a table:
> PANIC:  open of /usr/local/pgsql/data/pg_clog/0005 failed: No such file
> or  directory
> using 7.3.2.

>> Hm, interesting.  You had any crashes recently?

> Yes, I've had many crashes. Always when vacuuming a largish (500 Mb) table.
> I suspected faulty hardware, so I dropped and recreated the tables
> several times.

Did that help?  What were the crash symptoms exactly --- are you talking
about previous occurrences of this same error message, or other things?
Anything interesting in the postmaster's stderr log?

>> Could you show us an
>> "ls -l" listing of those clog files (I want to know their sizes and
>> mod dates...)

> -rw-------  1 postgres  wheel  262144 Dec 30 03:49 0000
> -rw-------  1 postgres  wheel  262144 Jan  2 19:12 0001
> -rw-------  1 postgres  wheel  262144 Feb 12 12:30 0002
> -rw-------  1 postgres  wheel  262144 Mar 10 06:51 0003
> -rw-------  1 postgres  wheel  253952 Mar 12 17:53 0004

You seem to be still at least several tens of thousands of transactions
away from actually needing an 0005 clog segment.  (It'd be worth your
time to run pg_controldata and verify that the next transaction ID
counter is still short of 5meg, ie 5242880.)

I'm guessing that the problem is data corruption in the table that you
are vacuuming when you get the error.  If you're lucky it's just one row
broken with a bogus xmin (or xmax) transaction ID.

What you can do is manually create an 0005 segment file.  Make sure it
contains exactly 262144 zero bytes (dd from /dev/zero may help here).
Give it the same ownership and permissions as the existing files.  Then,
when you vacuum, the broken row will look like it came from a failed
transaction, and it should disappear automatically.

But you'd better look into the root cause of the problem.  Have you run
memory and disk diagnostics lately?

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Vacuum Error
@ 2004-01-12 18:48 Dave Smith <dave.smith@candata.com>
  2004-01-12 19:25 ` Re: Vacuum Error Martin Marques <martin@bugs.unl.edu.ar>
  2004-01-12 22:31 ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 2 replies; 27+ messages in thread

From: Dave Smith @ 2004-01-12 18:48 UTC (permalink / raw)
  To: pgsql-general

I am running 7.2 and when doing a vacuum I am getting the following
error....

ERROR:  Cannot insert a duplicate key into unique index
pg_statistic_relid_att_index


Where do I start to fix this?

-- 
Dave Smith
CANdata Systems Ltd
416-493-9020




^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: Vacuum Error
  2004-01-12 18:48 Vacuum Error Dave Smith <dave.smith@candata.com>
@ 2004-01-12 19:25 ` Martin Marques <martin@bugs.unl.edu.ar>
  1 sibling, 0 replies; 27+ messages in thread

From: Martin Marques @ 2004-01-12 19:25 UTC (permalink / raw)
  To: Dave Smith <dave.smith@candata.com>; +Cc: pgsql-general

Mensaje citado por Dave Smith <dave.smith@candata.com>:

> I am running 7.2 and when doing a vacuum I am getting the following
> error....
> 
> ERROR:  Cannot insert a duplicate key into unique index
> pg_statistic_relid_att_index
> 
> 
> Where do I start to fix this?

I'm not 100% about this working, but I would try to rebuild the index:

REINDEX pg_statistic_relid_att_index

You have to be the postgres superuser to do this.

-- 
select 'mmarques' || '@' || 'unl.edu.ar' AS email;
---------------------------------------------------------
Martín Marqués          |   Programador, DBA
Centro de Telemática	|     Administrador
               Universidad Nacional
                    del Litoral
---------------------------------------------------------



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: Vacuum Error
  2004-01-12 18:48 Vacuum Error Dave Smith <dave.smith@candata.com>
@ 2004-01-12 22:31 ` Tom Lane <tgl@sss.pgh.pa.us>
  2004-01-12 22:27   ` Re: Vacuum Error scott.marlowe <scott.marlowe@ihs.com>
  2004-01-12 23:00   ` Re: Vacuum Error Andrew Bartley <abartley@evolvosystems.com>
  1 sibling, 2 replies; 27+ messages in thread

From: Tom Lane @ 2004-01-12 22:31 UTC (permalink / raw)
  To: Dave Smith <dave.smith@candata.com>; +Cc: pgsql-general

Dave Smith <dave.smith@candata.com> writes:
> I am running 7.2 and when doing a vacuum I am getting the following
> error....

> ERROR:  Cannot insert a duplicate key into unique index
> pg_statistic_relid_att_index

Hmm, if it were a slightly newer version I'd be interested in how you
got into this state, but since it's 7.2 I'll write it off as an old
bug.  The easiest way out, seeing that pg_statistic is all derived data,
is just
	DELETE FROM pg_statistic;
	(possibly VACUUM FULL pg_statistic here)
	re-ANALYZE everything
You should try the nearby suggestion to REINDEX first, but I'm betting
that that doesn't help.

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: Vacuum Error
  2004-01-12 18:48 Vacuum Error Dave Smith <dave.smith@candata.com>
  2004-01-12 22:31 ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
@ 2004-01-12 22:27   ` scott.marlowe <scott.marlowe@ihs.com>
  2004-01-12 22:57     ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
  1 sibling, 1 reply; 27+ messages in thread

From: scott.marlowe @ 2004-01-12 22:27 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; +Cc: Dave Smith <dave.smith@candata.com>; pgsql-general

On Mon, 12 Jan 2004, Tom Lane wrote:

> Dave Smith <dave.smith@candata.com> writes:
> > I am running 7.2 and when doing a vacuum I am getting the following
> > error....
> 
> > ERROR:  Cannot insert a duplicate key into unique index
> > pg_statistic_relid_att_index
> 
> Hmm, if it were a slightly newer version I'd be interested in how you
> got into this state, but since it's 7.2 I'll write it off as an old
> bug.  The easiest way out, seeing that pg_statistic is all derived data,
> is just
> 	DELETE FROM pg_statistic;
> 	(possibly VACUUM FULL pg_statistic here)
> 	re-ANALYZE everything
> You should try the nearby suggestion to REINDEX first, but I'm betting
> that that doesn't help.

Didn't this happen with parallel vacuum / analyzes running in the olden 
days?




^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: Vacuum Error
  2004-01-12 18:48 Vacuum Error Dave Smith <dave.smith@candata.com>
  2004-01-12 22:31 ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
  2004-01-12 22:27   ` Re: Vacuum Error scott.marlowe <scott.marlowe@ihs.com>
@ 2004-01-12 22:57     ` Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 27+ messages in thread

From: Tom Lane @ 2004-01-12 22:57 UTC (permalink / raw)
  To: scott.marlowe <scott.marlowe@ihs.com>; +Cc: Dave Smith <dave.smith@candata.com>; pgsql-general

"scott.marlowe" <scott.marlowe@ihs.com> writes:
>> Dave Smith <dave.smith@candata.com> writes:
>>> I am running 7.2 and when doing a vacuum I am getting the following
>>> error....
>> 
>>> ERROR:  Cannot insert a duplicate key into unique index
>>> pg_statistic_relid_att_index

> Didn't this happen with parallel vacuum / analyzes running in the olden 
> days?

I don't think it could happen in 7.2, because that release took
ExclusiveLock on pg_statistic while inserting rows.

Later releases use a weaker lock (to permit concurrent ANALYZE of
different tables) and are subject to "concurrent update" errors if
you try to run two ANALYZEs of the same table at the same time.
But it doesn't sound like Dave is doing that, anyway.

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: Vacuum Error
  2004-01-12 18:48 Vacuum Error Dave Smith <dave.smith@candata.com>
  2004-01-12 22:31 ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
@ 2004-01-12 23:00   ` Andrew Bartley <abartley@evolvosystems.com>
  2004-01-12 23:20     ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
  1 sibling, 1 reply; 27+ messages in thread

From: Andrew Bartley @ 2004-01-12 23:00 UTC (permalink / raw)
  To: pgsql-general

I believe this error usually comes about due to OID wrapping.

I have experienced this error many times.  But not once since I changed all
tables definitions to "without oids".

The Fix Tom has suggested bellow is only temporary.  You will need to back
up your data base and reload.  The long term solution is to change every
table to "without oids", that is if your application is not using them.

The way I did it was to edit the output of PG_DUMP and make a global change
to the text changing every create table statement to include "without oids".
If any of your functions or client side code use temp tables, they also need
changing.

The longer you leave it the worse it gets.

Good luck

Thanks

Andrew Bartley

-----Original Message-----
From: pgsql-general-owner@postgresql.org
[mailto:pgsql-general-owner@postgresql.org]On Behalf Of Tom Lane
Sent: Tuesday, 13 January 2004 9:31 AM
To: Dave Smith
Cc: pgsql-general@postgresql.org
Subject: Re: [GENERAL] Vacuum Error


Dave Smith <dave.smith@candata.com> writes:
> I am running 7.2 and when doing a vacuum I am getting the following
> error....

> ERROR:  Cannot insert a duplicate key into unique index
> pg_statistic_relid_att_index

Hmm, if it were a slightly newer version I'd be interested in how you
got into this state, but since it's 7.2 I'll write it off as an old
bug.  The easiest way out, seeing that pg_statistic is all derived data,
is just
	DELETE FROM pg_statistic;
	(possibly VACUUM FULL pg_statistic here)
	re-ANALYZE everything
You should try the nearby suggestion to REINDEX first, but I'm betting
that that doesn't help.

			regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings






^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: Vacuum Error
  2004-01-12 18:48 Vacuum Error Dave Smith <dave.smith@candata.com>
  2004-01-12 22:31 ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
  2004-01-12 23:00   ` Re: Vacuum Error Andrew Bartley <abartley@evolvosystems.com>
@ 2004-01-12 23:20     ` Tom Lane <tgl@sss.pgh.pa.us>
  2004-01-12 23:59       ` Re: Vacuum Error Kragen Sitaker <kragen+pgsql@airwave.com>
  0 siblings, 1 reply; 27+ messages in thread

From: Tom Lane @ 2004-01-12 23:20 UTC (permalink / raw)
  To: abartley@evolvosystems.com; +Cc: pgsql-general

"Andrew Bartley" <abartley@evolvosystems.com> writes:
> I believe this error usually comes about due to OID wrapping.

No; an OID collision would have occurred when you tried to create a
table.  If two tables are present in pg_class then they have different
OIDs, and shouldn't have any conflicts in pg_statistic.

Since my last message I've thought of a possibly plausible explanation:
the bt_moveright bug that was isolated just a few months ago.  If two
backends were analyzing some tables (not necessarily the same table) at
the same time, and one of them caused the first root-page split in
pg_statistic_relid_att_index, it would be possible for the other one to
miss spotting an existing row for the OID/attnum it wanted to insert.
I think this could lead to two valid entries for the same OID/attnum in
pg_statistic, and consequently a persistent error on every subsequent
attempt to analyze that table.

This seems moderately plausible because pg_statistic_relid_att_index
would fit in a single btree page up till about 300-400 entries, which
is about right for a moderate-sized database (I see 299 pg_statistic
entries in the current regression database, for example).  First split
could easily happen in a database that had been running for awhile.

The relevant CVS log entry is

2003-07-29 18:18  tgl

	* src/backend/access/nbtree/: nbtsearch.c (REL7_3_STABLE),
	nbtsearch.c (REL7_2_STABLE), nbtsearch.c: Fix longstanding error in
	_bt_search(): should moveright at top of loop not bottom. 
	Otherwise we fail to moveright when the root page was split while
	we were "in flight" to it.  This is not a significant problem when
	the root is above the leaf level, but if the root was also a leaf
	(ie, a single-page index just got split) we may return the wrong
	leaf page to the caller, resulting in failure to find a key that is
	in fact present.  Bug has existed at least since 7.1, probably
	forever.

(Note that although the patch was committed into 7.2 series, there has
been no 7.2 release since then.  You could pull REL7_2_STABLE tip if you
wanted to build a 7.2-series server with this fix in place.)

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: Vacuum Error
  2004-01-12 18:48 Vacuum Error Dave Smith <dave.smith@candata.com>
  2004-01-12 22:31 ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
  2004-01-12 23:00   ` Re: Vacuum Error Andrew Bartley <abartley@evolvosystems.com>
  2004-01-12 23:20     ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
@ 2004-01-12 23:59       ` Kragen Sitaker <kragen+pgsql@airwave.com>
  2004-01-13 04:43         ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 1 reply; 27+ messages in thread

From: Kragen Sitaker @ 2004-01-12 23:59 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; +Cc: abartley@evolvosystems.com; pgsql-general

On Mon, Jan 12, 2004 at 06:20:23PM -0500, Tom Lane wrote:
> "Andrew Bartley" <abartley@evolvosystems.com> writes:
> > I believe this error usually comes about due to OID wrapping.
> 
> No; an OID collision would have occurred when you tried to create a
> table.  If two tables are present in pg_class then they have different
> OIDs, and shouldn't have any conflicts in pg_statistic.

How would that OID collision manifest?  Do you think the error message
might look similar?



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: Vacuum Error
  2004-01-12 18:48 Vacuum Error Dave Smith <dave.smith@candata.com>
  2004-01-12 22:31 ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
  2004-01-12 23:00   ` Re: Vacuum Error Andrew Bartley <abartley@evolvosystems.com>
  2004-01-12 23:20     ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
  2004-01-12 23:59       ` Re: Vacuum Error Kragen Sitaker <kragen+pgsql@airwave.com>
@ 2004-01-13 04:43         ` Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 27+ messages in thread

From: Tom Lane @ 2004-01-13 04:43 UTC (permalink / raw)
  To: Kragen Sitaker <kragen+pgsql@airwave.com>; +Cc: abartley@evolvosystems.com; pgsql-general

Kragen Sitaker <kragen+pgsql@airwave.com> writes:
> On Mon, Jan 12, 2004 at 06:20:23PM -0500, Tom Lane wrote:
>> No; an OID collision would have occurred when you tried to create a
>> table.  If two tables are present in pg_class then they have different
>> OIDs, and shouldn't have any conflicts in pg_statistic.

> How would that OID collision manifest?  Do you think the error message
> might look similar?

Similar, but referring to pg_class_oid_index.

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* vacuum error
@ 2005-06-27 08:37 Ulrich Wisser <ulrich.wisser@relevanttraffic.se>
  0 siblings, 0 replies; 27+ messages in thread

From: Ulrich Wisser @ 2005-06-27 08:37 UTC (permalink / raw)
  To: pgsql-general

Hi,

after months of flawless operation I get the following error when 
running VACUUM ANALYZE

vacuumdb: vacuuming database "CLIX2"
vacuumdb: vacuuming of database "CLIX2" failed: ERROR:  left link 
changed unexpectedly

System: Fedora Core 2, 2.6.10-1.771_FC2
         Postgres 7.4.2

What does that mean? Can it be fixed? How?

TIA

Ulrich


-- 
Ulrich Wisser  / System Developer

RELEVANT TRAFFIC SWEDEN AB, Riddarg 17A, SE-114 57 Sthlm, Sweden
Direct (+46)86789755 || Cell (+46)704467893 || Fax (+46)86789769
________________________________________________________________
http://www.relevanttraffic.com



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* vacuum error
@ 2007-03-06 18:10 Ed L. <pgsql@bluepolka.net>
  2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  0 siblings, 1 reply; 27+ messages in thread

From: Ed L. @ 2007-03-06 18:10 UTC (permalink / raw)
  To: pgsql-general

I am seeing the following error in pgsql 8.1.2:

2007-03-05 10:00:51.106 PST [9834]    DEBUG:  vacuuming "pg_toast.pg_toast_1260"
2007-03-05 10:00:51.106 PST [9834]    DEBUG:  index "pg_toast_1260_index" now contains 0 row versions in 1 pages
2007-03-05 10:00:51.106 PST [9834]    DETAIL:  0 index pages have been deleted, 0 are currently reusable.
        CPU 0.00s/0.00u sec elapsed 0.00 sec.
2007-03-05 10:00:51.106 PST [9834]    DEBUG:  "pg_toast_1260": found 0 removable, 0 nonremovable row versions in 0 pages
2007-03-05 10:00:51.106 PST [9834]    DETAIL:  0 dead row versions cannot be removed yet.
        There were 0 unused item pointers.
        0 pages are entirely empty.
        CPU 0.00s/0.00u sec elapsed 0.00 sec.
2007-03-05 10:00:51.106 PST [9834]    DEBUG:  vacuuming "pg_catalog.pg_statistic"
2007-03-05 10:00:51.107 PST [9834]    ERROR:  could not access status of transaction 3229475082
2007-03-05 10:00:51.107 PST [9834]    DETAIL:  could not open file "pg_clog/0C07": No such file or directory

What does it mean, and what should I do about it?

TIA.
Ed



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
@ 2007-03-06 19:20 ` Peter Eisentraut <peter_e@gmx.net>
  2007-03-06 21:19   ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  0 siblings, 1 reply; 27+ messages in thread

From: Peter Eisentraut @ 2007-03-06 19:20 UTC (permalink / raw)
  To: pgsql-general; +Cc: Ed L. <pgsql@bluepolka.net>

Ed L. wrote:
> I am seeing the following error in pgsql 8.1.2:

> ERROR:  could not access status of transaction 3229475082
> DETAIL:  could not open file "pg_clog/0C07": No such file or directory
>
> What does it mean, and what should I do about it?

1. Read this thread: 
http://archives.postgresql.org/pgsql-general/2007-02/msg00820.php

2. Upgrade to the latest 8.1.* release.

3. If that doesn't help, check your system for faulty hardware, in 
particular for bad RAM.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
@ 2007-03-06 21:19   ` Ed L. <pgsql@bluepolka.net>
  2007-03-06 22:53     ` Re: vacuum error Joshua D. Drake <jd@commandprompt.com>
  0 siblings, 1 reply; 27+ messages in thread

From: Ed L. @ 2007-03-06 21:19 UTC (permalink / raw)
  To: Peter Eisentraut <peter_e@gmx.net>; +Cc: pgsql-general

On Tuesday March 6 2007 12:20 pm, Peter Eisentraut wrote:
> Ed L. wrote:
> > I am seeing the following error in pgsql 8.1.2:
> >
> > ERROR:  could not access status of transaction 3229475082
> > DETAIL:  could not open file "pg_clog/0C07": No such file or
> > directory
> >
> > What does it mean, and what should I do about it?
>
> 1. Read this thread:
> http://archives.postgresql.org/pgsql-general/2007-02/msg00820.
>php
>
> 2. Upgrade to the latest 8.1.* release.
>
> 3. If that doesn't help, check your system for faulty
> hardware, in particular for bad RAM.

This is a 200gb DB with ~300 transactions/second serving 5 busy 
facilities, so downtime comes at a premium.  We have some 
maintenance downtime planned for 2 weeks from now.  I'm trying 
to understand if this can wait that long.

It appears the only failure occurs during an autovacuum-initiated 
"VACUUM FREEZE" on template0 when it hits the pg_statistics 
table.  However, that abort appears to be causing autovacuum to 
skip all its other duties as it endlessly restarts and fails 
again.

Do I care if template0 gets a "VACUUM FREEZE"?

Assuming not, is there a simple way to make autovacuum skip over 
template0 so it can tend to the important data in the other 
databases?

Is restarting with 8.1.8 a known solution for this problem?  Or 
is an initdb required to fix it?

If initdb is required, we might as well move to the latest stable 
8.2 version.  I understand my options to minimize downtime to be 
limited to async replication.  Other ideas?

BTW, the RAM looks good.

TIA.
Ed



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-06 21:19   ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
@ 2007-03-06 22:53     ` Joshua D. Drake <jd@commandprompt.com>
  2007-03-06 23:18       ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  0 siblings, 1 reply; 27+ messages in thread

From: Joshua D. Drake @ 2007-03-06 22:53 UTC (permalink / raw)
  To: Ed L. <pgsql@bluepolka.net>; +Cc: Peter Eisentraut <peter_e@gmx.net>; pgsql-general


> If initdb is required, we might as well move to the latest stable 
> 8.2 version.  I understand my options to minimize downtime to be 
> limited to async replication.  Other ideas?
>
> BTW, the RAM looks good.
>
>   
You can update to 8.1.8 (if you are running 8.1.x) without an initdb.

Joshua D. Drake


> TIA.
> Ed
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: Have you checked our extensive FAQ?
>
>                http://www.postgresql.org/docs/faq
>
>   




^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-06 21:19   ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 22:53     ` Re: vacuum error Joshua D. Drake <jd@commandprompt.com>
@ 2007-03-06 23:18       ` Ed L. <pgsql@bluepolka.net>
  2007-03-07 06:52         ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  0 siblings, 1 reply; 27+ messages in thread

From: Ed L. @ 2007-03-06 23:18 UTC (permalink / raw)
  To: pgsql-general; +Cc: Joshua D. Drake <jd@commandprompt.com>; Peter Eisentraut <peter_e@gmx.net>

On Tuesday March 6 2007 3:53 pm, Joshua D. Drake wrote:
>
> > Is restarting with 8.1.8 a known solution for this problem?  
> > Or is an initdb required to fix it?
>
> You can update to 8.1.8 (if you are running 8.1.x) without an
> initdb.

Right.  I'm asking if the fix for this problem is in the new 
8.1.8 software, or in the new DB structure resulting from the 
initdb, or perhaps both.

Ed



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-06 21:19   ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 22:53     ` Re: vacuum error Joshua D. Drake <jd@commandprompt.com>
  2007-03-06 23:18       ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
@ 2007-03-07 06:52         ` Peter Eisentraut <peter_e@gmx.net>
  2007-03-07 09:29           ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  0 siblings, 1 reply; 27+ messages in thread

From: Peter Eisentraut @ 2007-03-07 06:52 UTC (permalink / raw)
  To: Ed L. <pgsql@bluepolka.net>; +Cc: pgsql-general; Joshua D. Drake <jd@commandprompt.com>

Ed L. wrote:
> Right.  I'm asking if the fix for this problem is in the new
> 8.1.8 software, or in the new DB structure resulting from the
> initdb, or perhaps both.

There is no new DB structure in 8.1.8, which is why you can update 
without initdb.  Consult the release notes for details.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-06 21:19   ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 22:53     ` Re: vacuum error Joshua D. Drake <jd@commandprompt.com>
  2007-03-06 23:18       ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-07 06:52         ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
@ 2007-03-07 09:29           ` Ed L. <pgsql@bluepolka.net>
  2007-03-07 10:13             ` Re: vacuum error Martijn van Oosterhout <kleptog@svana.org>
  0 siblings, 1 reply; 27+ messages in thread

From: Ed L. @ 2007-03-07 09:29 UTC (permalink / raw)
  To: Peter Eisentraut <peter_e@gmx.net>; +Cc: pgsql-general; Joshua D. Drake <jd@commandprompt.com>

On Tuesday March 6 2007 11:52 pm, Peter Eisentraut wrote:
> Ed L. wrote:
> > Right.  I'm asking if the fix for this problem is in the new
> > 8.1.8 software, or in the new DB structure resulting from
> > the initdb, or perhaps both.
>
> There is no new DB structure in 8.1.8, which is why you can
> update without initdb.  Consult the release notes for details.

Perhaps my question was not clear enough.  Let me rephrase:  Does 
the fix for this problem comes from a *fresh* DB structure 
resulting from the initdb, or from a software fix in 8.1.8, or 
both?  The answer makes a big difference with a 200gb database.  
If it's in the software alone, we can simply restart.  If it's 
in the DB structure, we have to migrate 200gb of data from one 
PGDATA to another.

Ed




^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-06 21:19   ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 22:53     ` Re: vacuum error Joshua D. Drake <jd@commandprompt.com>
  2007-03-06 23:18       ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-07 06:52         ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-07 09:29           ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
@ 2007-03-07 10:13             ` Martijn van Oosterhout <kleptog@svana.org>
  2007-03-08 02:07               ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  0 siblings, 1 reply; 27+ messages in thread

From: Martijn van Oosterhout @ 2007-03-07 10:13 UTC (permalink / raw)
  To: Ed L. <pgsql@bluepolka.net>; +Cc: Peter Eisentraut <peter_e@gmx.net>; pgsql-general; Joshua D. Drake <jd@commandprompt.com>

On Wed, Mar 07, 2007 at 02:29:08AM -0700, Ed L. wrote:
> Perhaps my question was not clear enough.  Let me rephrase:  Does 
> the fix for this problem comes from a *fresh* DB structure 
> resulting from the initdb, or from a software fix in 8.1.8, or 
> both?  The answer makes a big difference with a 200gb database.  
> If it's in the software alone, we can simply restart.  If it's 
> in the DB structure, we have to migrate 200gb of data from one 
> PGDATA to another.

It would come from upgrading the software. Reinitdbing won't actually
make a difference. The whole point of minor versions is that you don't
need to reinit the DB, otherwise it'd be a major version...

In your case you could also get running by creating the missing file,
but whether that's appropriate depends on the cause. I'd check the
release notes to see if any related bugs have been fixed since then.

Have a nice day,
-- 
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

Attachments:

  signature.asc (application/pgp-signature, 188B) download

^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-06 21:19   ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 22:53     ` Re: vacuum error Joshua D. Drake <jd@commandprompt.com>
  2007-03-06 23:18       ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-07 06:52         ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-07 09:29           ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-07 10:13             ` Re: vacuum error Martijn van Oosterhout <kleptog@svana.org>
@ 2007-03-08 02:07               ` Ed L. <pgsql@bluepolka.net>
  2007-03-08 18:25                 ` Re: vacuum error Martijn van Oosterhout <kleptog@svana.org>
  0 siblings, 1 reply; 27+ messages in thread

From: Ed L. @ 2007-03-08 02:07 UTC (permalink / raw)
  To: Martijn van Oosterhout <kleptog@svana.org>; +Cc: Peter Eisentraut <peter_e@gmx.net>; pgsql-general; Joshua D. Drake <jd@commandprompt.com>

On Wednesday March 7 2007 3:13 am, Martijn van Oosterhout wrote:
> On Wed, Mar 07, 2007 at 02:29:08AM -0700, Ed L. wrote:
> > Perhaps my question was not clear enough.  Let me rephrase: 
> > Does the fix for this problem comes from a *fresh* DB
> > structure resulting from the initdb, or from a software fix
> > in 8.1.8, or both?  The answer makes a big difference with a
> > 200gb database. If it's in the software alone, we can simply
> > restart.  If it's in the DB structure, we have to migrate
> > 200gb of data from one PGDATA to another.
>
> In your case you could also get running by creating the
> missing file, but whether that's appropriate depends on the
> cause. I'd check the release notes to see if any related bugs
> have been fixed since then.

How would I go about correctly creating the missing file?  That 
sounds appealing, as if it were something I could do without 
taking downtime.  Is it?

In reviewing the release notes between 8.1.2 and 8.1.8, there are 
a number of vacuum fixes along with many others.  It is unclear 
if any of them are related.

Given this error is occurring while doing a "VACUUM FREEZE" of 
the template0 database, I wonder if that creates any options for 
me?  Frankly, I'd be happy to simply drop the template0 DB if I 
could, since I'm not aware that we ever need it for anything.

Ed



^ permalink  raw  reply  [nested|flat] 27+ messages in thread

* Re: vacuum error
  2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-06 21:19   ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-06 22:53     ` Re: vacuum error Joshua D. Drake <jd@commandprompt.com>
  2007-03-06 23:18       ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-07 06:52         ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
  2007-03-07 09:29           ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
  2007-03-07 10:13             ` Re: vacuum error Martijn van Oosterhout <kleptog@svana.org>
  2007-03-08 02:07               ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
@ 2007-03-08 18:25                 ` Martijn van Oosterhout <kleptog@svana.org>
  0 siblings, 0 replies; 27+ messages in thread

From: Martijn van Oosterhout @ 2007-03-08 18:25 UTC (permalink / raw)
  To: Ed L. <pgsql@bluepolka.net>; +Cc: Peter Eisentraut <peter_e@gmx.net>; pgsql-general; Joshua D. Drake <jd@commandprompt.com>

On Wed, Mar 07, 2007 at 07:07:45PM -0700, Ed L. wrote:
> How would I go about correctly creating the missing file?  That 
> sounds appealing, as if it were something I could do without 
> taking downtime.  Is it?

Depends if it's because the file got deleted prematurly, or because
it's the result of corruption in the table. If it's just that it got
deleted prematurely, you should just be able to create the file with
256KB of zeros.

> In reviewing the release notes between 8.1.2 and 8.1.8, there are 
> a number of vacuum fixes along with many others.  It is unclear 
> if any of them are related.

There definitly was a bug related to this and you should upgrade to the
latest minor release anyway, because it will probably bite you again.

> Given this error is occurring while doing a "VACUUM FREEZE" of 
> the template0 database, I wonder if that creates any options for 
> me?  Frankly, I'd be happy to simply drop the template0 DB if I 
> could, since I'm not aware that we ever need it for anything.

You can drop and recreate the template0 database, instructions are
somewhere. I don't think you can do without because I beleive pg_dump
needs it.

Have a nice day,
-- 
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

Attachments:

  signature.asc (application/pgp-signature, 188B) download

^ permalink  raw  reply  [nested|flat] 27+ messages in thread


end of thread, other threads:[~2007-03-08 18:25 UTC | newest]

Thread overview: 27+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2000-09-05 08:26 VACUUM Error Hoosain Madhi <MADHIH@vodacom.co.za>
2003-03-12 11:48 vacuum error Eric Cholet <cholet@logilune.com>
2003-03-12 16:24 ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
2003-03-12 16:36   ` Re: vacuum error Eric Cholet <cholet@logilune.com>
2003-03-12 16:40     ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
2003-03-12 18:18       ` Re: vacuum error Eric Cholet <cholet@logilune.com>
2003-03-12 18:32         ` Re: vacuum error Tom Lane <tgl@sss.pgh.pa.us>
2004-01-12 18:48 Vacuum Error Dave Smith <dave.smith@candata.com>
2004-01-12 19:25 ` Re: Vacuum Error Martin Marques <martin@bugs.unl.edu.ar>
2004-01-12 22:31 ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
2004-01-12 22:27   ` Re: Vacuum Error scott.marlowe <scott.marlowe@ihs.com>
2004-01-12 22:57     ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
2004-01-12 23:00   ` Re: Vacuum Error Andrew Bartley <abartley@evolvosystems.com>
2004-01-12 23:20     ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
2004-01-12 23:59       ` Re: Vacuum Error Kragen Sitaker <kragen+pgsql@airwave.com>
2004-01-13 04:43         ` Re: Vacuum Error Tom Lane <tgl@sss.pgh.pa.us>
2005-06-27 08:37 vacuum error Ulrich Wisser <ulrich.wisser@relevanttraffic.se>
2007-03-06 18:10 vacuum error Ed L. <pgsql@bluepolka.net>
2007-03-06 19:20 ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
2007-03-06 21:19   ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
2007-03-06 22:53     ` Re: vacuum error Joshua D. Drake <jd@commandprompt.com>
2007-03-06 23:18       ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
2007-03-07 06:52         ` Re: vacuum error Peter Eisentraut <peter_e@gmx.net>
2007-03-07 09:29           ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
2007-03-07 10:13             ` Re: vacuum error Martijn van Oosterhout <kleptog@svana.org>
2007-03-08 02:07               ` Re: vacuum error Ed L. <pgsql@bluepolka.net>
2007-03-08 18:25                 ` Re: vacuum error Martijn van Oosterhout <kleptog@svana.org>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox