Search Postgresql Archives

Re: user connection not recorded?

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

 



Adrian Klaver <adrian.klaver@xxxxxxxxxxx> writes:
> Eventually got around to figuring that. So just for my reference, the 
> code snippet I showed from postinit.c seems to show a path where a 
> username is not used but is  substituted with BOOTSTRAP_SUPERUSERID.

That's single-user mode.

> Am I following that correctly and what is BOOTSTRAP_SUPERUSERID?

BOOTSTRAP_SUPERUSERID is the OID of the precreated superuser.

The reason for that hack is to ensure you can still log in, in single-user
mode, even if you've done something stupid like "delete from pg_authid".
You'll be running under a user OID that doesn't actually exist in
pg_authid, but it won't matter because the code will believe you're a
superuser and will never go looking for the missing row.  Then you
can create yourself a new superuser, and resolve not to do that again.

			regards, tom lane


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux