wood burning stoves 2.0*
The moose likes Beginning Java and the fly likes Path setting in Linux Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Path setting in Linux" Watch "Path setting in Linux" New topic
Author

Path setting in Linux

Gautam Sathe
Greenhorn

Joined: Jun 13, 2007
Posts: 6
Hello! I have started to learn java programming on Linux Platform. The version of Java is Java 1.6.0_02 and Linux - Fedora Core 6. At present I have to put the command:
%export PATH=/usr/java/jdk1.6.0_02/bin:$PATH
every time I login.

Can anyone please suggest me a permanent way of setting PATH in Linux (Fedora Core 6).

Thanks
Freddy Wong
Ranch Hand

Joined: Sep 11, 2006
Posts: 959

Add it in .bashrc.


SCJP 5.0, SCWCD 1.4, SCBCD 1.3, SCDJWS 1.4
My Blog
Gautam Sathe
Greenhorn

Joined: Jun 13, 2007
Posts: 6
Thanks for your prompt reply, Freddy.

I followed the suggestions from you link and it was successfully.

What I did was I edited .bash_profile in the home directory modifying the PATH statement.
PATH=/usr/java/jdk1.6.0_02/bin:$PATH:HOME/bin

The important thing to remember while doing the above changes is to put '/usr/java/jdk1.6.0_02/bin' before $PATH:HOME/bin. As if you put it at the end it takes the version of Java provide by Fedora Core 6 (something called gij).

Thanks.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Path setting in Linux
 
Similar Threads
how to uninstall java 1.5?
How to install SUN JDK1.6 on Fedora
Applet in LINUX fedora core 3
Install Issues - Fedora Core 1
installing java on fedora