LD_ASSUME_KERNEL to set thread library that will be used by JVM

My first aquintance with this environment variables when I was installing Oracle 9i. The notes that written by Werner Puschitz is my oracle installation guidance, back on my early days. Now, I’ve to deal with the same environment variable again.

As a reminder to myself, the LD_ASSUME_KERNEL should be set as:
# Set the LD_ASSUME_KERNEL environment variable only for Red Hat 9,
# RHEL AS 3, and RHEL AS 4 !!
# Use the "Linuxthreads with floating stacks" implementation instead of NPTL:
export LD_ASSUME_KERNEL=2.4.1 # for RH 9 and RHEL AS 3
export LD_ASSUME_KERNEL=export LD_ASSUME_KERNEL=2.4.19 # for RHEL AS 4

Honestly, I don’t know why we have to set differently between RH9 & RHEL AS 3 vs RHEL AS 4. I’ll do it anyway.

As I read from the Red Hat Release Notes, it says:
export LD_ASSUME_KERNEL=2.4.19 — Linuxthreads with floating stacks
export LD_ASSUME_KERNEL=2.2.5 — Linuxthreads without floating stacks

Once we set the environment, we can check which thread library that active, we can use ‘getconf GNU_LIBPTHREAD_VERSION’ command as follow:
bash-3.00$ unset LD_ASSUME_KERNEL
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION
NPTL 2.3.4
bash-3.00$ export LD_ASSUME_KERNEL=2.4.1
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION
linuxthreads-0.10
bash-3.00$ export LD_ASSUME_KERNEL=2.4.19
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION
linuxthreads-0.10
bash-3.00$ export LD_ASSUME_KERNEL=2.5.2
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION
NPTL 2.3.4
bash-3.00$ unset LD_ASSUME_KERNEL
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION
NPTL 2.3.4

Information about NPTL can be found in wikipedia.

You can leave a response, or trackback from your own site.
Subscribe to RSS Feed Follow me on Twitter!