Thread: TSearch2 FreeBSD

TSearch2 FreeBSD

From
Matthew Terenzio
Date:
Anyone with any TSearch2 experience on FreeBSD? Any known Gotchas?
Postgres 7.3

Postgres is working fine and the Port for contrib seemed to install
okay. tsearch2.so is indeed in the below directory and permissions look
right.

$ psql database < tsearch2.sql
SET
BEGIN
NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index
'pg_ts_dict_pkey' for table 'pg_ts_dict'
CREATE TABLE
ERROR:  Load of file /usr/local/lib/postgresql/tsearch2.so failed:
dlopen '/usr/local/lib/postgresql/tsearch2.so' failed.
(/usr/local/lib/postgresql/tsearch2.so: Undefined symbol
"errcode_for_file_access")
ERROR:  current transaction is aborted, queries ignored until end of
transaction block
ERROR:  current transaction is aborted, queries ignored until end of
transaction block

Thanks


Re: TSearch2 FreeBSD

From
Tom Lane
Date:
Matthew Terenzio <matt@jobsforge.com> writes:
> Anyone with any TSearch2 experience on FreeBSD? Any known Gotchas?
> Postgres 7.3

> ERROR:  Load of file /usr/local/lib/postgresql/tsearch2.so failed:
> dlopen '/usr/local/lib/postgresql/tsearch2.so' failed.
> (/usr/local/lib/postgresql/tsearch2.so: Undefined symbol
> "errcode_for_file_access")

This tsearch2 code seems to be intended for PG 7.4 or later.

            regards, tom lane

Re: TSearch2 FreeBSD

From
Matthew Terenzio
Date:
On Mar 25, 2005, at 9:28 PM, Tom Lane wrote:

> Matthew Terenzio <matt@jobsforge.com> writes:
>> Anyone with any TSearch2 experience on FreeBSD? Any known Gotchas?
>> Postgres 7.3
>
>> ERROR:  Load of file /usr/local/lib/postgresql/tsearch2.so failed:
>> dlopen '/usr/local/lib/postgresql/tsearch2.so' failed.
>> (/usr/local/lib/postgresql/tsearch2.so: Undefined symbol
>> "errcode_for_file_access")
>
> This tsearch2 code seems to be intended for PG 7.4 or later.

Oh I see what you mean Tom. The postgresql-contrib is code for 7.4







>
>             regards, tom lane
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
>       subscribe-nomail command to majordomo@postgresql.org so that your
>       message can get through to the mailing list cleanly
>


Re: TSearch2 FreeBSD

From
Michael Fuhr
Date:
On Fri, Mar 25, 2005 at 09:18:27PM -0500, Matthew Terenzio wrote:
>
> Anyone with any TSearch2 experience on FreeBSD? Any known Gotchas?
> Postgres 7.3

I use tsearch2 with PostgreSQL 8.0.1 (built from CVS source) on
FreeBSD 4.11-STABLE.  No problems.

> ERROR:  Load of file /usr/local/lib/postgresql/tsearch2.so failed:
> dlopen '/usr/local/lib/postgresql/tsearch2.so' failed.
> (/usr/local/lib/postgresql/tsearch2.so: Undefined symbol
> "errcode_for_file_access")

I don't think the stock tsearch2 works with 7.3.  The CVS tree for
REL7_3_STABLE doesn't include tsearch2, and the tsearch2 source
code in later branches includes a call to errcode_for_file_access(),
which appears to have been introduced in 7.4.

There appears to be a version of tsearch2 for 7.3 on the tsearch2
home page:

http://www.sai.msu.su/~megera/postgres/gist/tsearch/V2/

Is there a reason you're using PostgreSQL 7.3 instead of upgrading
to a newer release?

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/