3

I am trying to modify the PATH variable of my SSH server such at a non-interactive shell command ssh myserver.com 'echo $PATH' returns the desired path. I tried modifying ~/.bashrc and ~/.profile files but they only modify PATH for when I log in to the server interactively, i.e. ssh myserver.com.

Can I change this behavior in RHEL5?

user1027169
  • 2,627
  • 3
  • 27
  • 50
  • possible duplicate http://stackoverflow.com/questions/940533/how-do-i-set-path-such-that-ssh-userhost-command-works – wlf Feb 06 '13 at 14:07

1 Answers1

0

~/.bash_profile is where you want to place these variables. I don't believe that bash uses ~/.profile ( I believe it is used by csh and tcsh )

hro
  • 11
  • 2