Re: Fixing flat user/group files at database startup

From: Stephen Frost <sfrost(at)snowman(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Fixing flat user/group files at database startup
Date: 2005-02-05 22:53:41
Message-ID: 20050205225341.GM10437@ns.snowman.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

* Tom Lane (tgl(at)sss(dot)pgh(dot)pa(dot)us) wrote:
> Stephen Frost <sfrost(at)snowman(dot)net> writes:
> > We can't build the files very easily during WAL recovery, but
> > what about if we compare the files to the database after the normal
> > backend startup? If they're different, regenerate the files.
>
> This assumes that you can get in in the first place, which is not a good
> assumption if the flat password file is missing all your current users
> and/or passwords.

I was thinking of this just being a general 'check that the world is
sane' part of backend startup and would be automated and happen every
time, not something an admin would have to kick off or anything. The
backend looks through the WAL files and whatnot during startup too, to
check if there was a crash or something...

I guess I'm confused by 'who' needs to 'get in' to have a bit of code
run at the very end of the backend startup. Apparently I'm somewhat
naive in that area.

Stephen

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2005-02-05 23:51:52 Re: libpq API incompatibility between 7.4 and 8.0
Previous Message Tom Lane 2005-02-05 22:05:07 Re: Fixing flat user/group files at database startup