LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-16-2005, 09:12 AM   #1
0007
LQ Newbie
 
Registered: Jan 2005
Posts: 13

Rep: Reputation: 0
problems with java and redhat


hi

i have red hat 9 on the system. i downloaded java sdk for linux path from sun and installed it. i did exactly what this website's tutorial said, but still it says javac command not found even though i renamed the path using the locate javac command.

also my interent doesnt work properly i cant enter my mail in hotmail or yahoo.
 
Old 01-16-2005, 10:19 PM   #2
javabb
LQ Newbie
 
Registered: Oct 2004
Posts: 11

Rep: Reputation: 0
This is because you have not set the path properly. U have to set the PATH and CLASSPATH variables in .bash_profile
 
Old 01-18-2005, 04:05 AM   #3
0007
LQ Newbie
 
Registered: Jan 2005
Posts: 13

Original Poster
Rep: Reputation: 0
how can i do that???????????
 
Old 01-18-2005, 04:10 AM   #4
EdwinNameless
LQ Newbie
 
Registered: Jul 2003
Location: Paris
Distribution: Mandrake 10.1
Posts: 8

Rep: Reputation: 0
You open .bash_profile and add lines such as :

JAVA_HOME=/my/path/to/java
PATH=$PATH:$JAVA_HOME/bin

export JAVA_HOME
export PATH
 
Old 01-18-2005, 07:37 AM   #5
0007
LQ Newbie
 
Registered: Jan 2005
Posts: 13

Original Poster
Rep: Reputation: 0
i did this in .bash_profile

PATH = $PATH:/usr/java/j2ske1.4.2-06/bin/javac
export PATH

i found the path by typing locate javac in terminal.

but still i get this error:

bash: javac : command not found
 
Old 01-18-2005, 02:09 PM   #6
lnthai2002
Member
 
Registered: Jan 2005
Location: Montreal, QC, CANADA
Distribution: Red Hat Fedora
Posts: 135

Rep: Reputation: 15
Quote:
Originally posted by 0007
i did this in .bash_profile

PATH = $PATH:/usr/java/j2ske1.4.2-06/bin/javac
export PATH

i found the path by typing locate javac in terminal.

but still i get this error:

bash: javac : command not found
The correct pat must be: /usr/java/j2sdke1.4.2-06/bin
javac is a file, not folder
 
Old 01-18-2005, 03:22 PM   #7
0007
LQ Newbie
 
Registered: Jan 2005
Posts: 13

Original Poster
Rep: Reputation: 0
i tried this path as well but faced the same dillema.
 
Old 01-19-2005, 03:29 AM   #8
javabb
LQ Newbie
 
Registered: Oct 2004
Posts: 11

Rep: Reputation: 0
You have reboot for the effect to take place... are u logged in as root? otherwise hte bashprofile for that particular user also has to be changed
 
Old 01-19-2005, 01:19 PM   #9
0007
LQ Newbie
 
Registered: Jan 2005
Posts: 13

Original Poster
Rep: Reputation: 0
thanks mate now its working just fine!!!!
 
Old 02-15-2005, 02:26 PM   #10
petehinch
LQ Newbie
 
Registered: Aug 2004
Posts: 3

Rep: Reputation: 0
can't download java sdk for linux

Hi can anyone help I need the java sdk but the link on the java site seams to be broken, I would be very greatful if someone could help
thanks pete
 
Old 02-15-2005, 02:39 PM   #11
mickyg
Member
 
Registered: Oct 2004
Location: UK
Distribution: Ubuntu/Kubuntu
Posts: 249

Rep: Reputation: 30
Another way to solve the problem would have been to create symlinks to the java, javac, javah etc file in /usr/local/bin, that way any user who logs into the machine will be able to use the programs without needing to add it to their .bash_profile file and rebooting.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Problems with Java Web Start (java 1.4.2 - 1.5.0) on Slackware Egy Slackware 11 05-10-2005 06:30 AM
JAVA:(jwstric2) Problems in JAVA-LINUX nedian123 Programming 1 06-28-2004 04:12 PM
Java in Redhat. Peleus Programming 4 04-05-2004 01:26 PM
x-java-vm for Redhat V9 mfeat Red Hat 5 10-30-2003 09:28 PM
java in redhat 8 key_maker Linux - Software 1 10-02-2003 06:23 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:43 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration