pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
7.0.3 pg_dump -> segmentation fault!
4+ messages / 3 participants
[nested] [flat]

* 7.0.3 pg_dump -> segmentation fault!
@ 2002-03-07 20:17  george young <gry@ll.mit.edu>
  0 siblings, 1 reply; 4+ messages in thread

From: george young @ 2002-03-07 20:17 UTC (permalink / raw)
  To: pgsql-sql

[Postgres 7.0.3, SuSE Linux 7.1, kernel 2.2.14, dual pentium 3]
450 user tables, db directory ~ 90MB.

I'm desperate!  I need to dump my db so I can set it up on another machine.
I have a lot of important data here and haven't been able to dump it! I can't even pg_dump
a single table.  The db is up and running, but pg_dump crashes!

pg_dump -v pig5  gives:

--  reading user-defined types
--  reading user-defined functions
--  reading user-defined aggregates
--  reading user-defined operators
--  reading user-defined tables
--  finding Triggers for relation: 'runs_tmp'
PQgetvalue: ERROR! tuple number 0 is out of range 0..-1
Segmentation fault (core dumped)                      

The last stuff in the log file is:
  query: SELECT tgname, tgfoid, tgtype, tgnargs, tgargs, tgisconstraint, tgconstrname, tgdeferrable, tginitdeferred, oid from pg_trigger where tgrelid = '1131188'::oid
  ProcessQuery
  CommitTransactionCommand
  StartTransactionCommand
  query: SELECT proname from pg_proc where pg_proc.oid = '1132416'::oid   

In fact there is no row in pg_proc with oid=1132416.

select * from pg_trigger;
 tgrelid |     tgname     | tgfoid  | tgtype | tgenabled | tgisconstraint | tgconstrname | tgconstrrelid | tgdeferrable | tginitdeferred | tgnargs | tgattr | tgargs
---------+----------------+---------+--------+-----------+----------------+--------------+---------------+--------------+----------------+---------+--------+--------
    1260 | pg_sync_pg_pwd |      12 |     29 | t         | f              |              |             0 | f            | f              |       0 |        |
 1131188 | run_changed_tr | 1132416 |     17 | t         | f              |              |             0 | f            | f              |       0 |        |
(2 rows)                                                                                                                                                        

I'm hoping there is some safe way to manually delete the inconsistant rows and then pg_dump.
Does anyone have a suggestion how to recover from this situation?

Thanks,
	George
--
George Young,  Rm. L-204                gry@ll.mit.edu
MIT Lincoln Laboratory
244 Wood St.
Lexington, Massachusetts  02420-9108    (781) 981-2756



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

* Re: 7.0.3 pg_dump -> segmentation fault!
@ 2002-03-07 20:27  Stephan Szabo <sszabo@megazone23.bigpanda.com>
  parent: george young <gry@ll.mit.edu>
  0 siblings, 0 replies; 4+ messages in thread

From: Stephan Szabo @ 2002-03-07 20:27 UTC (permalink / raw)
  To: george young <gry@ll.mit.edu>; +Cc: pgsql-sql

On Thu, 7 Mar 2002, george young wrote:

> In fact there is no row in pg_proc with oid=1132416.
>
> select * from pg_trigger;
>  tgrelid |     tgname     | tgfoid  | tgtype | tgenabled | tgisconstraint | tgconstrname | tgconstrrelid | tgdeferrable | tginitdeferred | tgnargs | tgattr | tgargs
> ---------+----------------+---------+--------+-----------+----------------+--------------+---------------+--------------+----------------+---------+--------+--------
>     1260 | pg_sync_pg_pwd |      12 |     29 | t         | f              |              |             0 | f            | f              |       0 |        |
>  1131188 | run_changed_tr | 1132416 |     17 | t         | f              |              |             0 | f            | f              |       0 |        |
> (2 rows)
>
> I'm hoping there is some safe way to manually delete the inconsistant rows and then pg_dump.
> Does anyone have a suggestion how to recover from this situation?

Can you just do a
DROP TRIGGER run_changed_tr ON runs_tmp;
and get rid of it?




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

* Fw: Re: 7.0.3 pg_dump -> segmentation fault!
@ 2002-03-07 20:44  george young <gry@ll.mit.edu>
  0 siblings, 1 reply; 4+ messages in thread

From: george young @ 2002-03-07 20:44 UTC (permalink / raw)
  To: pgsql-sql

begin forwarded message:

Date: Thu, 7 Mar 2002 15:32:07 -0500
From: george young <gry@ll.mit.edu>
To: Stephan Szabo <sszabo@megazone23.bigpanda.com>
Subject: Re: [SQL] 7.0.3 pg_dump -> segmentation fault!


On Thu, 7 Mar 2002 12:27:49 -0800 (PST)
Stephan Szabo <sszabo@megazone23.bigpanda.com> wrote:

> On Thu, 7 Mar 2002, george young wrote:
> 
> > In fact there is no row in pg_proc with oid=1132416.
> >
> > select * from pg_trigger;
> >  tgrelid |     tgname     | tgfoid  | tgtype | tgenabled | tgisconstraint | tgconstrname | tgconstrrelid | tgdeferrable | tginitdeferred | tgnargs | tgattr | tgargs
> > ---------+----------------+---------+--------+-----------+----------------+--------------+---------------+--------------+----------------+---------+--------+--------
> >     1260 | pg_sync_pg_pwd |      12 |     29 | t         | f              |              |             0 | f            | f              |       0 |        |
> >  1131188 | run_changed_tr | 1132416 |     17 | t         | f              |              |             0 | f            | f              |       0 |        |
> > (2 rows)
> >
> > I'm hoping there is some safe way to manually delete the inconsistant rows and then pg_dump.
> > Does anyone have a suggestion how to recover from this situation?
> 
> Can you just do a
> DROP TRIGGER run_changed_tr ON runs_tmp;
> and get rid of it?

Alas, no.  I get:
  drop trigger run_chaged_tr on runs_tmp;
  ERROR:  RelationBuildTriggers: tgargs IS NULL for rel runs_tmp

In fact, anything I try to do to runs_tmp I get the same above error, select, delete, drop...
This table is not important and if I could blow it and the trigger away, that would be great.

-- 
 I cannot think why the whole bed of the ocean is
 not one solid mass of oysters, so prolific they seem. Ah,
 I am wandering! Strange how the brain controls the brain!
	-- Sherlock Holmes in "The Dying Detective"



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

* Re: Fw: Re: 7.0.3 pg_dump -> segmentation fault!
@ 2002-03-07 22:24  Tom Lane <tgl@sss.pgh.pa.us>
  parent: george young <gry@ll.mit.edu>
  0 siblings, 0 replies; 4+ messages in thread

From: Tom Lane @ 2002-03-07 22:24 UTC (permalink / raw)
  To: gry@ll.mit.edu; +Cc: pgsql-sql

george young <gry@ll.mit.edu> writes:
> In fact, anything I try to do to runs_tmp I get the same above error, select, delete, drop...
> This table is not important and if I could blow it and the trigger away, that would be great.

If nothing else works, delete the pg_class row for the table; then you
should be able to pg_dump.

			regards, tom lane



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


end of thread, other threads:[~2002-03-07 22:24 UTC | newest]

Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2002-03-07 20:17 7.0.3 pg_dump -> segmentation fault! george young <gry@ll.mit.edu>
2002-03-07 20:27 ` Stephan Szabo <sszabo@megazone23.bigpanda.com>
2002-03-07 20:44 Fw: Re: 7.0.3 pg_dump -> segmentation fault! george young <gry@ll.mit.edu>
2002-03-07 22:24 ` Tom Lane <tgl@sss.pgh.pa.us>

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