pg.ddx.io  pgsql-docs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
adding a superuser
7+ messages / 6 participants
[nested] [flat]

* adding a superuser
@ 2001-09-15 22:15 Karl Babcock <karl@knbenterprises.com>
  2001-09-16 10:01 ` Re: adding a superuser Arne Weiner <aswr@gmx.de>
  2001-09-16 14:38 ` Re: adding a superuser TeuK <humpf@yahoo.fr>
  2001-09-17 14:34 ` Re: adding a superuser Serge V. Tarasov <max@gilbor.ru>
  2001-09-17 17:20 ` Re: adding a superuser Stephan Szabo <sszabo@megazone23.bigpanda.com>
  0 siblings, 4 replies; 7+ messages in thread

From: Karl Babcock @ 2001-09-15 22:15 UTC (permalink / raw)
  To: pgsql-docs@postgresql.org.pgsql-general

Hi, I have just installed PostgreSQL 7.1 and am having a hard time adding
users. I am trying to add a superuser but I keep getting errors with the
createuser script.

I am user 'root' on the Linux system when I run:

lightning:/# createuser -d -a root
psql: FATAL 1: user "root" does not exist
createuser: creation of user "root failed

Does anyone know how I could create a superuser or any user?

Thanks in advance,

Karl





^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: adding a superuser
  2001-09-15 22:15 adding a superuser Karl Babcock <karl@knbenterprises.com>
@ 2001-09-16 10:01 ` Arne Weiner <aswr@gmx.de>
  3 siblings, 0 replies; 7+ messages in thread

From: Arne Weiner @ 2001-09-16 10:01 UTC (permalink / raw)
  To: pgsql-docs@postgresql.org.pgsql-general

Karl Babcock wrote:
> 
> Hi, I have just installed PostgreSQL 7.1 and am having a hard time adding
> users. I am trying to add a superuser but I keep getting errors with the
> createuser script.
> 
> I am user 'root' on the Linux system when I run:
> 
> lightning:/# createuser -d -a root
> psql: FATAL 1: user "root" does not exist
> createuser: creation of user "root failed
> 
> Does anyone know how I could create a superuser or any user?
> 
> Thanks in advance,
> 
> Karl

You have to supply the -U option if you specify the username in the
command line.

 createuser -d -a -U root

Or you just say:

 createuser -d -a

and you will be prompted for username.


Arne Weiner.



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: adding a superuser
  2001-09-15 22:15 adding a superuser Karl Babcock <karl@knbenterprises.com>
@ 2001-09-16 14:38 ` TeuK <humpf@yahoo.fr>
  2001-09-16 16:09   ` Re: adding a superuser Karl Babcock <karl@knbenterprises.com>
  3 siblings, 1 reply; 7+ messages in thread

From: TeuK @ 2001-09-16 14:38 UTC (permalink / raw)
  To: pgsql-docs@postgresql.org.pgsql-general

I think user root is not known in Postgres user and that's why you want to
add it (;

try :

createuser -d -a -U postgres root

As a rule postgres is running under postgres user account that is a
superuser.

So try psl -U postgres
"Karl Babcock" <karl@knbenterprises.com> a écrit dans le message news:
_pQo7.71168$xb.37085264@news1.mntp1.il.home.com...
> Hi, I have just installed PostgreSQL 7.1 and am having a hard time adding
> users. I am trying to add a superuser but I keep getting errors with the
> createuser script.
>
> I am user 'root' on the Linux system when I run:
>
> lightning:/# createuser -d -a root
> psql: FATAL 1: user "root" does not exist
> createuser: creation of user "root failed
>
> Does anyone know how I could create a superuser or any user?
>
> Thanks in advance,
>
> Karl
>
>





^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: adding a superuser
  2001-09-15 22:15 adding a superuser Karl Babcock <karl@knbenterprises.com>
  2001-09-16 14:38 ` Re: adding a superuser TeuK <humpf@yahoo.fr>
@ 2001-09-16 16:09   ` Karl Babcock <karl@knbenterprises.com>
  2001-09-17 15:19     ` Re: adding a superuser Oliver Elphick <olly@lfix.co.uk>
  0 siblings, 1 reply; 7+ messages in thread

From: Karl Babcock @ 2001-09-16 16:09 UTC (permalink / raw)
  To: pgsql-docs@postgresql.org.pgsql-general

I tried that and it says:

psql: Peer authentication failed for user 'postgres'
createuser: creation of user "root" failed


"TeuK" <humpf@yahoo.fr> wrote in message
news:9o2dhq$gc$1@front4m.grolier.fr...
> I think user root is not known in Postgres user and that's why you want to
> add it (;
>
> try :
>
> createuser -d -a -U postgres root
>
> As a rule postgres is running under postgres user account that is a
> superuser.
>
> So try psl -U postgres
> "Karl Babcock" <karl@knbenterprises.com> a écrit dans le message news:
> _pQo7.71168$xb.37085264@news1.mntp1.il.home.com...
> > Hi, I have just installed PostgreSQL 7.1 and am having a hard time
adding
> > users. I am trying to add a superuser but I keep getting errors with the
> > createuser script.
> >
> > I am user 'root' on the Linux system when I run:
> >
> > lightning:/# createuser -d -a root
> > psql: FATAL 1: user "root" does not exist
> > createuser: creation of user "root failed
> >
> > Does anyone know how I could create a superuser or any user?
> >
> > Thanks in advance,
> >
> > Karl
> >
> >
>
>





^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: adding a superuser
  2001-09-15 22:15 adding a superuser Karl Babcock <karl@knbenterprises.com>
  2001-09-16 14:38 ` Re: adding a superuser TeuK <humpf@yahoo.fr>
  2001-09-16 16:09   ` Re: adding a superuser Karl Babcock <karl@knbenterprises.com>
@ 2001-09-17 15:19     ` Oliver Elphick <olly@lfix.co.uk>
  0 siblings, 0 replies; 7+ messages in thread

From: Oliver Elphick @ 2001-09-17 15:19 UTC (permalink / raw)
  To: pgsql-docs; pgsql-general@postgresql.org

"Karl Babcock" wrote:
  >I tried that and it says:
  >
  >psql: Peer authentication failed for user 'postgres'
  >createuser: creation of user "root" failed
  >
  >
  >"TeuK" <humpf@yahoo.fr> wrote in message
  >news:9o2dhq$gc$1@front4m.grolier.fr...
  >> I think user root is not known in Postgres user and that's why you want to
  >> add it (;
  >>
  >> try :
  >>
  >> createuser -d -a -U postgres root
  >>
  >> As a rule postgres is running under postgres user account that is a
  >> superuser.
 
It sounds as though you are using a Debian package (peer authentication 
is peculiar to the current Debian release and will disappear again
when 7.2 is released).  The default authentication in Debian is:

  local   all   peer   sameuser

and if that is unchanged, you cannot connect as any user other than your
own Unix login id.  You need to run this command as Unix user 'postgres':

 # su - postgres
 $ createuser -d -a root


-- 
Oliver Elphick                                Oliver.Elphick@lfix.co.uk
Isle of Wight                              http://www.lfix.co.uk/oliver
PGP: 1024R/32B8FAA1: 97 EA 1D 47 72 3F 28 47  6B 7E 39 CC 56 E4 C1 47
GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839  932A 614D 4C34 3E1D 0C1C
                 ========================================
     "Honour the LORD with thy substance, and with the  
      firstfruits of all thine increase; So shall thy barns 
      be filled with plenty, and thy presses shall burst out
      with new wine."      Proverbs 3:9,10 





^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: adding a superuser
  2001-09-15 22:15 adding a superuser Karl Babcock <karl@knbenterprises.com>
@ 2001-09-17 14:34 ` Serge V. Tarasov <max@gilbor.ru>
  3 siblings, 0 replies; 7+ messages in thread

From: Serge V. Tarasov @ 2001-09-17 14:34 UTC (permalink / raw)
  To: pgsql-docs@postgresql.org.pgsql-general

Karl Babcock" <karl@knbenterprises.com> wrote in message
news:_pQo7.71168$xb.37085264@news1.mntp1.il.home.com...
> Hi, I have just installed PostgreSQL 7.1 and am having a hard time adding
> users. I am trying to add a superuser but I keep getting errors with the
> createuser script.
>
> I am user 'root' on the Linux system when I run:
>
> lightning:/# createuser -d -a root
> psql: FATAL 1: user "root" does not exist
> createuser: creation of user "root failed
>
> Does anyone know how I could create a superuser or any user?

Sorry for may poor english.
First as root use:
su -l postgres
after you may use
createuser root

[root@main /root]# su -l postgres
bash-2.04$ /usr/local/pgsql/bin/createuser root
Shall the new user be allowed to create databases? (y/n) y
Shall the new user be allowed to create more new users? (y/n) y
CREATE USER

Now user root - postgresql superuser.

Bye,
            Max.






^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: adding a superuser
  2001-09-15 22:15 adding a superuser Karl Babcock <karl@knbenterprises.com>
@ 2001-09-17 17:20 ` Stephan Szabo <sszabo@megazone23.bigpanda.com>
  3 siblings, 0 replies; 7+ messages in thread

From: Stephan Szabo @ 2001-09-17 17:20 UTC (permalink / raw)
  To: Karl Babcock <karl@knbenterprises.com>; +Cc: pgsql-general@postgresql.org

On Sat, 15 Sep 2001, Karl Babcock wrote:

> Hi, I have just installed PostgreSQL 7.1 and am having a hard time adding
> users. I am trying to add a superuser but I keep getting errors with the
> createuser script.
> 
> I am user 'root' on the Linux system when I run:
> 
> lightning:/# createuser -d -a root
> psql: FATAL 1: user "root" does not exist
> createuser: creation of user "root failed
> 
> Does anyone know how I could create a superuser or any user?

What does your pg_hba.conf say about local connections?





^ permalink  raw  reply  [nested|flat] 7+ messages in thread


end of thread, other threads:[~2001-09-17 17:20 UTC | newest]

Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-09-15 22:15 adding a superuser Karl Babcock <karl@knbenterprises.com>
2001-09-16 10:01 ` Arne Weiner <aswr@gmx.de>
2001-09-16 14:38 ` TeuK <humpf@yahoo.fr>
2001-09-16 16:09   ` Karl Babcock <karl@knbenterprises.com>
2001-09-17 15:19     ` Oliver Elphick <olly@lfix.co.uk>
2001-09-17 14:34 ` Serge V. Tarasov <max@gilbor.ru>
2001-09-17 17:20 ` Stephan Szabo <sszabo@megazone23.bigpanda.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox