pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: pgsql start implies initdb = bad



David Brownlee wrote:
[---]
> Just to clarify - the issue here is the psql data directory being on a
> soft or interruptable nfs mount, a restart when the mount is down
> causing initdb to run on the local filesystem, and then the mount
> coming back and psql scribbling 'new db data' over the production
> database?

   That's the core of the issue, yes. Information about "new" data gets
read into memory. "Old" database appears where "new" database was when
new mount completes. Database does confusing things to "Old" database
because of partial "new" database information.

> Running a database on an interruptable or soft mounted filesystem
> manages to make using it on a normal nfs filesystem seem quite
> sensible :)

   This is what happened: I noticed that template1 doesn't default to
unicode, so I asked on a postgresql IRC channel if something has changed
recently (since I had used utf-8 and template1 previously). After they
asked a few questions I replied that initdb is automatically run as a
part of "start" if no database has been initialized. Then came the,
rather unexpected - I must admit, "ARE YOU FRIGGIN' INSANE?!", etc.
Seeing as these guys have seen much more database experiences than have,
and that they have more than one documented case were exactly what is
done in default pkgsrc resulted in disaster, I thought I'd bring it up.
I have done so. I leave it up to the people who know more about these
things to determine if it's relevant. I'm not going to try to force the
issue.

-- 
Kind regards,
Jan Danielsson


Attachment: signature.asc
Description: OpenPGP digital signature



Home | Main Index | Thread Index | Old Index