Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 05 Jan 2002 20:42:04 -0500
From:      Gerard Samuel <trini0@optonline.net>
To:        FreeBSD Questions <questions@FreeBSD.ORG>
Subject:   Re: scp  job
Message-ID:  <3C37AB6C.2070605@optonline.net>
References:  <20020105161404.F49802-100000@stereophonic.noops.org>

next in thread | previous in thread | raw e-mail | index | archive | help
maybe Im brain dead.  Cant get this blasted thing going...

Thomas Cannon wrote:

> http://www.cvm.uiuc.edu/~ms-drake/linux/ssh_nopw.html is how you ssh/scp
> without a password. Your 'permission denied' also might be you not having
> write permissions to where you are trying to put that file, too.
> 
>>From reading what you've done, I also think you might have it backwards.
> You run ssh-keygen on the sending box, not the recieving one.
> 
> -tcannon
> 
> PS: you should also either set your $PATH in the script or use absolute
> path names, like /usr/local/bin/zip, /usr/bin/scp, etc. Your script won't
> run without that, as cron won't have /usr/local/bin in it's path (most
> likely), and it's also a little bit more secure to use complete path
> names.
> 
> PPS: Also, if you do a 'ssh -v' you'll get verbose output, and it's likely
> that you'll see why your login is failing, if it actually is.
> 
> 
> On Sat, 5 Jan 2002, Gerard Samuel wrote:
> 
> 
>>Hey all.  Im trying to setup a cron job involving scp.
>>So Im trying to make a script.
>>All the boxes are on my lan.
>>On the recieving box, I ran ssh-keygen and copyed the identity file via
>>scp to where the script is supposed to run.  Here is the script
>>---------------------------------------
>>
>>#!/bin/sh
>>zip -r /tmp/html_dev /files/www/data/test
>>scp -i /root/bin/identity /tmp/html_dev.zip developer@gatekeeper:
>>rm /tmp/html_dev.zip
>>
>>----------------------------------------
>>
>>When I try to run it I get this after its finished the zip portion.
>>
>>Permission denied.
>>lost connection
>>
>>I tried using the identity.pub file also, but no dice..
>>How does one automate scp to get its password so the script could finish
>>the job??
>>
>>Thanks
>>
>>
>>To Unsubscribe: send mail to majordomo@FreeBSD.org
>>with "unsubscribe freebsd-questions" in the body of the message
>>
>>
> 
> 



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3C37AB6C.2070605>