Re: Multiple modes? throught one connection
From: Darren Tucker (dtucker_at_zip.com.au)
Date: 09/15/04
- Previous message: Edwin: "Re: mmap failure (???) causes my SSH installation to not work?"
- In reply to: Tim Nelson: "Multiple modes? throught one connection"
- Next in thread: Tim Nelson: "RE: Multiple modes? throught one connection"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Wed, 15 Sep 2004 21:01:58 +1000 To: Tim Nelson <tim.nelson@webalive.biz>
Tim Nelson wrote:
> Hi all. I often want to scp a file somewhere and then run it. At
> the moment, I have to do an scp followed by an ssh (in a script) so I
> need to type the password twice. Is there a way of linking the two
> together somehow so that it will, through the one connection, trnasfer
> the file, and then run the command? If so, is there somewhere that I
> can find documentation on how to do this?
If you're using a recent OpenSSH, check the ssh(1) man page for
ControlMaster and ControlPath.
You don't need to scp the script to execute it, though. Try:
$ ssh yourserver /bin/sh <script.sh
--
Darren Tucker (dtucker at zip.com.au)
GPG key 8FF4FA69 / D9A3 86E9 7EEE AF4B B2D4 37C9 C982 80C7 8FF4 FA69
Good judgement comes with experience. Unfortunately, the experience
usually comes from bad judgement.
- Previous message: Edwin: "Re: mmap failure (???) causes my SSH installation to not work?"
- In reply to: Tim Nelson: "Multiple modes? throught one connection"
- Next in thread: Tim Nelson: "RE: Multiple modes? throught one connection"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|