X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id AC18AD1B4E5 for ; Sat, 8 Nov 2003 21:15:36 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 34703-10 for ; Sat, 8 Nov 2003 17:15:06 -0400 (AST) Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by svr1.postgresql.org (Postfix) with ESMTP id 85F46D1B504 for ; Sat, 8 Nov 2003 17:15:04 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.10/8.12.10) with ESMTP id hA8LF319014693; Sat, 8 Nov 2003 16:15:03 -0500 (EST) To: Bruce Momjian Cc: alban , pgsql-sql@postgresql.org Subject: Re: 7.3 : how add user when last user have lost 'createuser' option In-reply-to: <200311082103.hA8L3Fe20121@candle.pha.pa.us> References: <200311082103.hA8L3Fe20121@candle.pha.pa.us> Comments: In-reply-to Bruce Momjian message dated "Sat, 08 Nov 2003 16:03:15 -0500" Date: Sat, 08 Nov 2003 16:15:03 -0500 Message-ID: <14692.1068326103@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200311/59 X-Sequence-Number: 15874 Bruce Momjian writes: > alban wrote: >> i have execute >> ALTER USER postgres WITH NOCREATEUSER; > Uh, you removed createuser permission from the postgres super-user. That was a really bad move :-( If you have no superusers left, I think your only option is to shut down the postmaster, start a standalone backend, and ALTER USER postgres back to superuser status in the standalone backend. Then you can restart the postmaster. IIRC this will work in 7.3 and probably 7.2. If you're running something older, you are well and truly hosed, because you can't reclaim superuser status even with a standalone backend. regards, tom lane