Re: initdb error: "could not identify current directory" (or, what have i done now?)

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: initdb error: "could not identify current directory" (or, what have i done now?)
Дата
Msg-id 17222.1102122182@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: initdb error: "could not identify current directory" (or,  (OpenMacNews <pgsql-general.20.openmacnews@spamgourmet.com>)
Ответы Re: initdb error: "could not identify current directory" (or,
Re: initdb error: "could not identify current directory" (or,
Список pgsql-general
OpenMacNews <pgsql-general.20.openmacnews@spamgourmet.com> writes:
> then, i stumbled across the following behavior.:

> % rm -rf /var/data/pgsql /Volumes/data/pgsql

> % ls -ald /var/data/pgsql
>     lrwxr-xr-x  1 root wheel 27 Nov 22 20:26 /var/data/pgsql -> /Volumes/data/pgsql

> % ls -ald /Volumes/data/pgsql
>     drwxrwxr-x  12 testuser testuser 408 Nov 25 09:12 /Volumes/data/pgsql

Huh?  Why didn't the rm -rf remove both of those?  Or are you skipping
some steps?

> % cd /var/data/pgsql
> % pwd
>     /Volumes/data/pgsql

This is odd ... when I do pwd I see the path as it was told to cd.  I
have to say /bin/pwd to get what you're showing.

> % sudo -u testuser /usr/local/pgsql/bin/initdb --pgdata=/var/data/pgsql
> --username=testuser

> IT CHOKES.

Couldn't reproduce this, using fully up-to-date 10.3.6.

The man page for getcwd does say that it will fail with EACCES (ie,
"permission denied") if any component of the path is unreadable.
You didn't show us all the steps of the paths /private/var/data and
/Volumes/data ... maybe there's a non-world-readable directory involved?

            regards, tom lane

В списке pgsql-general по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: pgsql8b5 not launching on OSX system start; otherwise OK
Следующее
От: OpenMacNews
Дата:
Сообщение: Re: pgsql8b5 not launching on OSX system start; otherwise OK