In addition, the path should be a directory, not a file. So it should be: PATH=/opt/j2sdk1.4.2_04/jre/bin:$PATH ; export PATH If you are using bash, you can do it all in one statement: export PATH=/opt/j2sdk1.4.2_04/jre/bin:$PATH Thanks tzd. How do I set that in permanently for each reboot?