The moose likes Linux / UNIX and the fly likes Install Java on Linux question Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of Practical Unit Testing with TestNG and Mockito this week in the Testing forum!
JavaRanch » Java Forums » Engineering » Linux / UNIX
Reply Bookmark "Install Java on Linux question" Watch "Install Java on Linux question" New topic
Author

Install Java on Linux question

Bruce Jin
Ranch Hand

Joined: Sep 20, 2001
Posts: 664
I copied the install instruction below. The question is: in which directory should I issue the installation script? According to step 3 it is the directory in which the script is located. According to step 2 it should be /usr/java which may not contain the script.
Thanks
Bruce
Installation of Self-Extracting Binary

1. Check the download file size
2. Change to the directory you want to install into. For example, if you want to install the software in the /usr/java/ directory, then execute: cd /usr/java
3. Run j2re-1_3_1_<version number>-linux-i386.bin and agree to the license it displays.
Launch the installation script by using the following commands from the directory in which the script is located:
chmod a+x j2re-1_3_1_<version number>-linux-i386.bin
./j2re-1_3_1_<version number>-linux-i386.bin
The script will display a binary license agreement, which you will be asked to agree to before installation can proceed. Once you have agreed to the license, the install script will install the JRE in a directory called jre1.3.1_<version number> in the current directory.


BJ - SCJP and SCWCD
We love Java programming. It is contagious, very cool, and lot of fun. - Peter Coad, Java Design

Crazy Bikes created by m-Power
Jason Kretzer
Ranch Hand

Joined: May 31, 2001
Posts: 280
Just move the bin file to wherever you want to install it. Then run the script. I just keep all of that stuff together.

HTH,
[ January 22, 2002: Message edited by: Jason Kretzer ]

Jason R. Kretzer<br />Software Engineer<br />System Administrator<br /><a href="http://alia.iwarp.com" target="_blank" rel="nofollow">http://alia.iwarp.com</a>
Bruce Jin
Ranch Hand

Joined: Sep 20, 2001
Posts: 664
I just downloaded j2sdk-1_3_1_02-linux-i386.bin to the /usr folder. I login as root and issue the following:
<Usr> # chmod a+x j2sdk-1_3_1_02-linux-i386.bin
But nothing happens. It just returned back to <usr> #.
Then I issue
<usr> # ./j2sdk-1_3_1_02-linux-i386.bin
Still nothing happens. Then I do:
<usr> # chmod a+x j2sdk-1_3_1_02-linux-i386.bin ./j2sdk-1_3_1_02-linux-i386.bin
still nothing happens.
Can anyone help?
Thanks.
Bruce Jin
Ranch Hand

Joined: Sep 20, 2001
Posts: 664
Sorry I got it work.
Frank Hale
Ranch Hand

Joined: Mar 25, 2000
Posts: 230
yeah the bin file when ran like ./jdk.bin will produce an RPM file. This RPM file can be installed like so:
rpm -ivh jdk.rpm
Then you simply edit your home directory .bash_profile and add the path to the jdk binaries and you should be set. Its pretty easy on Linux to get the JDK up and running.
Frank
 
IntelliJ Java IDE
 
subject: Install Java on Linux question
 
Threads others viewed
in java with linx(newbie)
Installing JDK
Installing J2ME tools and SDK on Linux Platform
java installation problem in linux
JDK, path problem in Linux
MyEclipse, The Clear Choice