Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id A4D9F475AD7 for ; Mon, 18 Nov 2002 05:46:43 -0500 (EST) Received: from anchor-post-35.mail.demon.net (anchor-post-35.mail.demon.net [194.217.242.85]) by postgresql.org (Postfix) with ESMTP id 896B54758BD for ; Mon, 18 Nov 2002 05:46:41 -0500 (EST) Received: from lfix.demon.co.uk ([158.152.59.127] helo=linda.lfix.co.uk) by anchor-post-35.mail.demon.net with esmtp (Exim 3.36 #2) id 18DjQM-0001Ir-0U; Mon, 18 Nov 2002 10:46:39 +0000 Received: from localhost ([127.0.0.1] helo=localhost.localdomain ident=olly) by linda.lfix.co.uk with esmtp (Exim 3.36 #1 (Debian)) id 18DjQM-0000i5-00; Mon, 18 Nov 2002 10:46:38 +0000 Subject: Re: Problems invoking psql. Help please. From: Oliver Elphick To: jasiek@klaster.net Cc: Tom Lane , Hugh Esco , pgsql-sql@postgresql.org In-Reply-To: <20021117202404.GA1040@serwer> References: <5.1.0.14.0.20021116140623.031cbec0@petra.cagreens.org> <5855.1037560617@sss.pgh.pa.us> <20021117202404.GA1040@serwer> Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Mailer: Ximian Evolution 1.0.8 Date: 18 Nov 2002 10:46:38 +0000 Message-Id: <1037616398.31109.1177.camel@linda> Mime-Version: 1.0 X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200211/257 X-Sequence-Number: 10399 On Sun, 2002-11-17 at 20:24, jasiek@klaster.net wrote: > > You seem to have a very bizarre setup there --- there is no such thing > > as "readpgenv" in the standard Postgres distribution, and > > /usr/lib/postgresql/bin/ isn't the standard place to put the executable > > files either. Perhaps the above is normal for the Debian package of > > Postgres, but I'm afraid you'll have to ask the Debian packager for > > help. Nobody using other platforms is likely to be able to help... > I have Debian and Postgres installed from .deb package. Postgres is > installed in /usr/lib/postgresql by default and it contains readpgenv. > Psql stops working as described, when I remove executable attribute > from readpgenv. readpgenv is a bash script and has only 3 lines: > #!/bin/bash > . /etc/postgresql/postgresql.env > env > > postgresql.env file is an export of PGDATA/PGLIB/PGACCES_HOME variables Yes. The reaon for its existence is that Debian policy prohibits reliance on environmental variables, so I jump through this hoop to read them from a predictable location (if they are not already set). Permissions on /usr/lib/postgresql/bin/readpgenv should be 755. How did they get unset? -- Oliver Elphick Oliver.Elphick@lfix.co.uk Isle of Wight, UK http://www.lfix.co.uk/oliver GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839 932A 614D 4C34 3E1D 0C1C ======================================== "A Song for the sabbath day. It is a good thing to give thanks unto the LORD, and to sing praises unto thy name, O most High." Psalms 92:1