![]() |
[SOLVED] JDK Install fails with install.sfx.#### No such file during installation.
I'm trying to install jdk-1_5_0_09-linux-amd64.bin on a pure 64-bit Linux system built using CLFS version 1.0.0.
Code:
cp jdk-1_5_0_09-linux-amd64.bin jdk-mod.bin && ./jdk-mod.binQuote:
I first encountered the error after having installed Xorg and several other packages. I did a complete rebuild of the base CLFS on a new partition and attempted to install JDK before anything else. Same results. I'm assuming that I've done something wrong in the base build twice now, but I can't see what. During the second build, I ran every test suite and resolved any errors before installing the package. Any help would be appreciated. Thanks in advance. Andrew |
Try running ldd command on one of the java binaries to see what is missing.
I guess your dynamic linker (/lib64/ld-linux-x86-64.so.2) has somehow ended up in wrong directory. That path is hard-coded in every dynamically linked executable, so getting it wrong breaks all binaries that use the standard one. |
Thanks Harmaa Kettu, I didn't even consider a problem with dyanamic linker since nothing else on the system was problematic. By the time you have GNOME installed there are many things that use the dynamic linker. However, everything else on the system was built from source whereas the JDK binaries are, obviously, built by a Sun engineer for our convenience.
The path for the dynamic linker is hard coded, but this does not mean that the path is /lib64. That's why everything built from source worked with ld-linux-x86-64.so.2 in /lib. Which is where it really should be (IAW the FHS) on a pure 64-bit system because there is no need to differentiate between 64-bit and 32-bit files. Most likely, the engineers at Sun build the 64-bit Java on a multilib system or assume everyone using it will be using a multilib system. This causes the path to be hard-coded to /lib64/ld-linux-x86-64.so.2. Hence, failure if trying to install on a pure 64-bit system. Trying to change this path manually or with a sed before unpacking the *.bin corrupts the *.bin and the install fails. The solution I went with was to create a /lib64 directory and a symlink in /lib64 named ld-linux-x86-64.so.2 to /lib/ld-2.4.so before attempting to unpack and install the Java binary. Unfortunately, it appears you must keep this link around or the Java binaries won't run because they were compiled on a, most likely, multilib system. Hence, I assume, my "No such file or directory" problem. Building JDK from source on a pure 64-bit system should hard code the path to /lib. Of course, you need the precompiled Java to unpack the *.jar files containing the JDK source code. AFAIK, Java isn't needed after this. It should be possible to unpack the *.jar files, delete the link in /lib64, and then build JDK from source with ld-linux-x86-64.so.2 in /lib. Maybe I'll give it a try this weekend and report back on the results. |
Another solution
Another solution how to be able to run 32bit executables on 64bit Ubuntu is to install package i32-lib. This worked for me. I am now able to run both JDK installer and 32bit JDK executables like java, javac, ....
I use testing version of Feisty, Ubuntu 7.04 on AMD64 Linux 2.6.19-7-generic #2 SMP Mon Dec 4 12:39:22 UTC 2006 x86_64 GNU/Linux |
No, that's not a solution. I don't want to run 32 bit binaries on my 64 bit system. If that's what I wanted to do, I would have built a multilib system. I wanted to run the 64 bit java binaries on a pure 64 bit system.
|
Similar problem
I had a similar issue, several times. I was running jdk-1_5_0_06-linux-i586.bin using . /path/jdk-1_5_0_06-linux-i586.bin from the desired install dir (/usr/java/) when I moved the jdk-1_5_0_06-linux-i586.bin to the install dir, it installed without error.
|
solution
putting the bin in /usr/java and installing the 32 bit packages worked for me.
sudo apt-get install g++-multilib sudo apt-get install gcc-multilib |
@89robness:
Quote:
The OP has (had?? this being a very old thread...) problems with CLFS and jdk. CLFS does not use apt-get and although sudo can be installed it is not used to install anything (out of the box that is). |
Thought I'd share my solution as I've been banging my head against the wall with the same error, which is a little misleading considering my solution. I'm completely new to Linux, so please go easy :)
I tried the 32-bit and 64-bit flavours of the Java JDK for Linux (I'm running an Intel E2200, which is a dual core 64-bit CPU with Ubuntu). I followed Sun's installation instructions for installing the 64-bit self-extracting version. I tried installing 32-bit and 64-bit libs with "get-apt install ia32-libs" and "get-apt install amd64-libs", respectively but this didn't help. My solution was to use the command "sudo su" in the terminal before executing the self-extracting zip with "./jdk-6u22-linux-x64.bin". I didn't try this before as I recall Sun saying in the installation instructions "This bundle can be installed by anyone (not only root users), in any location that the user can write to." Hopefully this might help other newbies :) |
Hi,
@Gadbury: Although your general information might be useful to others, your answer/solution (like the previous post #7) doesn't have anything to do with (C)LFS. Apt-get and sudo are not part of (C)LFS! Did you read all the replies and especially post #8??? |
My apologies for the misinformation. I did not realise what CLFS was and that the commands in my example are not available to the OP. I had read the posts (I ended up here Googling for a solution) and to be honest a lot of the replies are difficult for me to understand as I'm completely new to Linux.
|
worked for me
Thanks 89robness, installing g++-multilib fixed the problem for me! (32 bit Java 1.5 on 64bit Ubuntu 9.10)
|
The g++ solution is still actual
Thanks for posting this solution to install g++
I have Ubuntu 11.10 32 bit and i tried to install the actual Sun Java Runtime Environment 32bit, which atctual version is 6u30 I got the following error when trying to extract the binary: Quote:
Quote:
Quote:
BTW i m following this tutorial to install and configure Java on my Ubuntu: w w w .youtube.com/watch?v=9cCjVIG26Do |
I encountered the same problem. In my case the error message was "./jdk-6u31-linux-i586.bin: 113: ./install.sfx.5987: not found" on "Ubuntu 10.04.2 LTS".
I had JDK 1.6.0_31 installed & working. It got crashed for no reason in the middle of a Maven build. When I tried re-installing JDK, I faced above error. Installing "g++-multilib" as suggested above solved the problem. In a summary I did, 1. sudo apt-get install g++-multilib 2. ./jdk-6u31-linux-i586.bin |
| All times are GMT -5. The time now is 10:28 PM. |