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