[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Transferring files over SSH in the console

On 2010-03-21 18:47, Dotan Cohen wrote:
Sigh.  What exactly are you trying to *accomplish*????

Just an example:
I want to move a tarball to the machine, unpack it there then edit a
file it in. I then want to make that file executable, run it, and
transfer the output file back to my localhost.

Always starting from machine_a, where machine_b is the "original" remote host.

1. ssh user@machine_b
2. scp -v user@machine_a:/some/tar/ball .
3. untar ...
4. chmod u+x
5. ./whatever
6. scp -v output.txt user@machine_a:/home/user/.
7. exit

1. scp -v /some/tar/ball user@machine_b:/home/user/.
2. ssh user@machine_b
3. untar ...
4. chmod u+x
5. ./whatever
6. exit
7. scp -v user@machine_b:/home/user/output.txt .

"History does not long entrust the care of freedom to the weak
or the timid."  Dwight Eisenhower

Reply to: