Re: 7.2.1 segfaults. - Mailing list pgsql-bugs

From Stephen Amadei
Subject Re: 7.2.1 segfaults.
Date
Msg-id Pine.LNX.4.44.0205042110210.11954-100000@rastaban.dandy.net
Whole thread Raw
In response to Re: 7.2.1 segfaults.  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
On Sat, 4 May 2002, Tom Lane wrote:

> Hmm.  It looks like GetRawDatabaseInfo is reading a zero for the VARSIZE
> of datpath, and then computing -4 (which strncpy will take as a huge
> unsigned value) as the string length to copy.  You could try applying
> a patch like this, in src/backend/utils/misc/database.c (about line
> 225 in current sources):

Wierd.

> However this really shouldn't be needed; I'm wondering whether the
> database's row in pg_database has been clobbered somehow.  If so,
> it probably won't get much further before dying.

Good point.  And deleting the $PGDATA directory and recreating it
fixed it without a patch.

> Two questions: does the same thing happen for all available databases?
> Have you tried to create a database with a nonstandard location
> (nondefault datpath)?

No... I was creating the database in /usr/local/pgsql/data and then
'cp -aRp'ing it into the chroot.  So I had two copies of the same corrupt
database.

Thanks for the help.

                    ----Steve
Stephen Amadei
Dandy.NET!  CTO
Atlantic City, NJ

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: Why does Postgres need the /bin/sh?
Next
From: Stephen Amadei
Date:
Subject: Re: Why does Postgres need the /bin/sh?