My system need to use java 1.7. However, I need to run some old apps which require java1.6. Can I use shell script to let the old apps use correct java version? Could the $JAVA_HOME work?
I try to set export JAVA_HOME=/usr/lib/jvm/java-6-openjdk-amd64
However, it does not has any effect.
$JAVA_HOMEcould work. What have you tried?JAVA_HOMEitself seems does not work. Do I need to set PATH?