[Ssh-sftp-perl-users] help needed with SFTP
Brought to you by:
dbrobins
From: Howard, C. <Ho...@pr...> - 2009-01-22 17:26:12
|
Hello, I am attemping to write a simple perl script to upload a file to a remote site using sftp. I am used to Net::FTP so my script follows along similar lines. I think that lack of sophistication is probably a large part of my problem! Problem #1: running a small test script with debug turned on I see that my login sequence gets held up for quite awhile before finally saying "Entering Diffie-Hullman Group 1 key exchange". Then it moves along and gets me logged in with my username and password. Is there any way to avoid the long delay? Problem #2: I need to change directory on the remote machine and then upload my file. I cannot find any "cd" type of command. I have attempted to use the full pathname in the "put", but that also seems to not be working as I expect. Does anyone have a simple example of logging in with a name and password, navigating to a directory, uploading/downloading a file? Chris |