[External] : Re: [RFC][PATCH v11 0/7] Implementation of RTLD_SHARED for dlmopen

Alfonso Alfonso Peterssen alfonso.peterssen@oracle.com
Wed Jun 16 13:08:07 GMT 2021


I'm testing these patches for our use case in GraalVM. We use dlmopen to load several isolated JVMs within the same process.

With the patches I'm hitting the following error:
Inconsistency detected by ld.so: dl-version.c: 205: _dl_check_map_versions: Assert
ion `needed != NULL' failed!

Here's the tail of the LD_DEBUG=all log:
   222389:       trying file=./nptl/tls/x86_64/libpthread.so.0
   222389:       trying file=./nptl/tls/libpthread.so.0
   222389:       trying file=./nptl/x86_64/x86_64/libpthread.so.0
   222389:       trying file=./nptl/x86_64/libpthread.so.0
   222389:       trying file=./nptl/x86_64/libpthread.so.0
   222389:       trying file=./nptl/libpthread.so.0
   222389:
   222389:     checking for version `GLIBC_2.2.5' in file ./dlfcn/libdl.so.2 [0]
required by file /home/mukel/Desktop/graal/graal/sdk/mxbuild/linux-amd64/GRAALVM_E
SPRESSO_JVM_EE_JAVA11/graalvm-espresso-jvm-ee-java11-21.2.0-dev/lib/libnio.so [1]
   222389:     checking for version `GLIBC_2.2.5' in file ./nptl/libpthread.so.0
[0] required by file /home/mukel/Desktop/graal/graal/sdk/mxbuild/linux-amd64/GRAAL
VM_ESPRESSO_JVM_EE_JAVA11/graalvm-espresso-jvm-ee-java11-21.2.0-dev/lib/libnio.so
[1]
   222389:     checking for version `GLIBC_2.3' in file ./libc.so.6 [0] required
by file /home/mukel/Desktop/graal/graal/sdk/mxbuild/linux-amd64/GRAALVM_ESPRESSO_J
VM_EE_JAVA11/graalvm-espresso-jvm-ee-java11-21.2.0-dev/lib/libnio.so [1]
   222389:     checking for version `GLIBC_2.3.2' in file ./libc.so.6 [0] require
d by file /home/mukel/Desktop/graal/graal/sdk/mxbuild/linux-amd64/GRAALVM_ESPRESSO
_JVM_EE_JAVA11/graalvm-espresso-jvm-ee-java11-21.2.0-dev/lib/libnio.so [1]
   222389:     checking for version `GLIBC_2.4' in file ./libc.so.6 [0] required
by file /home/mukel/Desktop/graal/graal/sdk/mxbuild/linux-amd64/GRAALVM_ESPRESSO_J
VM_EE_JAVA11/graalvm-espresso-jvm-ee-java11-21.2.0-dev/lib/libnio.so [1]
   222389:     checking for version `GLIBC_2.2.5' in file ./libc.so.6 [0] require
d by file /home/mukel/Desktop/graal/graal/sdk/mxbuild/linux-amd64/GRAALVM_ESPRESSO
_JVM_EE_JAVA11/graalvm-espresso-jvm-ee-java11-21.2.0-dev/lib/libnio.so [1]
Inconsistency detected by ld.so: dl-version.c: 205: _dl_check_map_versions: Assert
ion `needed != NULL' failed!


We use dlmopen a lot, but never seen this error before, hopefully you can pinpoint the issue. The program in question runs fine without the patches.
I'm running with ./testrun.sh .
I can provide a reproducer, but the setup is quite cumbersome. I can also test any further patches locally if needed.
We've been following this feature for a long time (with great excitement) and just wanted to make sure it works (or that at least doesn't break us) before it's merged.

Best,
Alfonso

________________________________
From: Libc-alpha <libc-alpha-bounces+alfonso.peterssen=oracle.com@sourceware.org> on behalf of Vivek Das Mohapatra via Libc-alpha <libc-alpha@sourceware.org>
Sent: Thursday, June 10, 2021 12:50 AM
To: Florian Weimer <fweimer@redhat.com>
Cc: Vivek Das Mohapatra via Libc-alpha <libc-alpha@sourceware.org>
Subject: [External] : Re: [RFC][PATCH v11 0/7] Implementation of RTLD_SHARED for dlmopen

On Wed, 9 Jun 2021, Florian Weimer wrote:

>>  - libpthread still has the new section applied as I'm not 100% sure it doesn't
>>    still need this treatment. I would like to investigate further before
>
> libpthread does not need this anymore.  We can safely load it as many
> times as we want.

Ok, thanks. I'll update the patch series.


More information about the Libc-alpha mailing list