<> wrote:
> set JAVA_HOME=/usr/java
Is Java really in /usr/java? You should check that it is really there.
> set CLASSPATH .;/usr/java/jdk1.6.0_02
> export JAVA_HOME CLASSPATH
>
> Did this as root thinking I'd be smart and set the CLASSPATH system
> wide even though I'm the only user. At the bottom of that 2003 thread
I'm not sure I understand what you mean when you say you did it as
root. If you opened up a shell window, and did the above, it will
only affect that shell. If you were root, set it, and logged out,
you will lose those settings once logging out.
As yourself, echo the JAVA_HOME variable:
echo $JAVA_HOME
to make sure it has been set.
> another guy said that CLASSPATH hasn't been used for years and that I
> should just set the PATH in /etc/profile. That's when I stopped and
> posted this message. There's a lot of great info/help on how to fix
> this problem, but it seems to be taking me further and further into
> the forest where I am now lost. Can anyone assist?
The first step is to echo $JAVA_HOME. It sounds like your $PATH variable
is set since you can call javac with no issues.
Yea, it has been a long time since I have had to set CLASSPATH to get
Java to work. I only set it so Java can find external packages.
I also haven't manually set up Java on Linux in years - the installation
package does it all for me now days. The global environmental variables set
for everyone are in /etc/profile.d for my distro:
export JAVA_HOME=/usr/lib/java
export MANPATH="$MANPATH:/usr/lib/java/man"
export PATH="$PATH:/usr/lib/java/bin:/usr/lib/java/jre/bin"
- Kurt