2

I am on Oracle Linux 6 and I am trying to add the path:

/root/jrockit-jdk1.6.0_33-R28.2.4-4.1.0

to the PATH and JAVA_HOME variables. So, I login as root and I try:

export PATH=$PATH:/root/jrockit-jdk1.6.0_33-R28.2.4-4.1.0 and JAVA_HOME=/root/jrockit-jdk1.6.0_33-R28.2.4-4.1.0.

PATH does not even add my jdk path, and JAVA_HOME adds it as it should. When I echo JAVA_HOME from another terminal or after a reboot JAVA_HOME returns to default(empty).

I also edited the .bash_profile and .bashrc with vi and I added the above commands but nothing happened.

Any ideas how could I edit these variables properly?

1 Answer 1

1

Just add

export PATH=$PATH:/root/jrockit-jdk1.6.0_33-R28.2.4-4.1.0
export JAVA_HOME=/root/jrockit-jdk1.6.0_33-R28.2.4-4.1.0

to your .bash_profile and reload it with the command

source ~/.bash_profile

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .