<font face="arial">The solution was found in in running "/usr/sbin/alternatives" and selecting a new path, along with creating "/etc/profile.d/java.sh". In other words it was completely different all together from CentOS.<br><br><br><br>At Wednesday, 15-09-2010 on 20:57 Josh Welch wrote:<br><blockquote style="border-width: 0pt 0pt 0pt 2px; border-style: none none none solid; border-color: -moz-use-text-color -moz-use-text-color -moz-use-text-color rgb(34, 67, 127); padding: 0px 0px 0px 5px; margin: 0px 0px 0px 5px;">Take a look at that Java that you're getting pathed to, I seem to<br>
recall that Red Hat does a bunch of symlink goofiness with Java that<br>
you need to navigate through. Looks like this might have the info you<br>
were looking for:<br>
<br>
http://www.linuxquestions.org/questions/linux-software-2/jdk1-5-install-rhel4-452546/<br>
<br>
On Tue, Sep 14, 2010 at 3:46 PM, Sean Waite <swaite@sbn-services.com> wrote:<br>
> Here is the full "/etc/profile":<br>
> _______________________________________________________________________________________________<br>
><br>
> # /etc/profile<br>
> # System wide environment and startup programs, for login setup<br>
> # Functions and aliases go in /etc/bashrc<br>
> pathmunge () {<br>
> if ! echo $PATH | /bin/egrep -q "(^|:)$1($|:)" ; then<br>
> if [ "$2" = "after" ] ; then<br>
> PATH=$PATH:$1<br>
> else<br>
> PATH=$1:$PATH<br>
> fi<br>
> fi<br>
> }<br>
> # ksh workaround<br>
> if [ -z "$EUID" -a -x /usr/bin/id ]; then<br>
> EUID=`id -u`<br>
> UID=`id -ru`<br>
> fi<br>
> # Path manipulation<br>
> if [ "$EUID" = "0" ]; then<br>
> pathmunge /sbin<br>
> pathmunge /usr/sbin<br>
> pathmunge /usr/local/sbin<br>
> fi<br>
> # No core files by default<br>
> ulimit -S -c 0 > /dev/null 2>&1<br>
> if [ -x /usr/bin/id ]; then<br>
> USER="`id -un`"<br>
> LOGNAME=$USER<br>
> MAIL="/var/spool/mail/$USER"<br>
> fi<br>
> HOSTNAME=`/bin/hostname`<br>
> HISTSIZE=1000<br>
> if [ -z "$INPUTRC" -a ! -f "$HOME/.inputrc" ]; then<br>
> INPUTRC=/etc/inputrc<br>
> fi<br>
> export PATH USER LOGNAME MAIL HOSTNAME HISTSIZE INPUTRC<br>
> for i in /etc/profile.d/*.sh ; do<br>
> if [ -r "$i" ]; then<br>
> if [ "$PS1" ]; then<br>
> . $i<br>
> else<br>
> . $i >/dev/null 2>&1<br>
> fi<br>
> fi<br>
> done<br>
> unset i<br>
> unset pathmunge<br>
> # JAVA<br>
> JAVA_HOME="/usr/java/jre1.6.0_21/bin"<br>
> export JAVA_HOME<br>
> export JAVA_PATH="$JAVA_HOME"<br>
> export PATH="$PATH:$JAVA_HOME"<br>
> _____________________________________________________________________________________________<br>
><br>
> Where else would it be reading the 1.4.2 version? I thought by putting this<br>
> in profile that it would make this the default java to use.<br>
><br>
> At Tuesday, 14-09-2010 on 15:14 Justin Krejci wrote:<br>
><br>
> If I understand you correctly then if you look at your $PATH variable it is<br>
> finding java sooner in the path than your newly appended version in<br>
> $JAVA_HOME. So you can either remove the old version (or even just rename<br>
> the binary file or remove the execute bit) or else modify your path to place<br>
> the new $JAVA_HOME location before the other one (prepend to $PATH instead<br>
> of append) or you could even remove the directory of the old one from $PATH<br>
> but this last one may have other unintended consequences.<br>
><br>
><br>
><br>
><br>
><br>
> From: tclug-list-bounces@mn-linux.org<br>
> [mailto:tclug-list-bounces@mn-linux.org] On Behalf Of Sean Waite<br>
> Sent: Tuesday, September 14, 2010 2:47 PM<br>
> To: TCLUG Mailing List<br>
> Subject: [tclug-list] Sun java on Redhat 5.5<br>
><br>
><br>
><br>
> When I installed Sun's java 1.6 in CentOS, I merely made /usr/java folder,<br>
> downloaded the file and extracted. Then added:<br>
><br>
> # JAVA<br>
><br>
> JAVA_HOME="/usr/java/jre1.6.0_21/bin"<br>
><br>
> export JAVA_HOME<br>
><br>
> export JAVA_PATH="$JAVA_HOME"<br>
><br>
> export PATH="$PATH:$JAVA_HOME"<br>
><br>
> to /etc/profile, and then "java -version" correctly displayed my version,<br>
> and the app that requires java 1.6 ran just fine.<br>
><br>
> However I am unfamiliar with Red Hat enterprise. I repeated the same steps<br>
> as I did for CentOS (which had no java version installed anyways). Also,<br>
> doing "whereis java" shows /usr/share/java" as the path. This version being<br>
> 1.4.2 we are told is not compatible, so that is why I need to get 1.6 (Sun's<br>
> version) installed.<br>
><br>
> What exactly am I missing here? I always thought that if I put the path to<br>
> "/etc/profile" that this would be sufficient. Redhat does have a config file<br>
> in "/etc/java/java.conf" that I can edit, but do not know if I should touch<br>
> this or not.<br>
><br>
> Please help a very dim nub out here.<br>
><br>
><br>
> Sean<br>
><br>
><br>
><br>
><br>
><br>
><br>
><br>
><br>
> _______________________________________________<br>
> TCLUG Mailing List - Minneapolis/St. Paul, Minnesota<br>
> tclug-list@mn-linux.org<br>
> http://mailman.mn-linux.org/mailman/listinfo/tclug-list<br>
><br>
><br>
<br>
_______________________________________________<br>
TCLUG Mailing List - Minneapolis/St. Paul, Minnesota<br>
tclug-list@mn-linux.org<br>
http://mailman.mn-linux.org/mailman/listinfo/tclug-list</blockquote></font>