Re: BUG #1072: "$libdir/ascii_and_mic": No such file or directory

From: "Thomas Borg Salling" <tbs(at)navicon(dot)dk>
To: "'Tom Lane'" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "'PostgreSQL Bugs List'" <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: BUG #1072: "$libdir/ascii_and_mic": No such file or directory
Date: 2004-02-02 17:30:36
Message-ID: 001b01c3e9b2$4538b2a0$0101000a@Umulius
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hi again,

Running ldd as postgres yields the same as root:

[postgres(at)hubertus postgres]$ ldd /opt/postgres-7.4.1/lib/ascii_and_mic.so
libc.so.6 => /lib/i686/libc.so.6 (0x42000000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)

the problem occurs when initdb tries to run the conversion_create.sql
script:

# Create pg_conversion and support functions

$ECHO_N "creating conversions... "$ECHO_C
grep -v '^DROP CONVERSION' $datadir/conversion_create.sql |
"$PGPATH"/postgres $PGSQL_OPT template1 > /dev/null || exit_nicely
echo "ok"

for some reason - conversion_create.sql the $libdir is not defined. I tried
to print $libdir from bin/initdb, but this variable is empty. $datadir,
however, is correctly set to /opt/postgres-7.4.1//share.

The following envvars are correctly set for user 'postgres':

export PATH=/opt/postgres-7.4.1/bin:${PATH}
export LD_LIBRARY_PATH=/opt/postgres-7.4.1/lib:${LD_LIBRARY_PATH}
export MANPATH=/opt/postgres-7.4.1/man:${MANPATH}
export PGHOST=localhost
export PGPORT=5432

Hmmm.... ?!

Best regards,
Thomas.

-----Original Message-----
From: pgsql-bugs-owner(at)postgresql(dot)org
[mailto:pgsql-bugs-owner(at)postgresql(dot)org] On Behalf Of Tom Lane
Sent: Monday, February 02, 2004 6:19 PM
To: Thomas Borg Salling
Cc: 'PostgreSQL Bugs List'
Subject: Re: [BUGS] BUG #1072: "$libdir/ascii_and_mic": No such file or
directory

"Thomas Borg Salling" <tbs(at)navicon(dot)dk> writes:
> ascii_and_mic.so lives i /opt/postgres-7.4.1/lib, and ldd yields:

> [root(at)hubertus lib]# ldd ascii_and_mic.so=20
> libc.so.6 =3D> /lib/i686/libc.so.6 (0x42000000)
> /lib/ld-linux.so.2 =3D> /lib/ld-linux.so.2 (0x80000000)

Hmm, nothing wrong with the library file itself then. So why isn't
initdb able to load it? The only thing I can think of is some
environment difference between your postgres account and your root
account that affects dynamic linking. Better look at LD_LIBRARY_PATH
discrepancies, for instance. You might try running ldd as postgres
instead of root to see if it gives a different answer. Also you might
want to add /opt/postgres-7.4.1/lib/ to your ldconfig search path.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faqs/FAQ.html

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Hamedany, Allen 2004-02-02 17:53:56 createdb fails
Previous Message Tom Lane 2004-02-02 17:18:59 Re: BUG #1072: "$libdir/ascii_and_mic": No such file or directory