|
How to call Shell Script on a remote server with remote servers env variables
Hello,
I need to call a shell script on the remote server which uses hadoop command. Now the remote server is a part of hadoop cluster and its environment is set up such that
"hadoop fs -ls" works on it.
But when I call a shell script from my own linux machine on this remote server that uses above command it fails saying hadoop command not found.
My question is : What do I need to do in order to call a script on the remote server in such way that it uses environmental variables from the remote server.
Currently, i use ssh <user>@remote <full path to shell script > to launch..
If there's any other way to call the shell script, please let me know
Thanks in advance!
|