LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-13-2006, 06:15 AM   #1
sharp81
Member
 
Registered: Mar 2005
Posts: 79

Rep: Reputation: 15
java path settings


I installed the java ... but i am not sure how to set the path to the java folder to access my version of the java

please help

Regards
Sharp
 
Old 01-13-2006, 06:19 AM   #2
sharp81
Member
 
Registered: Mar 2005
Posts: 79

Original Poster
Rep: Reputation: 15
Also when I try to run an application of mine it says Exception in thread "main" java.lang.RuntimeException: Could not load driver: org.postgresql.Driver org.postgresql.Driver (org/postgresql/Driver org/postgresql/Driver)
I dont know what could be the problem .. everything has been set properly
 
Old 01-13-2006, 09:50 AM   #3
megaspaz
Senior Member
 
Registered: Nov 2002
Location: Silly Con Valley
Distribution: Red Hat 7.3, Red Hat 9.0
Posts: 2,054

Rep: Reputation: 46
http://www.linuxquestions.org/questi...d.php?t=327989

For the question about the postgresql driver, where did you save the driver to and is that path/driver in your CLASSPATH variable?
 
Old 01-13-2006, 11:01 AM   #4
sharp81
Member
 
Registered: Mar 2005
Posts: 79

Original Poster
Rep: Reputation: 15
i saved to the lib folder of my appln and yes it is set in the CLASSPATH

And the problem with JAVA is I have set the JAVA_HOME to my new j2sdk home folder and also put the path for /bin in PATH ... but when I run java -version it is still the older version of the java. ...
Also when I run the commant export at the shell .. it shows the path to the old java version for JAVA_HOME , JAVA_BINDIR , JAVA_ROOT,
 
Old 01-13-2006, 11:24 AM   #5
megaspaz
Senior Member
 
Registered: Nov 2002
Location: Silly Con Valley
Distribution: Red Hat 7.3, Red Hat 9.0
Posts: 2,054

Rep: Reputation: 46
how did you set your environment variables? in a file or on the command line?

If from the command line, then your problem is that the environment variables are set only for the duration of that shell's session. You need to make it permanent by setting it in a file (/etc/profile).

If you did set the variables in a file, then you need to log out and log back in. If logging out and logging back in didn't work, try rebooting the system. If the variables still aren't working for you, post what you have in the file where you set your environment variables. I've seen problems with having sun's java and gnu's java on the same machine where the order in the path matters in which java is used. You only really need one java environment so if it were me, I'd uninstall everything java and install one java version. Which java you use (sun, ibm, gnu, ...) is up to you.
 
Old 01-13-2006, 11:50 AM   #6
sharp81
Member
 
Registered: Mar 2005
Posts: 79

Original Poster
Rep: Reputation: 15
this is my /etc/profile config file ..... btw when I run the export command I can some statements with declare -x .... and there I had
JAVA_HOME= the prev. path of my java

I also tried the uninstall but the problem but it is still there and the path still is the older version of java .. I tried the j2sdk install to install java after removing java from the system .. Is that the problem why jdbc is unable to connect


# Make path more comfortable
#
if test -z "$PROFILEREAD" ; then
PATH=/usr/local/bin:/usr/bin:/usr/X11R6/bin:/bin:/usr/java/j2sdk1.4.2_10/bin
if test "$HOME" != "/" ; then
for dir in $HOME/bin/$CPU $HOME/bin ; do
test -d $dir && PATH=$dir:$PATH
done
fi
if test "$UID" = 0 ; then
test -d /opt/gnome/sbin && PATH=/opt/gnome/sbin:$PATH
test -d /opt/kde3/sbin && PATH=/opt/kde3/sbin:$PATH
PATH=/sbin:/usr/sbin:/usr/local/sbin:$PATH
fi
for dir in /var/lib/dosemu \
/usr/games \
/opt/bin \
/opt/gnome/bin \
/opt/kde3/bin \
/opt/kde2/bin \
/opt/kde/bin \
/usr/openwin/bin \
/opt/cross/bin
do
test -d $dir && PATH=$PATH:$dir
done
unset dir
export PATH
fi

#
# Many programs using readline library for line editing
# should know about this (e.g. bash)
#
if test -z "$INPUTRC" ; then
INPUTRC=/etc/inputrc
test -s $HOME/.inputrc && INPUTRC=$HOME/.inputrc
export INPUTRC
fi

#
# Most bourn shell clones knows about this
#
if test -z "$PROFILEREAD" ; then
HISTSIZE=1000
export HISTSIZE
fi

#
# Set some environment variables for TeX/LaTeX
#
if test -n "$TEXINPUTS" ; then
TEXINPUTS=":$TEXINPUTS:$HOME/.TeX:/usr/share/doc/.TeX:/usr/doc/.TeX"
else
TEXINPUTS=":$HOME/.TeX:/usr/share/doc/.TeX:/usr/doc/.TeX"
fi
export TEXINPUTS

#
# Configure the default pager on SuSE Linux
#
if test -z "$LESS" ; then
LESS="-M -I"
LESSKEY=/etc/lesskey.bin
LESSOPEN="lessopen.sh %s"
LESSCLOSE="lessclose.sh %s %s"
LESS_ADVANCED_PREPROCESSOR="no"
PAGER=less
export LESSOPEN LESSCLOSE LESS LESSKEY PAGER LESS_ADVANCED_PREPROCESSOR
fi

#
# Minicom
#
if test -z "$PROFILEREAD" ; then
MINICOM="-c on"
export MINICOM
fi

#
# Current manpath
#
if test -z "$PROFILEREAD" ; then
tmp="$MANPATH"
unset MANPATH
if test -n "$tmp" ; then
MANPATH="${tmp}:`test -x /usr/bin/manpath && /usr/bin/manpath -q`"
else
MANPATH="`test -x /usr/bin/manpath && /usr/bin/manpath -q`"
fi
unset tmp
export MANPATH
fi

#
# Some applications do not handle the XAPPLRESDIR environment properly,
# when it contains more than one directory. More than one directory only
# makes sense if you have a client with /usr mounted via nfs and you want
# to configure applications machine dependent. Uncomment the lines below
# if you want this.
#
#XAPPLRESDIR="$XAPPLRESDIR:/var/X11R6/app-defaults:/usr/X11R6/lib/X11/app-defaults"
#export XAPPLRESDIR

#
# Set INFOPATH to tell xemacs where he can find the info files
#
if test -z "$PROFILEREAD" ; then
tmp="$INFODIR"
if test -n "$tmp" ; then
INFODIR="${tmp}:/usr/local/info:/usr/share/info:/usr/info"
else
INFODIR="/usr/local/info:/usr/share/info:/usr/info"
fi
INFOPATH=$INFODIR
unset tmp
export INFODIR INFOPATH
fi

#
# These settings are recommended for old motif applications
#
if test -z "$PROFILEREAD" ; then
XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB
export XKEYSYMDB
XNLSPATH=/usr/X11R6/lib/X11/nls
export XNLSPATH
fi

if test -s /etc/nntpserver ; then
read NNTPSERVER < /etc/nntpserver
export NNTPSERVER
fi

if test -s /etc/organization ; then
read ORGANIZATION < /etc/organization
export ORGANIZATION
fi

#
# Midnight Commander needs this to run in color mode
#
if test -z "$PROFILEREAD" ; then
COLORTERM=1
export COLORTERM
fi

#
# For RCS
#
#export VERSION_CONTROL=numbered

#
# Source the files generated by SuSEconfig
#
if test -z "$PROFILEREAD" ; then
test -r /etc/profile.d/sh.ssh && . /etc/profile.d/sh.ssh
test -r /etc/SuSEconfig/profile && . /etc/SuSEconfig/profile
if test -z "$SSH_SENDS_LOCALE" ; then
if test -r /etc/sysconfig/language -a -r /etc/profile.d/sh.utf8 ; then
tmp="$(. /etc/sysconfig/language; echo $AUTO_DETECT_UTF8)"
test "$tmp" = "yes" && . /etc/profile.d/sh.utf8
unset tmp
fi
fi
fi

#
# Source profile extensions for certain packages
#
if test -d /etc/profile.d -a -z "$PROFILEREAD" ; then
for s in /etc/profile.d/*.sh ; do
test -r $s && . $s
done
unset s
fi

if test "$is" != "ash" ; then
#
# And now let's see if there is a local profile
# (for options defined by your sysadmin, not SuSE Linux)
#
test -s /etc/profile.local && . /etc/profile.local
fi

#
# Avoid overwriting user settings if called twice
#
if test -z "$PROFILEREAD" ; then
readonly PROFILEREAD=true
export PROFILEREAD
fi

#
# System BASH specials, maybe also good for other shells
#
test -r /etc/bash.bashrc && . /etc/bash.bashrc
if test "$is" = "bash" -a -z "$_HOMEBASHRC" ; then
# loop detection
readonly _HOMEBASHRC=true
test -r $HOME/.bashrc && . $HOME/.bashrc
fi

#
# KSH specials
#
if test "$is" = "ksh" ; then
test -r /etc/ksh.kshrc && . /etc/ksh.kshrc
fi
if test "$is" = "ksh" -a -z "$_HOMEKSHRC" ; then
# loop detection
readonly _HOMEKSHRC=true
test -r $HOME/.kshrc && . $HOME/.kshrc
fi

export POSTGRESQL_HOME=/usr/local/pgsql
export PATH=$PATH:$POSTGRESQL_HOME/bin

# System wide environment and startup programs, for login setup
# Functions and aliases go in /etc/bashrc

pathmunge () {
if ! echo $PATH | /bin/egrep -q "(^|$1($|" ; then
if [ "$2" = "after" ] ; then
PATH=$PATH:$1
else
PATH=$1:$PATH
fi
fi
}

# Path manipulation
if [ `id -u` = 0 ]; then
pathmunge /sbin
pathmunge /usr/sbin
pathmunge /usr/local/sbin
fi

pathmunge /usr/X11R6/bin after

CVSROOT=/usr/local/cvsroot
pathmunge $CVSROOT after
export CVSROOT

export EDITOR=vim

JAVA_HOME=/usr/java/j2sdk1.4.2_10

export JAVA_HOME
export PATH="$PATH:$JAVA_HOME/bin"

KOMODO_HOME=/usr/local/Komodo
pathmunge $KOMODO_HOME after
export KOMODO_HOME

ANT_HOME=/usr/share/ant
pathmunge $ANT_HOME/bin after
export ANT_HOME

CATALINA_HOME=/usr/share/tomcat5
export CATALINA_HOME

AXIS_HOME=/usr/local/axis
pathmunge $AXIS_HOME/bin after

AXIS_LIB=$AXIS_HOME/lib
pathmunge $AXIS_LIB after

TOMCAT_HOME=/usr/share/tomcat5
export TOMCAT_HOME
ARKONA_HOME=/srv/www/bcs/
BCS_HOME=/srv/www/bcs/
export BCS_HOME
export ARKONA_HOME

AXISCLASSPATH=$AXIS_LIB/axis.jar:$AXIS_LIB/commons-discovery-0.2.jar:$AXIS_LIB/commons-logging-1.0.4.jar:$AXIS_LIB/jaxrpc.jar:$AXIS_LIB/saaj.jar:$AXIS_LIB/log4j-1.2.8.jar:$AXIS_LIB/wsdl4j-1.5.1.jar:$AXIS_LIB/axis-ant.jar


CLASSPATH=/usr/share/tomcat5/bin:$JAVA_HOME/lib:/usr/share/tomcat5/common/lib:/usr/share/tomcat5:$JAVA_HOME/lib/mysql-connector-java-3.1.12-bin.jar:$AXISCLASSPATH:/usr/local/xerces/resolver.jar:/usr/local/xerces/xercesImpl.jar:/usr/local/xerces/xercesSamples.jar:/usr/local/xerces/xml-apis.jar:/srv/www/bcs/lib/postgresql-8.1-404.jdbc2.jar:
export CLASSPATH

export AXIS_HOME
export AXIS_LIB
export AXISCLASSPATH
export JAVA_OPTS=-Xmx256M

unset pathmunge

# No core files by default
ulimit -S -c 0 > /dev/null 2>&1

USER="`id -un`"
LOGNAME=$USER
MAIL="/var/spool/mail/$USER"

HOSTNAME=`/bin/hostname`
HISTSIZE=1000

if [ -z "$INPUTRC" -a ! -f "$HOME/.inputrc" ]; then
INPUTRC=/etc/inputrc
fi

export PATH USER LOGNAME MAIL HOSTNAME HISTSIZE INPUTRC

for i in /etc/profile.d/*.sh ; do
if [ -r "$i" ]; then
. $i
fi
done

unset i
#
# End of /etc/profile
#
 
Old 01-15-2006, 09:21 PM   #7
megaspaz
Senior Member
 
Registered: Nov 2002
Location: Silly Con Valley
Distribution: Red Hat 7.3, Red Hat 9.0
Posts: 2,054

Rep: Reputation: 46
do these commands and post the output.

echo $JAVA_HOME
echo $PATH
echo $CLASSPATH

it could be that you need to reboot the machine as you could still have a bad path. in other words, if your old path was:

/usr/java/old_java:/usr/local/some_foo

and you altered your path the way you did in your /etc/profile, and then did a source /etc/profile, your path would look like:

/usr/java/old_java/bin:/usr/local/some_foo:/usr/java/new_java/bin

which is clearly not what you want. Anyway, I'm not really sure why your java home var is still showing your old path, as that is odd. I do believe in your case, a reboot would probably solve your path problems, although logging out of your user's session and logging back in should work also.

Last edited by megaspaz; 01-15-2006 at 09:25 PM.
 
Old 01-16-2006, 07:33 AM   #8
sharp81
Member
 
Registered: Mar 2005
Posts: 79

Original Poster
Rep: Reputation: 15
ok , i tried a restart too and still the path of java is showing the old path .. when i echo $JAVA_HOME Iget

/usr/java/j2sdk1.4.2/ but what i want is /usr/lib/jvm/java ... so each time I need to use the path I am running the command export JAVA_HOME=/usr/lib/jvm/java at the shell prompt
 
Old 01-16-2006, 11:09 AM   #9
megaspaz
Senior Member
 
Registered: Nov 2002
Location: Silly Con Valley
Distribution: Red Hat 7.3, Red Hat 9.0
Posts: 2,054

Rep: Reputation: 46
well you need to change the value in your /etc/profile file.

what you posted from your /etc/profile:

JAVA_HOME=/usr/java/j2sdk1.4.2_10

export JAVA_HOME
export PATH="$PATH:$JAVA_HOME/bin"

change that to what you want - /usr/lib/jvm/java

edit: Also, are the permissions correct for /srv/www/bcs/lib/postgresql-8.1-404.jdbc2.jar?

And why did you put the jar file in your server's www directory? I would've put it in a more traditional location on the hard drive. There's no reason to put it in a www folder unless you want to let other people download it...

Last edited by megaspaz; 01-16-2006 at 11:19 AM.
 
Old 01-16-2006, 12:00 PM   #10
sharp81
Member
 
Registered: Mar 2005
Posts: 79

Original Poster
Rep: Reputation: 15
no in fact after changing my configuration ... it still shows the same old path ..... thatīs what I wanted to know
 
Old 01-16-2006, 12:11 PM   #11
megaspaz
Senior Member
 
Registered: Nov 2002
Location: Silly Con Valley
Distribution: Red Hat 7.3, Red Hat 9.0
Posts: 2,054

Rep: Reputation: 46
Okay. I don't know. But there's something that isn't working correctly in your set up.

again run those echo commands and post the output and post your /etc/profile file again.
 
Old 01-16-2006, 12:21 PM   #12
sharp81
Member
 
Registered: Mar 2005
Posts: 79

Original Poster
Rep: Reputation: 15
I tried splitting my profile and profile.d and I guess now I might have messed up something .... could you help me out as with
profile.local I am getting an error msg syntax error at the pathmunge () { line ...
here#s my profile.local configuration file :
# /etc/profile.local for SuSE Linux
#
# (PLEASE DO NOT CHANGE /etc/profile. There are chances that your changes
# will be lost during system upgrades. Instead use /etc/profile.local for
# your local settings, favourite global aliases, VISUAL and EDITOR
# variables, etc ...)
# System wide environment and startup programs, for login setup
# Functions and aliases go in /etc/bashrc
pathmunge {
if ! echo $PATH | /bin/egrep -q "(^|$1($|" ; then
if [ "$2" = "after" ] ; then
PATH=$PATH:$1
else
PATH=$1:$PATH
fi
fi
}

# Path manipulation
if [ `id -u` = 0 ]; then
pathmunge /sbin
pathmunge /usr/sbin
pathmunge /usr/local/sbin
fi

pathmunge /usr/X11R6/bin after

JAVA_HOME=/usr/lib/jvm/java
pathmunge $JAVA_HOME/bin after
export JAVA_HOME

CVSROOT=/usr/local/cvsroot
pathmunge $CVSROOT after
export CVSROOT

export EDITOR=vim

export PATH="$PATH:$JAVA_HOME/bin"

KOMODO_HOME=/usr/local/Komodo
pathmunge $KOMODO_HOME after
export KOMODO_HOME

ANT_HOME=/usr/share/ant
pathmunge $ANT_HOME/bin after
export ANT_HOME

CATALINA_HOME=/usr/share/tomcat5
export CATALINA_HOME

AXIS_HOME=/usr/local/axis
pathmunge $AXIS_HOME/bin after

AXIS_LIB=$AXIS_HOME/lib
pathmunge $AXIS_LIB after

TOMCAT_HOME=/usr/share/tomcat5
export TOMCAT_HOME

AXISCLASSPATH=$AXIS_LIB/axis.jar:$AXIS_LIB/commons-discovery-0.2.jar:$AXIS_LIB/commons-logging-1.0.4.jar:$AXIS_LIB/jaxrpc.jar:$AXIS_LIB/saaj.jar:$AXIS_LIB/log4j-1.2.8.jar:$AXIS_LIB/wsdl4j-1.5.1.jar:$AXIS_LIB/axis-ant.jar


CLASSPATH=/usr/share/tomcat5/bin:$JAVA_HOME/lib:/usr/share/tomcat5/common/lib:/usr/share/tomcat5:$JAVA_HOME/lib/mysql-connector-java-3.1.12-bin.jar:$AXISCLASSPATH:/usr/local/xerces/resolver.jar:/usr/local/xerces/xercesImpl.jar:/usr/local/xerces/xercesSamples.jar:/usr/local/xerces/xml-apis.jar:/srv/www/bcs/lib/postgresql-8.1-404.jdbc2.jar:
export CLASSPATH

export AXIS_HOME
export AXIS_LIB
export AXISCLASSPATH
export JAVA_OPTS=-Xmx256M

unset pathmunge

# No core files by default
ulimit -S -c 0 > /dev/null 2>&1

USER="`id -un`"
LOGNAME=$USER
MAIL="/var/spool/mail/$USER"

HOSTNAME=`/bin/hostname`
HISTSIZE=1000

if [ -z "$INPUTRC" -a ! -f "$HOME/.inputrc" ]; then
INPUTRC=/etc/inputrc
fi

export PATH USER LOGNAME MAIL HOSTNAME HISTSIZE INPUTRC

for i in /etc/profile.d/*.sh ; do
if [ -r "$i" ]; then
. $i
fi
done

unset i
#
# End of /etc/profile.local
#

And this is the profile file :
# /etc/profile for SuSE Linux
#
# PLEASE DO NOT CHANGE /etc/profile. There are chances that your changes
# will be lost during system upgrades. Instead use /etc/profile.local for
# your local settings, favourite global aliases, VISUAL and EDITOR
# variables, etc ...

#
# Check which shell is reading this file
#
if test -f /proc/mounts ; then
case "`/bin/ls -l /proc/$$/exe`" in
*/bash) is=bash ;;
*/rbash) is=bash ;;
*/ash) is=ash ;;
*/ksh) is=ksh ;;
*/zsh) is=zsh ;;
*/*) is=sh ;;
esac
else
is=sh
fi

#
# Initialize terminal
#
tty=`tty 2> /dev/null`
test $? -ne 0 && tty=""
if test -O "$tty" -a -n "$PS1"; then
test -z "${TERM}" && { TERM=linux; export TERM; }
test "${TERM}" = "unknown" && { TERM=linux; export TERM; }
# Do not change settings on local line if connected to remote
if test -z "$SSH_TTY" ; then
test -x /bin/stty && /bin/stty sane cr0 pass8 dec
test -x /usr/bin/tset && /usr/bin/tset -I -Q
fi
# on iSeries virtual console, detect screen size and terminal
if test -d /proc/iSeries -a \( "$tty" = "/dev/tty1" -o "$tty" = "/dev/console" \) ; then
LINES=24; COLUMNS=80; export LINES COLUMNS TERM
test -x /bin/initviocons && { eval `/bin/initviocons -e`; }
fi
fi
unset TERMCAP

#
# Time until a complete key sequence must have arrived
#
#ESCDELAY=2000
#export ESCDELAY

#
# The user file-creation mask
#
umask 022

#
# ksh/ash soemtimes do not know
#
test -z "$UID" && UID=`id -ur 2> /dev/null`
test -z "$EUID" && EUID=`id -u 2> /dev/null`
test -z "$USER" && USER=`id -un 2> /dev/null`
test -z "$MAIL" && MAIL=/var/spool/mail/$USER
test -z "$HOST" && HOST=`hostname -s 2> /dev/null`
test -z "$CPU" && CPU=`uname -m 2> /dev/null`
test -z "$HOSTNAME" && HOSTNAME=`hostname 2> /dev/null`
test -z "$LOGNAME" && LOGNAME=$USER
case "$CPU" in
i?86) HOSTTYPE=i386 ;;
*) HOSTTYPE=${CPU} ;;
esac
OSTYPE=linux
MACHTYPE=${CPU}-suse-${OSTYPE}
# Do NOT export UID, EUID, USER, MAIL, and LOGNAME
export HOST CPU HOSTNAME HOSTTYPE OSTYPE MACHTYPE

#
# Adjust some size limits (see bash(1) -> ulimit)
# Note: You may use /etc/initscript instead to set up ulimits and your PATH.
# Setting of ulimits are skipped if /etc/initscript (ulimit package) exists.
if test "$is" != "ash" -a ! -r /etc/initscript; then
#ulimit -c 20000 # only core-files less than 20 MB are written
#ulimit -d 15000 # max data size of a program is 15 MB
#ulimit -s 15000 # max stack size of a program is 15 MB
#ulimit -m 30000 # max resident set size is 30 MB

ulimit -Sc 0 # don't create core files
ulimit -Sd $(ulimit -Hd)
ulimit -Ss $(ulimit -Hs)
ulimit -Sm $(ulimit -Hm)
fi

#
# Make path more comfortable
#
if test -z "$PROFILEREAD" ; then
PATH=/usr/local/bin:/usr/bin:/usr/X11R6/bin:/bin
if test "$HOME" != "/" ; then
for dir in $HOME/bin/$CPU $HOME/bin ; do
test -d $dir && PATH=$dir:$PATH
done
fi
if test "$UID" = 0 ; then
test -d /opt/gnome/sbin && PATH=/opt/gnome/sbin:$PATH
test -d /opt/kde3/sbin && PATH=/opt/kde3/sbin:$PATH
PATH=/sbin:/usr/sbin:/usr/local/sbin:$PATH
fi
for dir in /var/lib/dosemu \
/usr/games \
/opt/bin \
/opt/gnome/bin \
/opt/kde3/bin \
/opt/kde2/bin \
/opt/kde/bin \
/usr/openwin/bin \
/opt/cross/bin
do
test -d $dir && PATH=$PATH:$dir
done
unset dir
export PATH
fi

#
# Many programs using readline library for line editing
# should know about this (e.g. bash)
#
if test -z "$INPUTRC" ; then
INPUTRC=/etc/inputrc
test -s $HOME/.inputrc && INPUTRC=$HOME/.inputrc
export INPUTRC
fi

#
# Most bourn shell clones knows about this
#
if test -z "$PROFILEREAD" ; then
HISTSIZE=1000
export HISTSIZE
fi

#
# Set some environment variables for TeX/LaTeX
#
if test -n "$TEXINPUTS" ; then
TEXINPUTS=":$TEXINPUTS:$HOME/.TeX:/usr/share/doc/.TeX:/usr/doc/.TeX"
else
TEXINPUTS=":$HOME/.TeX:/usr/share/doc/.TeX:/usr/doc/.TeX"
fi
export TEXINPUTS

#
# Configure the default pager on SuSE Linux
#
if test -z "$LESS" ; then
LESS="-M -I"
LESSKEY=/etc/lesskey.bin
LESSOPEN="lessopen.sh %s"
LESSCLOSE="lessclose.sh %s %s"
LESS_ADVANCED_PREPROCESSOR="no"
PAGER=less
export LESSOPEN LESSCLOSE LESS LESSKEY PAGER LESS_ADVANCED_PREPROCESSOR
fi

#
# Minicom
#
if test -z "$PROFILEREAD" ; then
MINICOM="-c on"
export MINICOM
fi

#
# Current manpath
#
if test -z "$PROFILEREAD" ; then
tmp="$MANPATH"
unset MANPATH
if test -n "$tmp" ; then
MANPATH="${tmp}:`test -x /usr/bin/manpath && /usr/bin/manpath -q`"
else
MANPATH="`test -x /usr/bin/manpath && /usr/bin/manpath -q`"
fi
unset tmp
export MANPATH
fi

#
# Some applications do not handle the XAPPLRESDIR environment properly,
# when it contains more than one directory. More than one directory only
# makes sense if you have a client with /usr mounted via nfs and you want
# to configure applications machine dependent. Uncomment the lines below
# if you want this.
#
#XAPPLRESDIR="$XAPPLRESDIR:/var/X11R6/app-defaults:/usr/X11R6/lib/X11/app-defaults"
#export XAPPLRESDIR

#
# Set INFOPATH to tell xemacs where he can find the info files
#
if test -z "$PROFILEREAD" ; then
tmp="$INFODIR"
if test -n "$tmp" ; then
INFODIR="${tmp}:/usr/local/info:/usr/share/info:/usr/info"
else
INFODIR="/usr/local/info:/usr/share/info:/usr/info"
fi
INFOPATH=$INFODIR
unset tmp
export INFODIR INFOPATH
fi

#
# These settings are recommended for old motif applications
#
if test -z "$PROFILEREAD" ; then
XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB
export XKEYSYMDB
XNLSPATH=/usr/X11R6/lib/X11/nls
export XNLSPATH
fi

if test -s /etc/nntpserver ; then
read NNTPSERVER < /etc/nntpserver
export NNTPSERVER
fi

if test -s /etc/organization ; then
read ORGANIZATION < /etc/organization
export ORGANIZATION
fi

#
# Midnight Commander needs this to run in color mode
#
if test -z "$PROFILEREAD" ; then
COLORTERM=1
export COLORTERM
fi

#
# For RCS
#
#export VERSION_CONTROL=numbered

#
# Source the files generated by SuSEconfig
#
if test -z "$PROFILEREAD" ; then
test -r /etc/profile.d/sh.ssh && . /etc/profile.d/sh.ssh
test -r /etc/SuSEconfig/profile && . /etc/SuSEconfig/profile
if test -z "$SSH_SENDS_LOCALE" ; then
if test -r /etc/sysconfig/language -a -r /etc/profile.d/sh.utf8 ; then
tmp="$(. /etc/sysconfig/language; echo $AUTO_DETECT_UTF8)"
test "$tmp" = "yes" && . /etc/profile.d/sh.utf8
unset tmp
fi
fi
fi

#
# Source profile extensions for certain packages
#
if test -d /etc/profile.d -a -z "$PROFILEREAD" ; then
for s in /etc/profile.d/*.sh ; do
test -r $s && . $s
done
unset s
fi

if test "$is" != "ash" ; then
#
# And now let's see if there is a local profile
# (for options defined by your sysadmin, not SuSE Linux)
#
test -s /etc/profile.local && . /etc/profile.local
fi

#
# Avoid overwriting user settings if called twice
#
if test -z "$PROFILEREAD" ; then
readonly PROFILEREAD=true
export PROFILEREAD
fi

#
# System BASH specials, maybe also good for other shells
#
test -r /etc/bash.bashrc && . /etc/bash.bashrc
if test "$is" = "bash" -a -z "$_HOMEBASHRC" ; then
# loop detection
readonly _HOMEBASHRC=true
test -r $HOME/.bashrc && . $HOME/.bashrc
fi

#
# KSH specials
#
if test "$is" = "ksh" ; then
test -r /etc/ksh.kshrc && . /etc/ksh.kshrc
fi
if test "$is" = "ksh" -a -z "$_HOMEKSHRC" ; then
# loop detection
readonly _HOMEKSHRC=true
test -r $HOME/.kshrc && . $HOME/.kshrc
fi

export POSTGRESQL_HOME=/usr/local/pgsql
export PATH=$PATH:$POSTGRESQL_HOME/bin
#
# End of /etc/profile
#
 
Old 01-16-2006, 12:34 PM   #13
megaspaz
Senior Member
 
Registered: Nov 2002
Location: Silly Con Valley
Distribution: Red Hat 7.3, Red Hat 9.0
Posts: 2,054

Rep: Reputation: 46
what file or files have you made changes to? This having 2 profile files must be a suse thing. When you made changes to one file, did you back out your changes in the other file?

you don't need this line since you use pathmunge earlier.

export PATH="$PATH:$JAVA_HOME/bin"

This is from the top of your line:

pathmunge {

that needs to change to:

pathmunge () {

Also, when you post stuff like your configuration files, put them in the [code] tags. I can't tell what's what with the line due to the smiley stuff and the format is off.

Last edited by megaspaz; 01-16-2006 at 12:35 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Path to java mherring Linux - Software 1 05-04-2005 07:11 PM
Cannot set the path for java jgoggel Programming 2 07-23-2004 06:31 AM
Java can't find package, but PATH set correctly (j2se1.4.0, java.util.regex package) Ethan Programming 5 02-06-2004 09:55 PM
Path to system settings program!?! Punkduplo Red Hat 4 10-25-2003 04:41 AM
modprobe path settings carpman Linux - Software 2 01-02-2002 04:46 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:09 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration