
| This forum is proudly powered by Scientific Linux 6 | SL website Download SL Help Search Members |
| Welcome Guest ( Log In | Register ) | Resend Validation Email |
![]() ![]() ![]() |
| Ocifer |
Posted: Feb 11 2012, 04:52 AM
|
|||
|
SLF Junior ![]() ![]() Group: Members Posts: 47 Member No.: 333 Joined: 23-June 11 |
Hi all,
I was just wondering if someone could guide me through the proper way to install java for SL 6? I've installed it once, adapting commands for a 64-bit version (I'm running 32 bit), but it's not working. I was able to get the .bin from the java site, and create the rpm. The rpm installed, and now if I try again it tells me it's installed. The output of alternatives --display java
Any help? I never got any error messages, so I think it's a matter of linking properly. If someone could tell me what needs to be linked, and explain the locations? I've restarted Firefox and it still doesn't even recognize java as a plugin when I go to the plugins menu. Any thoughts are welcome. EDIT: Poor phrasing. What I meant by the "adapting for a 64 bit version" is that the instructions I found were for a 64-bit version of java, so I had to adapt some of the lines for my 32 bit system. I'm not sure if in doing so I made a mistake. Can anyone reccomend either a way to diagnose what's going on, or a way to cleanly uninstall and try again? |
|||
| U308 |
Posted: Feb 11 2012, 03:55 PM
|
|
|
SLF Advocate ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 485 Member No.: 32 Joined: 11-April 11 |
I always install from Oracle http://www.oracle.com/technetwork/java/javase/downloads/jre-7u2-download-1377135.html The disadvantage being that you have to check for updates yourself.
I am still on jre-7u1 because 7u2, the latest, isn't a security update, so there was no need to update. Anyway if you want to use Oracle's java jre runtime, this is how to do it. First part taken from Oracle's site. Installation of the 64-bit JRE on RPM-based Linux Platforms This procedure installs the Java Runtime Environment (JRE) for 64-bit RPM-based Linux platforms, such as Red Hat and SuSE, using an RPM binary file (.rpm) in the system location. You must be root to perform this installation. These instructions use the following file: jre-7u<version>-linux-x64.rpm 1. Download the file. Before the file can be downloaded, you must accept the license agreement. 2. Become root by running su and entering the super-user password. 3. Uninstall any earlier installations of the JRE packages. # rpm -e <package_name> 4. Install the package. # rpm -ivh jre-7u<version>-linux-x64.rpm To upgrade a package: # rpm -Uvh jre-7u<version>-linux-x64.rpm 5. Delete the .rpm file if you want to save disk space. cd / alternatives --install /usr/bin/java java /usr/java/jre1.7.0_01/bin/java 2 TO REMOVE A VERSION su -c 'alternatives --remove java /opt/jre1.6.0_26/bin/java' (I had previously installed to /opt) OR su -c 'alternatives --remove java /usr/java/jre1.7.0_01/bin/java' 6. Exit the root shell. No need to reboot. 64 bits systems Remove any older JRE package if installed. Remove /usr/lib/mozilla/plugins/libnpjp2.so (if present). Install the new rpm package. Create a soft link to the plugins directory: ln -s /usr/java/jre1.7.0_01/lib/amd64/libnpjp2.so /usr/lib64/mozilla/plugins/libnpjp2.so |
|
![]() |
![]() ![]() ![]() |