From: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: Maksim Milyutin <milyutinma@gmail.com>
To: PostgreSQL-development <pgsql-hackers@postgresql.org>
Subject: Re: Hint to set owner for tablespace directory
Date: Thu, 30 Aug 2018 18:52:01 +0200
Message-ID: <1bc2bc14-e42a-8d9c-d47c-3afac05de347@2ndquadrant.com> (raw)
In-Reply-To: <5ca60e1a-26f9-89fd-e912-021dd2b8afe2@gmail.com>
References: <5ca60e1a-26f9-89fd-e912-021dd2b8afe2@gmail.com>
On 23/08/2018 13:24, Maksim Milyutin wrote:
> I have noticed the novice users are stuck trying to create tablespace
> over a directory whose owner is not the system postgres user. They
> observed the message "could not set permissions on directory ...:
> permission denied".
>
> I want to add patch that prints hint to set required owner for the
> tablespace directory if this is the cause of the problem (*errno ==
> EPERM* after calling *chmod*).
I think the hint is backwards. When you don't have permission to chmod
the tablespace directory, you probably want to fix the permissions on
the tablespace directory or its parent. But the hint says to run the
database server as a different user. That's a bit unusual.
--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: peter.eisentraut@2ndquadrant.com, milyutinma@gmail.com
Subject: Re: Hint to set owner for tablespace directory
In-Reply-To: <1bc2bc14-e42a-8d9c-d47c-3afac05de347@2ndquadrant.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
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