there must be an /etc/environment file which runs at the beginning just before /etc/profile.
Alternatively, in case the environment file is not present there could be /etc/profile.d directory which contains various shell scripts for bash and other shells.
Just change the line present in java_**.sh like java_sdk.sh or java_jre.csh and properly replace the older version with this new one. Afterwards just log in to any user and try echo $JAVA_HOME
one more thing $JAVA_HOME is a standart variable in Linux, JAVA_BINDIR must be customery variable. I am sure you will find the solution to your problem in /etc/profile.d directory