Vous êtes sur la page 1sur 3

First you need to check that Ubuntu Partners repository is enabled in your apt s ources list, open /etc/apt/sources.

list and uncomment the following line or add it: deb http://archive.canonical.com/ubuntu maverick partner Then in command line type sudo apt-get update sudo apt-get install sun-java6-jdk As well you need to set Sun Java as default Java provider in your system by typi ng the following in command line sudo update-alternatives --config java You will be presented with the screen similar to this one: ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ +++ There are 2 choices for the alternative java (providing /usr/bin/java). Selection Path Priority -----------------------------------------------------------* 0 /usr/lib/jvm/java-6-openjdk/jre/bin/java 1061 1 /usr/lib/jvm/java-6-openjdk/jre/bin/java 1061 2 /usr/lib/jvm/java-6-sun/jre/bin/java 63 Status auto mode manual mode manual mode

Press enter to keep the current choice[*], or type selection number: 2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ ++++ Select the option that has the path /usr/lib/jvm/java-6-sun/jre/bin/java and you are done. to check if you are using the Sun Java provider type the following: java -version You should see a screen similar to the below: ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ java version "1.6.0_22" Java(TM) SE Runtime Environment (build 1.6.0_22-b04) Java HotSpot(TM) Client VM (build 17.1-b03, mixed mode, sharing) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Downloaded the JDK : Ubuntu: 1. Download the JRE (Java Runtime Environment) / JDK (Java Development Kit) 7 fr om here: The file type for Ubuntu is the .tar.gz Note: The JDK is for developers. Do not download unless you plan on programming

in Java. 2. Unpack (or untar, or extract) the .tar.gz file in the desired directory. Type : tar -zxvf filename 3. Install Java 1.7 to alternatives. Type: sudo update-alternatives --install /usr/bin/java java /your/java/directory/jre/b in/java 3 Note: Replace /your/java/directory/, with the directory where you extracted the .tar.gz 4. Choose your Java version using alternatives. Type: sudo update-alternatives config java

Then choose the option that points to your Java 7 directory. Note: If you have chosen the JDK, your javac will not be updated. Typing the jav ac -version command will return the previous Java s version javac. I do not know h ow to fix this. 5. Configure the Java browser plugin. You will have to use a symbolic link to configure the plugin. Type: ln -s /your/java/directory/jre/lib/your system architecture/libnpjp.so /your/bro wer/plugins/directory Note: /your/java/directory/ is wherever you extracted the .tar.gz Also, /your system architecture/ is the architecture type of the Java .tar.gz fi le you downloaded. This will either be i386, or amd64. If you are unsure which, open a file manager, go to your Java directory, and go to the jre/lib/ directory . If a folder entitled amd64 is there, you have the x64-bit version. If not, you have the x32-bit. Another thing to note, the /your/browser/plugins/directory/ is your browser s plug ins directory. Example: if you are using Mozilla s Firefox, your plugins directory is /usr/lib/mozilla/plugins/ 6. Test the plugin. Restart your browser, and go to Java Tester ( http://javatester.org/ ) Click the Java Version button. If the pink box says Java 1.7.0 from Oracle, you have configured the plugin correctly.

Installing Java 1.7 goodness for Ubuntu. Enjoy ++++++++++++++++++++++++++++ I got the following error when trying to extract the binary:

Quote:

sudo ./jre-6u30-linux-i586.bin Unpacking... Checksumming... Extracting... ./jre-6u30-linux-i586.bin: 86: ./install.sfx.8648: not found Failed to extract the files. Please refer to the Troubleshooting section of the Installation Instructions on the download page for more information. then i tried the proposed solution:

Quote:

chris@chris-VirtualBox:~/Downloads$ sudo apt-get install g++-multilib and after it has finished i tried again to start the binary extraction and this time it worked!: ++++++++++++++++++++++++++++++++

Vous aimerez peut-être aussi