- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- DB starting error
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 12:12 AM
тАО11-03-2008 12:12 AM
I am having this peculiar problem that needs some troubleshooting
I hv installed gmake and are trying to compile some postgres code, please find the steps as below:
ln -s /opt/perl_32/lib/5.8.3/PA-RISC1.1-thread-multi/CORE/libperl.so libperl.so
cd /opt/pgsql/src
cd /opt/pgsql/src/postgresql-8.2.4
export CC=cc
export CPP="cc -E +legacy_cpp"
export LIBS="-lkrb5 -lk5crypto -lcom_err"
export LDFLAGS="-Wl,+nodefaultrpath"
./configure --prefix=/opt/iexpress/postgresql --disable-rpath --with-perl --enable-integer-datetimes --with-openssl --libdir=/opt/iexpress/postgresql/lib/hpux32 --without-readline --without-zlib --without-docdir
/usr/local/bin/gmake -f /opt/pgsql/src/postgresql-8.2.4/GNUmakefile all
/usr/local/bin/gmake -f /opt/pgsql/src/postgresql-8.2.4/GNUmakefile install
su - postgres
/opt/iexpress/postgresql/bin/createlang --echo --dbname=vsm --username=postgres plperl
$ /opt/iexpress/postgresql/bin/createlang --echo --dbname=vsm --username=postgres plperl
/usr/lib/dld.sl: Can't open shared library: ../../../src/interfaces/libpq/libpq.sl.5
/usr/lib/dld.sl: No such file or directory
Abort
Please help me with this error. I checked the user rights and also the existence of /usr/lib/dld.sl and /opt/iexpress/postgresql/src/postgresql-8.2.4/src/interfaces/libpq/libpq.sl.5. They are all fine. Please help
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 01:04 AM
тАО11-03-2008 01:04 AM
Re: DB starting error
ln -s /opt/perl_32/lib/5.8.3/PA-RISC1.1-thread-multi/CORE/libperl.sl libperl.sl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 01:18 AM
тАО11-03-2008 01:18 AM
Re: DB starting error
You don't have an absolute path to your shlib.
If you are going to use +nodefaultrpath and not +b, you might want to look to $ORIGIN for relative paths.
>export CPP="cc -E +legacy_cpp"
You can't use +legacy_cpp on PA cc.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 01:35 AM
тАО11-03-2008 01:35 AM
Re: DB starting error
Check that SHLIB_PATH is properly set and that ll libraries needed are on that path variable.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 01:59 AM
тАО11-03-2008 01:59 AM
Re: DB starting error
Thanks for the reply. I have 2 questions.
1. How can I check whether I have absolute path to SHLIB or Not? Because we have set this library path postgres .profile file
export LD_LIBRARY_PATH=/opt/pgsql/lib/:/opt/pgsql/vsm-lib:/usr/lib:/opt/pgsql/lib/hpux32
export libdir=/opt/pgsql/lib
2.If I can't use +legacy_cpp on PA cc, then how can I set the CPP value then? Any idea?
Regarding SHLIB path when I do an chatr on dld.sl I get this value
chatr /usr/lib/dld.sl
/usr/lib/dld.sl:
shared library
shared library dynamic path search:
SHLIB_PATH disabled second
embedded path disabled first Not Defined
shared vtable support disabled
explicit unloading enabled
static branch prediction disabled
executable from stack: D (default)
kernel assisted branch prediction enabled
lazy swap allocation disabled
text segment locking disabled
data segment locking disabled
third quadrant private data space disabled
fourth quadrant private data space disabled
third quadrant global data space disabled
data page size: D (default)
instruction page size: D (default)
nulptr references disabled
shared library private mapping disabled
#
Please let me know as I am not able to enable SHLIB path here.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 03:03 AM
тАО11-03-2008 03:03 AM
Re: DB starting error
What is the -L path you pass to the compiler in your makefile?
>export LD_LIBRARY_PATH
Useless for PA32, only SHLIB_PATH works.
>2. If I can't use +legacy_cpp on PA cc, then how can I set the CPP value then?
Just -E is enough.
>Regarding SHLIB path when I do an chatr on dld.sl
It is useless to do it on dld.sl. You must do it on your executable.
>I am not able to enable SHLIB path here.
To enable it on your executable, you link with "-Wl,+s". Or you can use chatr(1).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 04:43 PM
тАО11-03-2008 04:43 PM
SolutionI tried to build PostgreSQL from source code on HP-UX 11.11.
------------------------------
NOTE: I used the latest HP ANSI C compiler:
% cc -V hello.c -o hello
cpp.ansi: HP92453-01 B.11.11.20 HP C Preprocessor (ANSI)
ccom: HP92453-01 B.11.11.20 HP C Compiler
/usr/ccs/bin/ld: 92453-07 linker linker ld B.11.40 040530
%
Before upgrading to this, I met the following error:
cc -Ae +O2 -I../../../../src/include -D_XOPEN_SOURCE_EXTENDED -c -o elog.o elog.c
cc: error 1405: "/opt/ansic/lbin/ccom" terminated abnormally with signal 11.
------------------------------
Here's my simple steps:
% cd /var/tmp
% gzcat postgresql-8.3.4.tar.gz | tar xvf
% cd postgresql-8.3.4
% env CC=cc CFLAGS="+O2" ./configure \
--without-readline --without-zlib 2>&1 | tee configure.log
% gmake 2>&1 | tee make.log
% gmake check 2>&1 | tee makecheck.log
..(snip)..
=======================
All 114 tests passed.
=======================
gmake[2]: Leaving directory `/var/tmp/postgresql-8.3.4/src/test/regress'
gmake[1]: Leaving directory `/var/tmp/postgresql-8.3.4/src/test'
% su -
# cd /var/tmp/postgresql-8.3.4
# /usr/local/bin/gmake install 2>&1 | tee makeinstall.log
# useradd postgres
# mkdir /usr/local/pgsql/data
# chown postgres:users /usr/local/pgsql/data
# su - postgres
$ export PGDATA=/usr/local/pgsql/data
$ export PGLIB=/usr/local/pgsql/lib
$ export PATH=/usr/local/pgsql/bin:$PATH
% initdb --encoding=EUC_JP --no-locale
$ pg_ctl -w start
$ ps -ef | grep postgres
postgres 21403 21397 0 09:17:43 ? 0:00 postgres: wal writer process
postgres 21404 21397 0 09:17:43 ? 0:00 postgres: autovacuum launcher process
postgres 22263 21937 2 09:40:33 pts/ta 0:00 ps -ef
postgres 21405 21397 0 09:17:43 ? 0:00 postgres: stats collector process
postgres 21397 1 0 09:17:42 pts/ta 0:00 /usr/local/pgsql/bin/postgres
postgres 21402 21397 0 09:17:43 ? 0:00 postgres: writer process
postgres 21937 21922 1 09:32:07 pts/ta 0:00 -sh
postgres 22264 21937 0 09:40:33 pts/ta 0:00 grep postgres
$
$ psql -l
List of databases
Name | Owner | Encoding
-----------+----------+----------
postgres | postgres | EUC_JP
template0 | postgres | EUC_JP
template1 | postgres | EUC_JP
(3 rows)
$ createdb sample
$ psql -l
List of databases
Name | Owner | Encoding
-----------+----------+----------
postgres | postgres | EUC_JP
sample | postgres | EUC_JP
template0 | postgres | EUC_JP
template1 | postgres | EUC_JP
(4 rows)
$
$ chatr /usr/local/pgsql/bin/createdb
/usr/local/pgsql/bin/createdb:
shared executable
shared library dynamic path search:
SHLIB_PATH disabled second
embedded path enabled first /usr/local/pgsql/lib
shared library list:
dynamic ../../../src/interfaces/libpq/libpq.sl.5
dynamic /usr/lib/libxnet.2
dynamic /usr/lib/libm.2
dynamic /usr/lib/libc.2
shared library binding:
..(snip)..
$ ldd /usr/local/pgsql/bin/createdb
/usr/lib/libc.2 => /usr/lib/libc.2
/usr/lib/libdld.2 => /usr/lib/libdld.2
/usr/lib/libc.2 => /usr/lib/libc.2
/usr/lib/libm.2 => /usr/lib/libm.2
/usr/lib/libxnet.2 => /usr/lib/libxnet.2
/usr/lib/libxti.2 => /usr/lib/libxti.2
../../../src/interfaces/libpq/libpq.sl.5 => /usr/local/pgsql/lib/libpq.sl.5
$ ldd /usr/local/pgsql/bin/createlang
/usr/lib/libc.2 => /usr/lib/libc.2
/usr/lib/libdld.2 => /usr/lib/libdld.2
/usr/lib/libc.2 => /usr/lib/libc.2
/usr/lib/libm.2 => /usr/lib/libm.2
/usr/lib/libxnet.2 => /usr/lib/libxnet.2
/usr/lib/libxti.2 => /usr/lib/libxti.2
../../../src/interfaces/libpq/libpq.sl.5 => /usr/local/pgsql/lib/libpq.sl.5
$
I didn't specify "--with-perl" to the configure script. But it
seems to me my PostgreSQL is working well.
I hope this helps you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 06:46 PM
тАО11-03-2008 06:46 PM
Re: DB starting error
Lots of thanks for your help. It has made my understanding better.
Terajito, for you I have one question when I performed the last steps as given by you:
1. chatr /usr/bin/createdb - I got the same result as you.
2. But in the next step
ldd /usr/bin/createdb - The o/p I got is:
/usr/lib/libc.2 => /usr/lib/libc.2
/usr/lib/libdld.2 => /usr/lib/libdld.2
/usr/lib/libc.2 => /usr/lib/libc.2
/usr/lib/libcom_err.sl => /usr/lib/libcom_err.sl
/usr/lib/libk5crypto.sl => /usr/lib/libk5crypto.sl
/usr/lib/libkrb5.sl => /usr/lib/libkrb5.sl
/usr/lib/libcom_err.sl => /usr/lib/libcom_err.sl
/usr/lib/libk5crypto.sl => /usr/lib/libk5crypto.sl
/usr/lib/libm.2 => /usr/lib/libm.2
/usr/lib/libcrypto.sl.0 => /usr/lib/libcrypto.sl.0
/usr/lib/libc.2 => /usr/lib/libc.2
/usr/lib/libdld.2 => /usr/lib/libdld.2
/usr/lib/libssl.sl.0 => /usr/lib/libssl.sl.0
/usr/lib/libdld.2 => /usr/lib/libdld.2
/usr/lib/libxnet.2 => /usr/lib/libxnet.2
/usr/lib/libxti.2 => /usr/lib/libxti.2
/usr/lib/dld.sl: Can't open shared library: ../../../src/interfaces/libpq/libpq.sl.5
/usr/lib/dld.sl: No such file or directory
Please notice the last two lines. They are throwing some error. It is the same case with /usr/bin/createlang.
Please let me know your suggestions.
Regards,
Sutapa
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 07:54 PM
тАО11-03-2008 07:54 PM
Re: DB starting error
You should not have. You should have /opt/iexpress/postgresql/lib/hpux32 as the embedded path because you specify the directory as --libdir and your libpq.sl is present there.
Can you remove the configuration for LDFLAGS="-Wl,+nodefaultrpath" ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-03-2008 11:20 PM
тАО11-03-2008 11:20 PM
Re: DB starting error
This will obviously make it work. I.e. if it found it at link time, it will still be there at runtime, if on the same machine or shlib layout.