United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
JDK-4654443 : REGRESSION: Java 1.4 does not work with Redhat's new glibc-2.2.5

Details
Type:
Bug
Submit Date:
2002-03-18
Status:
Closed
Updated Date:
2012-10-08
Project Name:
JDK
Resolved Date:
2002-10-21
Component:
hotspot
OS:
linux
Sub-Component:
runtime
CPU:
x86
Priority:
P3
Resolution:
Fixed
Affected Versions:
1.0.1,1.4.0
Fixed Versions:
1.4.0_01 (01)

Related Reports

Sub Tasks

Description

Name: rmT116609			Date: 03/18/2002


FULL PRODUCT VERSION :
java version "1.4.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-b92)
Java HotSpot(TM) Client VM (build 1.4.0-b92, mixed mode)

(obtained by using an older glibc: 2.2.4)

FULL OPERATING SYSTEM VERSION :

Linux aknaffpc 2.4.18-0.4 #1 Wed Mar 13 10:36:06 EST 2002 i686 unknown
glibc-2.2.5-27 Raw Hide 20020317

DESCRIPTION OF THE PROBLEM :

Starting java with glibc-2.2.5 (new in RedHat's Rawhide) fails with the following error

Error occured during initialization of VM
Unable to load native library:
/usr/java/j2sdk1.4.0/jre/lib/i386/libjava.so: symbol__libc_waitpid,
version GLIBC_2.0 not defined in file libc.so.6 with link
time reference

REGRESSION.  Last worked in version 1.3.1_02

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1. Install glibc-2.2.5
2. /usr/java/j2sdk1.4.0/bin/java -version

EXPECTED VERSUS ACTUAL BEHAVIOR :
Expected result:

java version "1.4.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-b92)
Java HotSpot(TM) Client VM (build 1.4.0-b92, mixed mode)

(obtained by using an older glibc: 2.2.4)


Actual result:
Error occured during initialization of VM
Unable to load native library:
/usr/java/j2sdk1.4.0/jre/lib/i386/libjava.so: symbol
__libc_waitpid,
version GLIBC_2.0 not defined in file libc.so.6 with link
time reference


ERROR MESSAGES/STACK TRACES THAT OCCUR :
Error occured during initialization of VM
Unable to load native library:
/usr/java/j2sdk1.4.0/jre/lib/i386/libjava.so: symbol __libc_waitpid,
version GLIBC_2.0 not defined in file libc.so.6 with link time reference

(Review ID: 144311) 
======================================================================

Name: rmT116609			Date: 03/19/2002


FULL PRODUCT VERSION :
# java -version
Error occurred during initialization of VM
Unable to load native library: /usr/java/j2sdk1.4.0/jre/lib/i386/libjava.so:
symbol __libc_waitpid, version GLIBC_2.0 not defined in file libc.so.6 with link time reference

DESCRIPTION OF THE PROBLEM :

error loading java after upgrade to glibc-2.2.90-8

How Reproducible:
everytime i start java ... this error will be produced:
# javac
Error occurred during initialization of VM
Unable to load native library:
/usr/java/j2sdk1.4.0/jre/lib/i386/libjava.so:
symbol __libc_waitpid, version GLIBC_2.0 not defined in file libc.so.6 with link
time reference

Additional Information:

Everything was ok on glibc-2.2.90-3


STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1.just run anything under bin/

(Review ID: 144258)
======================================================================

Name: rmT116609			Date: 03/19/2002


FULL PRODUCT VERSION :
$ /usr/java/j2sdk1.4.0/bin/java  -version
Error occurred during initialization of VM
Unable to load native library: /usr/java/j2sdk1.4.0/jre/lib/i386/libjava.so:
symbol __libc_waitpid, version GLIBC_2.0 not defined in file libc.so.6 with link
time reference

FULL OPERATING SYSTEM VERSION :

Redhat Linux 7.2 with recent glibc

A DESCRIPTION OF THE PROBLEM :
jdk using private interface which is disallowed by newer glibc's.  Reference redhat bug here:
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=61215

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1. install recent glibc
2. try to run java
3.

EXPECTED VERSUS ACTUAL BEHAVIOR :
expected: java works
actual: java doesn't work


(Review ID: 144317)
======================================================================

Name: rmT116609			Date: 04/01/2002


JRE 1.4.0 libc symbol problem on RedHat Skipjack beta (aka 7.3)

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1. Install RedHat Skipjack beta, try to run JRE 1.4 from Sun.

Error occurred during initialization of VM
Unable to load native library:
/home/lanforge/LANforgeGUI_3.0.3-JVM1.4/jre/lib/i386/libjava.so:
symbol
__libc_waitpid, version GLIBC_2.0 not defined in file
libc.so.6 with link time reference

REGRESSION.  Last worked in version 1.3.1
(Review ID: 144830)
======================================================================

                                    

Comments
EVALUATION

__libc_waitpid was used to workaround an earlier glibc problem. In 1.4.1, we
no longer use __libc_waitpid().

###@###.### 2002-03-19
                                     
2002-03-19
WORK AROUND

Here is a workaround before 1.4.0_01 is released:

+ create a file called "hswaitpid.c":

  #include <sys/types.h>
  #include <sys/wait.h>

  pid_t hslibc_waitpid(pid_t pid, int *status, int options) {
    return waitpid(pid, status, options);
  }

+ build a shared library libhswaitpid.so with this command:

  gcc -shared -O3 -o libhswaitpid.so hswaitpid.c

+ edit libjava.so and retarget "__libc_waitpid" calls to "hslibc_waitpid",
  for example, you can use the following commands:

  cd <jdk_directory>/jre/lib/i386
  perl -e "while(<>) {" -e "s/__libc_waitpid/hslibc_waitpid/;" -e "print;" -e"}" libjava.so > libjava.so.tmp
  mv libjava.so libjava.so.orig
  mv libjava.so.tmp libjava.so

+ preload libhswaitpid.so before you start java, for example, on tcsh you can do:

  setenv LD_PRELOAD  /<directory>/libhswaitpid.so

It's ugly, but seems working just fine.

###@###.### 2002-04-01
                                     
2002-04-01
CONVERTED DATA

BugTraq+ Release Management Values

COMMIT TO FIX:
1.4.0_01

FIXED IN:
1.4.0_01

INTEGRATED IN:
1.4.0_01


                                     
2004-06-14



Hardware and Software, Engineered to Work Together