Re: BUG #15265: The program "initdb" is needed by pg_ctl but was not found in the same directory as "pg_ctl".

From: "Aaron W(dot) Swenson" <titanofold(at)gentoo(dot)org>
To: Mohammed Shahid Nawaz <mohammedshahid(dot)r(at)gmail(dot)com>
Cc: pgsql-bugs(at)lists(dot)postgresql(dot)org, PG Bug reporting form <noreply(at)postgresql(dot)org>
Subject: Re: BUG #15265: The program "initdb" is needed by pg_ctl but was not found in the same directory as "pg_ctl".
Date: 2018-07-09 09:54:22
Message-ID: 20180709095422.GB11978@martineau.grandmasfridge.local
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On 2018-07-09 14:24, Mohammed Shahid Nawaz wrote:
> Hello Everyone,
> Can anyone help me with this issue? As this is being a road block for me,
> where I am able to run the commands in non-root login, but not from root
> with sudo or su command.
> Requesting help at the earliest.
> Thanks in Advance. I
>
> Shahid

It’s probably because /root has its access restricted to just the root
user, so the shahid user can’t get past that first part of the path.

Further, it’s atypical to allow users to do anything inside /root. You should
probably work under /usr/local or in /home/shahid/.

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Mohammed Shahid Nawaz 2018-07-09 09:59:50 Re: BUG #15265: The program "initdb" is needed by pg_ctl but was not found in the same directory as "pg_ctl".
Previous Message Mohammed Shahid Nawaz 2018-07-09 08:54:14 Re: BUG #15265: The program "initdb" is needed by pg_ctl but was not found in the same directory as "pg_ctl".