Set Java Environment Variable on Windows 7 and Windows vista
Right click on My Computer, go to properties and then click on Advanced System Settings.Now click on Environment Variables , Add JAVA_HOME path in system variables and then change Path system variable to add one more path. Details are described in below picture.
Set Java Environment Variable on Windows XP
Right click on My Computer, go to properties and then click on Advanced.Now click on Environment Variables , Add JAVA_HOME path in system variables and then change Path system variable to add one more path. Details are described in below picture.
Set Java Environment Variable on Ubuntu/Unix
Edit .bashrc file in the home directory and add following lines at the end. Note JAVA_HOME should point to your jdk installation directory. export JAVA_HOME=/usr/lib/jvm/java-6-sun
export PATH=$PATH:$JAVA_HOME/bin
export PATH=$PATH:$JAVA_HOME/bin
To check whether path has been set correctly or not type echo $JAVA_HOME at the command prompt, you should get result /usr/lib/jvm/java-6-sun.
No comments:
Post a Comment