Just tried this on a Red Hat box (EL4). I get a return code of 0 for the
same commands.
We have a SSH return code problem when we use SSH in batch in Solaris.
We haven't this problem on RedHat.
bash-2.05$ cat a.sftp
ls -l
pwd
get b.txt
ls -l
bash-2.05$ sftp -b a.sftp
I've looked through ssh man page and FAQ and tried a google search, but
can't seem to figure out how to use ssh to start a command on a remote
machine, have ssh exit immediately, and still have the command running
on the remote machine.
When I do
[popcorn][~]$ time ssh [EMAIL PROTECTED]
The second ls -l command successfully completes. Therefore the return code
is zero.
We have a SSH return code problem when we use SSH in batch in Solaris.
We haven't this problem on RedHat.
bash-2.05$ cat a.sftp
ls -l
pwd
get b.txt
ls -l
bash-2.05$ sftp -b a.sftp