Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am running Ubuntu 12.04 LTS. I wanted to install Java and so I downloaded the 32-bit self extracting .bin file from and tried to install it according to their instruction.

First I made the file an executable one. Then created /usr/java/. After that I have to run this command: ./jre-7u<version>-linux-i586.bin.

But I'm stuck here. My Java version is Java 6 u32. When I enter the command it says "no such file or directory". What to do? Please help. Also I'm trying to install 32-bit Java on my 64-bit Precise. Could that possibly be the problem?

I tried to follow second answer by Jonas Christensen. I tried to open it, it says file is an unknown type. I tried the terminal command: ./jre-6u31-linux-i586.bin. But it gave this:

./jre-6u32-linux-i586.bin: 86: ./jre-6u32-linux-i586.bin: ./install.sfx.5736: not found  
Failed to extract the files. Please refer to the Troubleshooting section of the Installation Instructions on the download page for more information.
share|improve this question
up vote 10 down vote accepted

Please see the "bug" described at:

Resolve by installing 32 bit libs:

sudo apt-get install ia32-libs

share|improve this answer
On Ubuntu 13.10 , instead of ia32-libs, I installed lib32z1. – kostmo Oct 21 '13 at 4:17

The easiest method to install Oracle Java 7 via PPA:

  1. sudo add-apt-repository ppa:webupd8team/java
  2. sudo apt-get update
  3. sudo apt-get install oracle-java7-installer

See also:

share|improve this answer

If you don't actually need a specific version of java for a special purpose, download the now-latest 7u7 version as a tar file: download 7u7 from | download 6u35 from

Note that 6u35 link is a bin file as yours. But I have just tried to run it and it works. It is a generic shell script so to execute it: sh jre-6u35-linux-x64.bin. It wouldn't break anything that runs on 6u32, so download it with comfort.

Extract the archive and put contents to any directory you want (chosing a directory like /opt/java or /usr/local/java is ok. put it somewhere that you won't accidentally remove) and keep a note of the full path to that directory. Then edit as needed and put the following code into an executable .sh file inside /etc/profile.d:

# You may put this in /etc/profile.d/

if [ -d <full-path-to-java> ]; then
  export PATH=$PATH:<full-path-to-java>;

# dont forget to make executable, run following in your terminal:
# chmod +x /etc/profile.d/

As a little note, don't keep the '<' and '>' characters in :)

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.