JAVA_HOME is a system environment variable which represent JDK installation directory. When you install JDK in your machine (windows, Linux or unix) it creates a home directory and puts all its binary (bin), library(lib) and other
Read more »
tools. In order to compile java program "javac" tool should be in your PATH and in order to get that in PATH
we use JAVA_HOME environment variable. Many tools like ANT and web servers like tomcat use JAVA_HOME to find java binaries. In this article we will see how to set JAVA_HOME environment variable in different operating system including Windows (windows 7, vista, xp) and Linux (Unix).