Symbol resolution failed error on AIX

Issue #1105 open
Lutz Mader created an issue

An information to AIX user!

Monit (version 3.34.0) does not start, you get an error message to an unresolved symbol only.

~/monit/bin/monit summary
exec(): 0509-036 Cannot load program /home/was12345/monit/bin/monit because of the following errors:
        0509-130 Symbol resolution failed for monit because:
        0509-136   Symbol __atomic_is_lock_free (number 257) is not exported from
                   dependent module /usr/lib/libatomic.a(libatomic.so.1).
        0509-192 Examine .loader section symbols with the
                 'dump -Tv' command.

The shared library "libatomic.a" from the XLC package cannot be used and is not compatible with the bound shared library "libatomic.a" from the GCC Shared Support Library package.

The shared libraries "libatomic.a" and "libgcc_s.a" (from the “libgcc” RPM package) are used by OpenSSL 3.0.13 and OpenSSL libraries are static bind to Monit.

The LIBPATH must be adapted so, that the library "/opt/freeware/lib/libatomic.a" is found before the library "/usr/lib/libatomic.a" (set library path e.g. with "export LIBPATH=/opt/freeware/lib").

With regards,
Lutz

p.s.

The GCC Shared Support Library package (“libgcc” RPM package) is available via site "The official site for downloading GNU and open source tool packages for AIX",
see https://www.ibm.com/developerworks/aix/library/aix-toolbox/alpha.html

p.s.

The Libraries used by OpenSSL 3.0.13 and Monit 5.34.0.

You can check the used shared libraries with the LDD command, LDD should list the following libraries (check the path/location of the libraries also).

ldd monit/bin/monit
monit/bin/monit needs:
         /usr/lib/libc.a(shr.o)
         /usr/lib/libpthread.a(shr_xpg5.o)
         /usr/lib/libnsl.a(shr.o)
         /opt/freeware/lib/libatomic.a(libatomic.so.1)  <<== from libgcc
         /usr/lib/libpthread.a(shr_comm.o)
         /usr/lib/libperfstat.a(shr.o)
         /usr/lib/libpam.a(shr.o)
         /unix
         /usr/lib/libcrypt.a(shr.o)
         /usr/lib/libpthreads.a(shr_comm.o)
         /usr/lib/libthread.a(shr.o)
         /usr/lib/libpthreads_compat.a(shr.o)
         /usr/lib/libpthreads.a(shr_xpg5.o)
         /usr/lib/libtli.a(shr.o)
         /opt/freeware/lib/libgcc_s.a(shr.o)  <<== from libgcc
         /usr/lib/libcfg.a(shr.o)
         /usr/lib/libodm.a(shr.o)
         /usr/lib/liblvm.a(shr.o)
         /usr/lib/libcorcfg.a(shr.o)
         /usr/lib/libmls.a(shr.o)
         /usr/lib/libpthreads.a(shr.o)
         /usr/lib/libc.a(pse.o)
         /usr/lib/libsrc.a(shr.o)
         /usr/lib/libmlsenc.a(shr.o)

If the LDD command does not find the proper libraries, you should use a proper LIBPATH and check the available libraries.

ldd monit/bin/monit
monit/bin/monit needs:
         /usr/lib/libc.a(shr.o)
         /usr/lib/libpthread.a(shr_xpg5.o)
         /usr/lib/libnsl.a(shr.o)
         /usr/lib/libatomic.a(libatomic.so.1)  <<== XLC library
         /usr/lib/libpthread.a(shr_comm.o)
         /usr/lib/libperfstat.a(shr.o)
         /usr/lib/libpam.a(shr.o)
         /unix
         /usr/lib/libcrypt.a(shr.o)
         /usr/lib/libpthreads.a(shr_comm.o)
         /usr/lib/libthread.a(shr.o)
         /usr/lib/libpthreads_compat.a(shr.o)
         /usr/lib/libpthreads.a(shr_xpg5.o)
         /usr/lib/libtli.a(shr.o)
         /usr/lib/libcfg.a(shr.o)
         /usr/lib/libodm.a(shr.o)
         /usr/lib/liblvm.a(shr.o)
         /usr/lib/libcorcfg.a(shr.o)
         /usr/lib/libmls.a(shr.o)
         /usr/lib/libpthreads.a(shr.o)
         /usr/lib/libc.a(pse.o)
         /usr/lib/libsrc.a(shr.o)
         /usr/lib/libmlsenc.a(shr.o)

The missing libraries are available in the "libgcc" package.

Comments (5)

  1. Log in to comment