LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > AIX
User Name
Password
AIX This forum is for the discussion of IBM AIX.
eserver and other IBM related questions are also on topic.

Notices


Reply
  Search this Thread
Old 08-10-2015, 12:09 PM   #1
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 3,054

Rep: Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883
AIX relink warning


I've just relinked Oracle Instant Client 12.1's libclntsh.so, it seems working, but I get annoying warnings I'd like not to get.

before
Code:
# dump -H -X64 libclntsh.so.orig
INDEX  PATH                          BASE                MEMBER
0      /ade/b/1630515813/oracle/lib:/usr/lib:/lib:/usr/lib:/lib
1                                    libclntshcore.so
2                                    libc.a              shr_64.o
3                                    libperfstat.a       shr_64.o
4                                    libpthreads.a       shr_xpg5_64.o
5      /                             unix
6                                    libc.a              aio_64.o
7                                    libdl.a             shr_64.o
8                                    libons.so
after
Code:
# dump -H -X64 libclntsh.so
INDEX  PATH                          BASE                MEMBER
0      /usr/lib:/lib
1      /orabin/instantclient/lib64   libons.so
2      /orabin/instantclient/lib64   libclntshcore.so
3      /usr/lib                      libperfstat.a       shr_64.o
4      /usr/lib                      libpthreads.a       shr_xpg5_64.o
5      /usr/lib                      libdl.a             shr_64.o
6      /usr/lib                      libc.a              shr_64.o
7      /usr/lib                      libc.a              aio_64.o
8      /                             unix
process:
Code:
# make libclntsh.so

ld -b64 -r -o libclntsh.o -bnso ../lib/libclntsh.so.orig

explist ../lib/libclntsh.so.orig >libclntsh.exp

ld -b64 -G -bernotok -bnoentry -brtl -bbigtoc -bE:libclntsh.exp -o libclntsh.so \
libclntsh.o \
/orabin/instantclient/lib64/libons.so \
/orabin/instantclient/lib64/libclntshcore.so    \
/usr/lib/libperfstat.a          \
/usr/lib/libpthreads.a          \
/usr/lib/libdl.a                \
/usr/lib/libc.a                 \
-bI:/usr/lib/iocp.exp
ld: 0711-224 WARNING: Duplicate symbol: .bcopy
ld: 0711-224 WARNING: Duplicate symbol: .fsav
ld: 0711-224 WARNING: Duplicate symbol: .fres
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.
ld: 0711-773 WARNING: Object libclntsh.o, imported symbol slts_runmode
        Symbol was expected to be local. Extra instructions
        are being generated to reference the symbol.
ld: 0711-773 WARNING: Object libclntsh.o, imported symbol lxdobl
        Symbol was expected to be local. Extra instructions
        are being generated to reference the symbol.
ld: 0711-773 WARNING: Object libclntsh.o, imported symbol slfitcl
        Symbol was expected to be local. Extra instructions
        are being generated to reference the symbol.
ld: 0711-773 WARNING: Object libclntsh.o, imported symbol slfitlb
        Symbol was expected to be local. Extra instructions
        are being generated to reference the symbol.
ld: 0711-773 WARNING: Object libclntsh.o, imported symbol timezone
        Symbol was expected to be local. Extra instructions
        are being generated to reference the symbol.

echo 'If you are brave enough, you might copy libclntsh.so into ../lib'
If you are brave enough, you might copy libclntsh.so into ../lib
The 0711-773 warnings bug me; google proves than many people got those, but I couldn't find the solution.

Last edited by NevemTeve; 08-10-2015 at 12:15 PM.
 
Old 08-12-2015, 04:26 AM   #2
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 8,799

Rep: Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552
since there was no answer:
version mismatch problem, among libs/headers. Probably one (a few) of those libs were compiled with different flags/headers..
 
1 members found this post helpful.
Old 02-23-2017, 06:39 AM   #3
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 3,054

Original Poster
Rep: Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883
It went worse

I've just found out, that my instantclient!libclntsh.so contains BIO_* entries that should exist in openssl!libcrypto.so
It's quite disturbing.

Here is what's happened to poor PHP:
Code:
$ grep BIO libphp7.so.imports 
[375]   0x00000000    undef      IMP     DS EXTref /opt/lib64/libclntsh.so.12 BIO_printf
[376]   0x00000000    undef      IMP     DS EXTref /opt/lib64/libclntsh.so.12 BIO_free
[377]   0x00000000    undef      IMP     DS EXTref /opt/lib64/libclntsh.so.12 BIO_new
[378]   0x00000000    undef      IMP     DS EXTref /opt/lib64/libclntsh.so.12 BIO_write
[379]   0x00000000    undef      IMP     DS EXTref /opt/lib64/libclntsh.so.12 BIO_ctrl
[380]   0x00000000    undef      IMP     DS EXTref /opt/lib64/libclntsh.so.12 BIO_free_all
[484]   0x00000000    undef      IMP     DS EXTref /usr/local/lib64/libcrypto.so.1.0.2 BIO_puts
[485]   0x00000000    undef      IMP     DS EXTref /usr/local/lib64/libcrypto.so.1.0.2 BIO_s_mem
[486]   0x00000000    undef      IMP     DS EXTref /usr/local/lib64/libcrypto.so.1.0.2 BIO_new_mem_buf
[487]   0x00000000    undef      IMP     DS EXTref /usr/local/lib64/libcrypto.so.1.0.2 BIO_new_file

Last edited by NevemTeve; 02-23-2017 at 08:47 AM.
 
Old 02-23-2017, 08:23 AM   #4
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 3,054

Original Poster
Rep: Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883
A possible fix (part of the Makefile):
Code:
DONT_EXPORT_THESE := ^(BIO_|ERR_|SSLv23_|SSLv3_|TLSv1_|ssl23_|ssl3_|ssl_|tls1_|BZ2_|inflate|deflate)

%.exp_64: ../lib64/%.so.orig
        explist $< >$@.to_prune
        egrep -v '${DONT_EXPORT_THESE}' $@.to_prune >$@

%.exp_32: ../lib32/%.so.orig
        explist $< >$@.to_prune
        egrep -v '${DONT_EXPORT_THESE}' $@.to_prune >$@

Last edited by NevemTeve; 02-23-2017 at 08:46 AM.
 
Old 02-25-2017, 10:19 AM   #5
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 3,054

Original Poster
Rep: Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883
This problem might be related with this: aix6 / 64-bit / Apache / libphp5 / dlopen problem
 
Old 04-26-2017, 04:30 AM   #6
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 3,054

Original Poster
Rep: Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883
I think I should create the export-list this-way:
Code:
dump -Tv -X64 libclntsh.so.orig |
grep ' EXP ' |
while read _ _ _ _ _ _ _ S;
do
    echo "$S"
done |
LC_CYTPE=C sort
 
Old 04-26-2017, 04:42 AM   #7
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 8,799

Rep: Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552Reputation: 2552
that is better with an awk:
Code:
dump | awk '/ EXP / { print $6 }' | sort
 
1 members found this post helpful.
Old 04-27-2017, 09:25 PM   #8
Laserbeak
Member
 
Registered: Jan 2017
Location: Manhattan, NYC NY
Distribution: Mac OS X, iOS, Solaris
Posts: 84

Rep: Reputation: 28
I worked at a company than ran AIX for about a year and I had never-ending problems trying to get things to compile correctly on it. The fact that I didn't have root access and the people that did worked in an office like 2,000 miles away didn't help either!
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mass relink symlinks? homer_3 Linux - General 2 07-07-2009 02:52 PM
WinSCP FTP client connection to AIX gives "host key not found" warning. mufy AIX 2 06-17-2009 12:00 PM
LXer: Java on AIX: Data Collection For AIX Core Dumps LXer Syndicated Linux News 0 05-17-2007 06:46 PM
An question about tethereal.【relink】 operand Linux - Newbie 0 12-21-2005 07:10 PM
How to relink a file ForumKid Linux - General 9 11-09-2002 12:52 PM


All times are GMT -5. The time now is 12:39 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration