I have a script at Server B. I want to run it from server A via another script. I tried the following command. ssh mss@247.123.456.123 "sh pm10.sh"
It's getting login automatically, but while running the script through error like "reppar: command not found" where reppar is an application installed in the remote machine. I am able to run the same script via manual ssh. But unable to do via script. Please help
It might be missing from the PATH, running it directly may prevent it doing an actual shell login and getting your usual shell variabies. something like ssh username@host . /etc/profile ';' mycommand could rectify that