Re: Permission denied error for initdb - Mailing list pgsql-novice

From Tom Lane
Subject Re: Permission denied error for initdb
Date
Msg-id 26460.1479913119@sss.pgh.pa.us
Whole thread Raw
In response to Permission denied error for initdb  (Tom Dron <thomas.e.dron@gmail.com>)
Responses Re: Permission denied error for initdb  (Tom Dron <thomas.e.dron@gmail.com>)
List pgsql-novice
Tom Dron <thomas.e.dron@gmail.com> writes:
> fbbgsa@web1:~/.local$ initdb -D ~/.local/data
> ...
> creating template1 database in /home/.local/data/base/1 ... FATAL:
>  shmat(id=18808835) failed: Permission denied

That's really weird.  Usually problems appear at the preceding shmget
call, not shmat.  I'd guess that somehow the System V shared memory
facility is turned off on that machine, but surely it'd fail at shmget
if so.  Still, it might be informative to do "sysctl -a | grep shm"
and see what the shmmax/shmall/shmmni parameters are set to.

Also, I gather from the printout that this isn't a terribly late-model
Postgres.  If you could try 9.4 or later, that might conceivably have
better luck because it requires only a very small SysV segment.
(This error doesn't sound like it's dependent on segment size, but
I'm grasping at straws...)

            regards, tom lane


pgsql-novice by date:

Previous
From: Tom Dron
Date:
Subject: Permission denied error for initdb
Next
From: Tom Dron
Date:
Subject: Re: Permission denied error for initdb