Thread: problems loading languages

problems loading languages

From
Mija Lee
Date:
Hi folks:

I am doing a fresh install of 8.2.4 and have been having problems with language
support.

This is what I know:

- pg has been configured --with perl
- the libdir is /usr/lib
- there are plpgsql.so and plperl.so in the libdir
- I get this:

postgres=# create language plperl;
ERROR:  could not access file "$libdir/plperl": No such file or directory

but other languages work fine:

postgres=# create language plpgsql;
CREATE LANGUAGE

My end goal is to be able to load the following function into template1:

CREATE FUNCTION plperl_call_handler() RETURNS language_handler
    AS '$libdir/plperl', 'plperl_call_handler'
    LANGUAGE c;

At least that's what the developers are telling me. This also gets the error
about $libdir/plperl. Any ideas about what I'm doing wrong?

Thanks so much!
Mija


Re: problems loading languages

From
Tom Lane
Date:
Mija Lee <mija@scharp.org> writes:
> - pg has been configured --with perl
> - the libdir is /usr/lib
> - there are plpgsql.so and plperl.so in the libdir
> - I get this:

> postgres=# create language plperl;
> ERROR:  could not access file "$libdir/plperl": No such file or directory

I rather doubt that libdir is /usr/lib.  It's much more likely to have
"postgres" or "postgresql" in the path somewhere.  "pg_config --pkglibdir"
would tell you for sure.

            regards, tom lane

Re: problems loading languages

From
Mija Lee
Date:
Tom:

you are right. I was looking at another install of pg 8.1 which used the solaris
packages. So as it turns out the solaris-package 8.1 was pointing to /usr/lib
and my new 8.2 is pointing to /systems/pg8.2/lib, and the plperl did not exist
in the second directory.

Thank you so much for your help!

Mija


>X-Spam-Level:
>X-Spam-Status: No, score=0.5 required=5.0 tests=AWL,URI_NOVOWEL autolearn=no
version=3.1.3
>X-Greylist: from auto-whitelisted by SQLgrey-1.7.5
>To: Mija Lee <mija@scharp.org>
>cc: pgsql-novice@postgresql.org
>Subject: Re: [NOVICE] problems loading languages
>Comments: In-reply-to Mija Lee <mija@scharp.org> message dated "Tue, 11 Sep
2007 08:55:12 -0700"
>Date: Tue, 11 Sep 2007 14:40:19 -0400
>From: Tom Lane <tgl@sss.pgh.pa.us>
>X-Virus-Scanned: Maia Mailguard 1.0.1
>List-Archive: <http://archives.postgresql.org/pgsql-novice>
>List-Help: <mailto:majordomo@postgresql.org?body=help>
>List-ID: <pgsql-novice.postgresql.org>
>List-Owner: <mailto:pgsql-novice-owner@postgresql.org>
>List-Post: <mailto:pgsql-novice@postgresql.org>
>List-Subscribe: <mailto:majordomo@postgresql.org?body=sub%20pgsql-novice>
>List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-novice>
>
>Mija Lee <mija@scharp.org> writes:
>> - pg has been configured --with perl
>> - the libdir is /usr/lib
>> - there are plpgsql.so and plperl.so in the libdir
>> - I get this:
>
>> postgres=# create language plperl;
>> ERROR:  could not access file "$libdir/plperl": No such file or directory
>
>I rather doubt that libdir is /usr/lib.  It's much more likely to have
>"postgres" or "postgresql" in the path somewhere.  "pg_config --pkglibdir"
>would tell you for sure.
>
>            regards, tom lane
>
>---------------------------(end of broadcast)---------------------------
>TIP 5: don't forget to increase your free space map settings