Обсуждение: Encountering errors while using pg_ctl

Поиск
Список
Период
Сортировка

Encountering errors while using pg_ctl

От
"Ali, Luqman"
Дата:
Hi All,

We're using postgresql v.8.0.4 on a RHEL ES 4. Its newly installed by my
sys-admin and when trying to use pg_ctl I get this error:

[postgres@hsvxto pgsql]$ pg_ctl -D /usr/local/pgsql/data stop -l log
The programs "postmaster" and "psql" are needed by pg_ctl but
were not found in the directory "/usr/bin".
Check your installation.

Postmaster is currently running and both psql and postmaster is there.
Tried searching the archives but had no luck.. Am I missing something
here?


---Best Regards

Luqman B Mohd Ali

CONFIDENTIALITY
This e-mail message and any attachments thereto, is intended only for use by the addressee(s) named herein and may
containlegally privileged and/or confidential information. If you are not the intended recipient of this e-mail
message,you are hereby notified that any dissemination, distribution or copying of this e-mail message, and any
attachmentsthereto, is strictly prohibited.  If you have received this e-mail message in error, please immediately
notifythe sender and permanently delete the original and any copies of this email and any prints thereof. 
ABSENT AN EXPRESS STATEMENT TO THE CONTRARY HEREINABOVE, THIS E-MAIL IS NOT INTENDED AS A SUBSTITUTE FOR A WRITING.
Notwithstandingthe Uniform Electronic Transactions Act or the applicability of any other law of similar substance and
effect,absent an express statement to the contrary hereinabove, this e-mail message its contents, and any attachments
heretoare not intended to represent an offer or acceptance to enter into a contract and are not otherwise intended to
bindthe sender, Sanmina-SCI Corporation (or any of its subsidiaries), or any other person or entity. 
_____________________________________________________________________________
Scanned by Sanmina-SCI eShield  _____________________________________________________________________________

Re: Encountering errors while using pg_ctl

От
"Phillip Smith"
Дата:
> [postgres@hsvxto pgsql]$ pg_ctl -D /usr/local/pgsql/data stop -l log
> The programs "postmaster" and "psql" are needed by pg_ctl but
> were not found in the directory "/usr/bin".
> Check your installation.

Where did you install Postgres to? Did you install a binary package or
compile from source?

You may just need to sym link postmaster and psql into /usr/bin/ from their
actual location - probably something like /usr/local/postgres/bin/

Cheers,
~p


*******************Confidentiality and Privilege Notice*******************

The material contained in this message is privileged and confidential to
the addressee.  If you are not the addressee indicated in this message or
responsible for delivery of the message to such person, you may not copy
or deliver this message to anyone, and you should destroy it and kindly
notify the sender by reply email.

Information in this message that does not relate to the official business
of Weatherbeeta must be treated as neither given nor endorsed by Weatherbeeta.
Weatherbeeta, its employees, contractors or associates shall not be liable
for direct, indirect or consequential loss arising from transmission of this
message or any attachments

Re: Encountering errors while using pg_ctl

От
"Ali, Luqman"
Дата:
Phillip,



As you can see it,


> Where did you install Postgres to? Did you install a binary package or
> compile from source?
Its from a binary source. The files are in various places but $PGDATA
will be in /usr/local/pgsql. Someone else did the installation.

>You may just need to sym link postmaster and psql into /usr/bin/ from
their
>actual location - probably something like /usr/local/postgres/bin/

[postgres@hsvxto pgsql]$ ls -al /usr/bin/pg_ctl
-rwxr-xr-x  1 root root 10214 May 10  2005 /usr/bin/pg_ctl
[postgres@hsvxto pgsql]$ ls -la /usr/bin/postmaster /usr/bin/psql
lrwxrwxrwx  1 root root      8 Jun 26  2006 /usr/bin/postmaster ->
postgres
-rwxr-xr-x  1 root root 165336 May 10  2005 /usr/bin/psql

Its actually in /usr/bin itself.


CONFIDENTIALITY
This e-mail message and any attachments thereto, is intended only for use by the addressee(s) named herein and may
containlegally privileged and/or confidential information. If you are not the intended recipient of this e-mail
message,you are hereby notified that any dissemination, distribution or copying of this e-mail message, and any
attachmentsthereto, is strictly prohibited.  If you have received this e-mail message in error, please immediately
notifythe sender and permanently delete the original and any copies of this email and any prints thereof. 
ABSENT AN EXPRESS STATEMENT TO THE CONTRARY HEREINABOVE, THIS E-MAIL IS NOT INTENDED AS A SUBSTITUTE FOR A WRITING.
Notwithstandingthe Uniform Electronic Transactions Act or the applicability of any other law of similar substance and
effect,absent an express statement to the contrary hereinabove, this e-mail message its contents, and any attachments
heretoare not intended to represent an offer or acceptance to enter into a contract and are not otherwise intended to
bindthe sender, Sanmina-SCI Corporation (or any of its subsidiaries), or any other person or entity. 
_____________________________________________________________________________
Scanned by Sanmina-SCI eShield  _____________________________________________________________________________

Re: Encountering errors while using pg_ctl

От
"Ali, Luqman"
Дата:
All,

I realize what the problem is. Somehow multiple versions on pg_ctl
exists...

[postgres@hsvxto pgsql]$ find / -name pg_ctl -print 2>/dev/null
/usr/bin/pg_ctl
/usr/local/pgsql/bin/pg_ctl
/opt/postgresql-8.0.4/src/bin/pg_ctl
/opt/postgresql-8.0.4/src/bin/pg_ctl/pg_ctl
[postgres@hsvxto pgsql]$ ls -la /usr/bin/pg_ctl
-rwxr-xr-x  1 root root 10214 May 10  2005 /usr/bin/pg_ctl

Sigh... I have to clean this up then. I wonder if this means that there
are multiple versions of postgres...Anyway thank you for the help
Phillip.

Best regards,
Luqman.

CONFIDENTIALITY
This e-mail message and any attachments thereto, is intended only for use by the addressee(s) named herein and may
containlegally privileged and/or confidential information. If you are not the intended recipient of this e-mail
message,you are hereby notified that any dissemination, distribution or copying of this e-mail message, and any
attachmentsthereto, is strictly prohibited.  If you have received this e-mail message in error, please immediately
notifythe sender and permanently delete the original and any copies of this email and any prints thereof. 
ABSENT AN EXPRESS STATEMENT TO THE CONTRARY HEREINABOVE, THIS E-MAIL IS NOT INTENDED AS A SUBSTITUTE FOR A WRITING.
Notwithstandingthe Uniform Electronic Transactions Act or the applicability of any other law of similar substance and
effect,absent an express statement to the contrary hereinabove, this e-mail message its contents, and any attachments
heretoare not intended to represent an offer or acceptance to enter into a contract and are not otherwise intended to
bindthe sender, Sanmina-SCI Corporation (or any of its subsidiaries), or any other person or entity. 
_____________________________________________________________________________
Scanned by Sanmina-SCI eShield  _____________________________________________________________________________