Daniel,
Your suggestion appears to have solved my problem.
Thank you and very well done. 
I posted this problem to every Linux forum I could find and you are the
only person who could zero in on the problem and solve it. Nobody else
came close.
If you have time, could you possibly explain what the change to
/etc/bashrc/ that you suggested did and why it fixed the problem. I
sense a real learning opportunity here. You have however already gone
above and beyond the call of duty and if you don't respond that's fine.

If you are feeling extra generous with your time, here is another
question prompted by your highly informative responses that you may be
able to help me with.
You made a comment earlier in this exchange of emails as follows;
"It still wouldn't do what you wanted because it would be setting the
PATH variable of a subshell running off the shell you logged in to and
NOT the shell you are typing into."
This made little sense to me as I do not understand how shells and
subshells work.
Could you briefly explain what your comment meant. Even if I don't
understand your response, it will guide me in further research. I would
like to learn about shells and how they operate. Can you recommend any
references (web or other) that I might consult to increase my knowledge
in this area? I will search also.

Thanks again.
Regards
Andrew   

>>> "Daniel Bush" <[EMAIL PROTECTED]> 09/29/06 7:05 PM >>>
G'day Andrew,
Yeah, I think I can probably see it.
In your /etc/bashrc you have a line near the bottom:

"PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/share/pvm3/".

If I'm right, thats your prob.

Change to
PATH=$PATH:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/share/pvm3/

In my previous response I was going to mention that if PATH was being
clobbered, the culprit might be identifiable from your existing PATH
ie the pvm3.

It seems to bear this out.

And don't forget to clobber the person that put that line in :D

Cheers,
Daniel.

On 29/09/06, Andrew Dunkin <[EMAIL PROTECTED]> wrote:
> Daniel,
> Thanks. Still no success, but here is the latest.
>
> # HERE IS MY ORIGINAL .bash_profile
> #########################################
> # .bash_profile
>
> # Get the aliases and functions
> if [ -f ~/.bashrc ]; then
>    . ~/.bashrc
> fi
>
> # User specific environment and startup programs
>
> PATH=$PATH:$HOME/bin
>
> export PATH
> unset USERNAME
> #########################################
>
> #########################################
> # I THEN EDITED .bash_profile AS FOLLOWS,  LOGGED OUT & IN;
> #
> # .bash_profile
>
> # Get the aliases and functions
> if [ -f ~/.bashrc ]; then
>    . ~/.bashrc
> fi
>
> # User specific environment and startup programs
>
> PATH=$PATH:$HOME/bin
>
> export PATH
> unset USERNAME
> export PATH=$PATH:/usr/java/j2sdk1.4.2_07/bin/
>
> ## THIS DID NOT WORK. JAVA COMMANDS NOT FOUND.
> ##################################################
>
> ##################################################
>
> ## SO I EDITED IT AS FOLLOWS, LOGGED OUT & IN;
>
> # .bash_profile
>
> # Get the aliases and functions
> if [ -f ~/.bashrc ]; then
>    . ~/.bashrc
> fi
>
> # User specific environment and startup programs
>
> PATH=$PATH:$HOME/bin
>
> export PATH=$PATH:/usr/java/j2sdk1.4.2_07/bin/
> unset USERNAME
>
> ## THIS DID NOT WORK.  JAVA COMMANDS NOT FOUND.
> #################################################
>
> ################################################
> ## I THEN EDITED IT AS FOLLOWS, LOGGED OUT & IN;
> # .bash_profile
>
> # Get the aliases and functions
> if [ -f ~/.bashrc ]; then
>    . ~/.bashrc
> fi
>
> # User specific environment and startup programs
>
> PATH=$PATH:$HOME/bin:/usr/java/j2sdk1.4.2_07/bin/
>
> export PATH
> unset USERNAME
> ## THIS DID NOT WORK EITHER. JAVA COMMANDS NOT FOUND.
> #########################################################
>
> #########################################################
> Below are my original files;
> /home/<user>/.bash_profile<~!B*+R^&>> /home/<user>/.bashrc<~!B*+R^&>>
/etc/bashrc
> /etc/profile
>
> Can you see anywhere where the PATH is being reset in any of these?
> I am not quite sure how to interpret the contents of these files.
> Can you think of any other edits that may work?
> #########################################################
> # .bash_profile
>
> # Get the aliases and functions
> if [ -f ~/.bashrc ]; then
>    . ~/.bashrc
> fi
>
> # User specific environment and startup programs
>
> PATH=$PATH:$HOME/bin
>
> export PATH
> unset USERNAME
> ########################################################
>
> #########################################################
> # .bashrc
>
> # User specific aliases and functions
>
> # Source global definitions
> if [ -f /etc/bashrc ]; then
>    . /etc/bashrc
> fi
> #######################################################
>
>
> #########################################################
> # /etc/bashrc
>
> # System wide functions and aliases
> # Environment stuff goes in /etc/profile
>
> # by default, we want this to get set.
> # Even for non-interactive, non-login shells.
> if [ "`id -gn`" = "`id -un`" -a `id -u` -gt 99 ]; then
>    umask 002
> else
>    umask 022
> fi
>
> # are we an interactive shell?
> if [ "$PS1" ]; then
>    case $TERM in
>    xterm*)
>        PROMPT_COMMAND='echo -ne "\033]0;[EMAIL PROTECTED]:
> ${PWD}\007"'
>        ;;
>    *)
>        ;;
>    esac
>    [ "$PS1" = "\\s-\\v\\\$ " ] && PS1="[EMAIL PROTECTED] \W]\\$ "
>
>    if [ -z "$loginsh" ]; then # We're not a login shell
>        for i in /etc/profile.d/*.sh; do
>        if [ -x $i ]; then
>            . $i
>        fi
>    done
>    fi
> fi
>
> unset loginsh
> # PVM environement
> export PVM_RSH=/usr/bin/rsh
> export PVM_ROOT=/usr/share/pvm3
> export PVMD_NOHOLD=ON
> export PVM_TMP=/var/run/pvm3
> export XPVM_ROOT=/usr/X11R6/lib/xpvm/
> export
> PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/share/pvm3/
> ##########################################################
>
> #########################################################
>
> # /etc/profile -*- Mode: shell-script -*-
> # (c) MandrakeSoft, Chmouel Boudjnah
<[EMAIL PROTECTED]><~!B*+R^&>><~!B*+R^&>> loginsh=1
>
> # Users generally won't see annoyng core files
> [ "$UID" = "0" ] && ulimit -S -c 1000000 > /dev/null 2>&1
>
> if ! echo ${PATH} |grep -q /usr/X11R6/bin ; then
>    PATH="$PATH:/usr/X11R6/bin"
> fi
>
> if [ "$UID" -ge 500 ] && ! echo ${PATH} |grep -q /usr/games ; then
>    export PATH=$PATH:/usr/games
> fi
>
> umask 022
>
> USER=`id -un`
> LOGNAME=$USER
> MAIL="/var/spool/mail/$USER"
> HISTCONTROL=ignoredups
> HOSTNAME=`/bin/hostname`
> HISTSIZE=1000
>
> if [ -z "$INPUTRC" -a ! -f "$HOME/.inputrc" ]; then
>    INPUTRC=/etc/inputrc
> fi
>
> # some old programs still use it (eg: "man"), and it is also
> # required for level1 compliance for LI18NUX2000
> NLSPATH=/usr/share/locale/%l/%N
>
> export PATH PS1 USER LOGNAME MAIL HOSTNAME INPUTRC NLSPATH
> export HISTCONTROL HISTSIZE
>
> for i in /etc/profile.d/*.sh ; do
>    if [ -x $i ]; then
>        . $i
>    fi
> done
>
> unset i
> #########################################################
> #########################################################
> ######################################################END
>
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html

**********************************************
Internet mail is to be used for NSW Fire Brigades Business 
Only. 
The NSW Fire Brigades reserves the right to monitor and 
filter content considered inappropriate.
**********************************************


********NSW Fire Brigades Confidentiality Notice********

This electronic transmission, including any attachments, may 
contain information which is confidential and/or privileged. 
If you are not the intended recipient of this message, any 
dissemination, copying or action taken in reliance of its 
contents is strictly prohibited. If you have received 
this message in error, please notify the sender immediately.

************************************************
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html

Reply via email to