Posts Tagged ‘classpath’

setting java environment under ubuntu

May 20th, 2010

you can set all the environment vars in /etc/environment.

for example:

PATH=”/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games”
JAVA_HOME=”/usr/lib/jvm/java-6-sun/jre”
CLASSPATH=”.:$JAVA_HOME/lib:/home/xxxxxx/other-packages/lucene-3.0.1″

UPDATE:

use bash> source /etc/environment to refresh the system variables.