[plug] Using SCP without entering a password interactively

Jeremy Malcolm Jeremy at Malcolm.wattle.id.au
Thu Sep 27 13:23:12 WST 2001


Mike Hasleby wrote:
> 
> List,
> 
> We need to set up a script to copy files between two of our servers
> using scp. Problem is, scp seems to need a password every time it is
> used. This is unhelpful when it needs one at 2am when the script will be
> run :)
> 
> Is there any way of passing a password to scp on the command line or in
> a config file, etc.?

Yes this is easy to do, you just need to create your ssh private key
without a passphrase on it, then copy the public key (normally the
filename is identity.pub) to the other machine's ~/.ssh directory and
name it "authorized_keys".  That should be all there is to it...

-- 
JEREMY MALCOLM <Jeremy at Malcolm.wattle.id.au> http://malcolm.wattle.id.au
Providing online networks of Australian lawyers (http://www.ilaw.com.au)
and Linux experts (http://www.linuxconsultants.com.au) for instant help!
Disclaimer: http://www.terminus.net.au/disclaimer.html. GPG key: finger.



More information about the plug mailing list