Re: Installed PostgreSQL-11 in Ubuntu 18.04.02 Server Edition: No existing local cluster is suitable as a default target

From: Matthias Apitz <guru(at)unixarea(dot)de>
To: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
Cc: Marco Ippolito <ippolito(dot)marco(at)gmail(dot)com>, pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Installed PostgreSQL-11 in Ubuntu 18.04.02 Server Edition: No existing local cluster is suitable as a default target
Date: 2019-09-18 14:49:01
Message-ID: 20190918144901.GA3103@c720-r342378
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

El día miércoles, septiembre 18, 2019 a las 07:41:41a. m. -0700, Adrian Klaver escribió:

> On 9/18/19 6:13 AM, Marco Ippolito wrote:
> > Thanks Matthias,
> > very kind. Hopefully I will get some hints on how to solve my problem.
>
> You should probably take a look at:
>
> https://help.ubuntu.com/lts/serverguide/postgresql.html
>
> FYI, you should set the permission son /usr/lib/postgresql back to root
> and use:
>
> sudo pg_ctl <command>

NAK. In my understanding, the dir above the data dir of the cluster
should be owned by 'postgres' and the pg_ctl run as 'postgres':

# mkdir /data/postgresql11
# chown postgres /data/postgresql11
# su - postgres
$ LANG=de_DE.UTF-8 export LANG
$ /usr/local/sisis-pap/pgsql/bin/pg_ctl -D /data/postgresql11/data initdb

This is stolen from the pages mentioned, i.e. https://www.postgresql.org/docs/11/runtime.html
(chapter 18. Server Setup and Operation) and worked out of the box fine
for me.

matthias

--
Matthias Apitz, ✉ guru(at)unixarea(dot)de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub

Mientras haya voluntad de lucha habrá esperanza de vencer.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Sonam Sharma 2019-09-18 14:56:32 Re: Pg_auto_failover
Previous Message Marco Ippolito 2019-09-18 14:44:16 Re: Installed PostgreSQL-11 in Ubuntu 18.04.02 Server Edition: No existing local cluster is suitable as a default target