The easiest way is to swap ssh keys so no password is required.

If that's not possible, you'll need the "Expect" module to handle the
interactive session.

--edan


> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
> Behalf Of Svetlana Degtiar
> Sent: Monday, February 04, 2008 10:41
> To: [email protected]
> Subject: [Israel.pm] Automate scp
> 
> Hi,
> 
> I want to automate scp. I had the password and the scp
> (/Users/xyz/test.txt
> [EMAIL PROTECTED]:/tmp) command in a file (Suppose).
> 
> I am able to execute the scp command successfully but I am not able to
> enter
> password automatically.
> 
> Can any one suggest how to do it or any other way in Perl or shell to
> do
> that.
> 
> 
> 
> Thanks,
> 
> Sveta.
> 
> 
> _______________________________________________
> Perl mailing list
> [email protected]
> http://perl.org.il/mailman/listinfo/perl
_______________________________________________
Perl mailing list
[email protected]
http://perl.org.il/mailman/listinfo/perl

Reply via email to