I am trying to run a program from hostA to hostB using rsh, however when I execute
rsh hostB -l myuser mycommand
mycommand fails because the environment is not correct. I have checked it by running rsh hostB -l myuser set and have seen that the environment variables are not the same for when I log into the hostB with myuser.
check that all the paths and expected environment settings required for the script also exist in the remote server ... if file/directory paths are already there, check the shell initialization files (i.e., $HOME/.profile, $HOME/.login, etc.) for the account running the script to make sure it is setting up the correct variables ... or --- specify them directly on the script ....