When I launch my script, instead of going in active "current", WinSCP goes in the last "current" visited on this server. I tried to empty the cache via WinSCP, but it doesn't works.
An idea how to regulate this problem ?
Setup a stored session with option "Cache directory changes" turned off. Use that stored session from your script.
rem boucle sur les serveurs for /L %%i in (68,1,80) do call ::Go %%i goto :end rem Creation du fichier des commandes SFTP echo option confirm off>sftp.txt echo open %LOGIN%:%PASSWORD2firstname.lastname@example.org.%1>>sftp.txt echo cd ../../exec/applis/myAppli/current/logs>>sftp.txt echo option transfer binary>>sftp.txt echo get *.log c:\recup_FTP\80\>>sftp.txt echo close>>sftp.txt rem echo exit>>sftp.txt winscp3 /console /script=sftp.txt
Do you run the script with the same account (on local machine) as with which you have configured the stored session? (read corresponding FAQ).
option confirm off open login:email@example.com cd ../../exec/applis/myAppli/current/logs option transfer binary get *.log c:\myDirectory\ close
[Sessions\Default%20Settings] CacheDirectories=0 CacheDirectoryChanges=0 PreserveDirectoryChanges=0
You can post new topics in this forum