Autorun WinSCP on system's startup + logon + keepuptodate...

Advertisement

joujoujou
Guest

Autorun WinSCP on system's startup + logon + keepuptodate...

Hello.

I'm trying to do all things automatically, but can't get through it.

What I want to do - run WinSCP on windows startup, logon using last (and the only one) saved session and keep remote folder up to date.

Using documentation made batch file:
@ECHO OFF
@ECHO Odpalamy FTP... :-)
@PING 1.1.1.1 -n 1 -w 10000 >NUL
@START C:"\Documents and Settings\joujoujou\Desktop\Pulpitt\winscp\WinSCP.exe" /command /script=test.txt

as well as script file (test.txt), located together with both winscp.exe and winscp.com in the same folder:
option batch on

option confirm off

open user@domain.com

keepuptodate C:\Program Files\Cumulus\web /var/www/domain.com/htdocs/weather

Already tried with quotation marks and without, with options "batch on" and "confirm off" and without them. Nothing happened.

Currently just run application manually, manually logging in and manually starting "keep up to date" option from application's menu. Also with "synchronize on start" "existing files only" and "including subfolders" options ticked.



What am I doing wrong?

Regards,


joujoujou.

Reply with quote

Advertisement

joujoujou
Guest

Thank you. :D

Parameter /console showed me where (actually when) I made a mistake - when my script has been saved, character encoding was set to "unicode" - reedited entire file, saved as ANSI and all works now as I wanted.

Thank you again for your effort and help.

Now results can be seen online at www.joujoujou.com/weather (update is done every 10 minutes when my computer is on).

Reply with quote

joujoujou
Guest

joujoujou wrote:

[...] all works now as I wanted.

[...]

Actually, I was wrong.

It worked, occasionally.

Usually instead of upload I'm getting message as below:

<invalid hyperlink removed by admin>

Obviously in GUI mode all is still correct.

Any ideas?

Reply with quote

Advertisement

joujoujou
Guest

I'm not sure, log attached.

This is the log saved during scripting:
<removed by admin>

Real domain as well as username changed to keep some privacy. All the rest of the log untouched.

Reply with quote

joujoujou
Guest

No, unfortunately. :(

Anyway, GUI mode works O.K. - script not.

Will you, please, delete the log from post above?

Thanks. :)

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
40,476
Location:
Prague, Czechia

Please post a full log file showing the problem.

To generate log file, enable logging, log in to your server and do the operation and only the operation that causes the error. For posting extensive logs you may use pastebin or similar application. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you may email it to me. You will find my address (if you log in) in my forum profile. Please include link back to this topic in your email. Also note in this topic that you have emailed the log.

Reply with quote

Advertisement

You can post new topics in this forum