dbTalk Databases Forums  

Superuser

comp.databases.postgresql.novice comp.databases.postgresql.novice


Discuss Superuser in the comp.databases.postgresql.novice forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Reinhard Hnat
 
Posts: n/a

Default Superuser - 06-29-2004 , 04:02 AM






By mistake I took away superuser rights from my postgresql Admin. Any idea
how to get it back? There is no other superuser in the database.
----
R.Hnat




---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings


Reply With Quote
  #2  
Old   
Nabil Sayegh
 
Posts: n/a

Default Re: Superuser - 06-29-2004 , 04:36 AM






Reinhard Hnat wrote:
Quote:
By mistake I took away superuser rights from my postgresql Admin. Any idea
how to get it back? There is no other superuser in the database.
How did you remove it?
Maybe pg_hba.conf is what you're looking for.
Or the pg_shadow table for passwords etc.

hth
--
e-Trolley Sayegh & John, Nabil Sayegh
Tel.: 0700 etrolley /// 0700 38765539
Fax.: +49 69 8299381-8
PGP : http://www.e-trolley.de

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo (AT) postgresql (DOT) org



Reply With Quote
  #3  
Old   
Tom Lane
 
Posts: n/a

Default Re: Superuser - 06-29-2004 , 09:07 AM



"Reinhard Hnat" <hnat (AT) logotronic (DOT) co.at> writes:
Quote:
By mistake I took away superuser rights from my postgresql Admin. Any idea
how to get it back? There is no other superuser in the database.
Assuming you are running a reasonably recent Postgres (I am sure this
works in 7.3, don't recall about 7.2 or before):

1. Stop the postmaster.
2. Start a standalone backend (see the "postgres" man page for details).
3. Now you are effectively superuser. ALTER USER to give your admin
back superuserness, or just UPDATE his pg_shadow row if that seems
easier.
4. Stop standalone backend, restart postmaster.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.