Ulrike wrote:
Hi,
im uploading multiple files via script to one SFTP server. Each file is done with one script. After uploading 5 files (running 5 scripts) the login to the server is not possible for the next 2 or 3 minutes.
<--- SNIP
option batch on
option confirm off
open sftp://<user>:<pw>@<ip>:<port>
session
option transfer binary
put <file>
exit
--> SNAP
Any suggestions?
Regards,
Ulrike
The simplest (but not most elegant) solution is to list all files in the one script:
option batch on
option confirm off
open sftp://<user>:<pw>@<ip>:<port>
session
option transfer binary
put <file1>
put <file2>
put <file3>
put <file4>
put <file5>
put <file6>
put <file7>
exit
But why don't you use a wildcard instead? For example, if all the files you are uploading share the same extension (for example .txt) you could do this:
put *.txt
There are other examples here:
https://winscp.net/eng/docs/scriptcommand_put