Re: create tablespace fails silently, or succeeds improperly

From: Stephen Frost <sfrost(at)snowman(dot)net>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Bruce Momjian <bruce(at)momjian(dot)us>, Dave Cramer <pg(at)fastcrypt(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: create tablespace fails silently, or succeeds improperly
Date: 2010-12-11 04:17:21
Message-ID: 20101211041721.GJ26232@tamriel.snowman.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

* Robert Haas (robertmhaas(at)gmail(dot)com) wrote:
> On Fri, Dec 10, 2010 at 10:33 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> > Anybody have a problem with adopting this behavior?
>
> Seems a bit surprising.

Yeahh.. I'm not really sure about mkdir -p type actions from a SQL
command. Not entirely sure why but it doesn't feel 'right' to me. I'd
rather have PG complain "that directory doesn't exist". It's not a
terribly strong feeling though, more of a "that's kind of suprising",
since, as you point out, PG would have to have the necessary permissions
to create the directories, and I know that it probably wouldn't on
systems that I set up, but I don't really like relying on the FS
permissions to realize something like this was happening...

At the end of the day, I think you'll get people who will see a
permission denied and go "oh, I need to grant PG rights to mkdir in /,
sure, why not", even though that might mean creating a directory on a
small root FS which will then run out of space quickly...

Just my 2c.

Stephen

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Stephen Frost 2010-12-11 04:19:53 Re: Anyone for SSDs?
Previous Message Robert Haas 2010-12-11 04:16:20 Re: unlogged tables