WinSCP 保持最新命令卡在检查更改上

WinSCP Keep up to date command stuck on checking for changes

我目前正在我的本地环境中测试 keepuptodate 命令以便在服务器上部署正确的完整命令,但我遇到了 keepuptodate.

的问题

我在 Windows 10 上,"Xlight FTP Server" 作为测试服务器,我在 WinSCP 上将访问权限保存为 "test_local"(我知道这不是一个好习惯,但这只是一个测试)

我在shell中写的命令是

WinSCP.exe test_local /Console /Script=script.txt

并且 script.txt 包含

option batch on
option confirm off
option transfer automatic
keepuptodate -delete F:\mirror_test /
close
exit

我还尝试在启用日志记录的情况下记录脚本

/log="F:\WinSCP.log"

选项和日志

. 2020-03-08 15:07:06.590 --------------------------------------------------------------------------
. 2020-03-08 15:07:06.590 Using FTP protocol.
. 2020-03-08 15:07:06.590 Doing startup conversation with host.
> 2020-03-08 15:07:06.591 PWD
< 2020-03-08 15:07:06.690 257 "/"
. 2020-03-08 15:07:06.691 Getting current directory name.
. 2020-03-08 15:07:06.691 Startup conversation with host finished.
< 2020-03-08 15:07:06.691 Script: Active session: [1] anonymous@192.168.1.81
> 2020-03-08 15:07:06.692 Script: option transfer binary
< 2020-03-08 15:07:06.692 Script: transfer        binary    
> 2020-03-08 15:07:06.693 Script: keepuptodate F:\mirror_test /
< 2020-03-08 15:07:06.693 Script: Checking for changes started, press 'Ctrl-C' to stop...
< 2020-03-08 15:07:06.694 Script: Looking for subfolders in 'F:\mirror_test'...
. 2020-03-08 15:07:06.694 Keep up to date: Looking for subfolders in 'F:\mirror_test'...
< 2020-03-08 15:07:06.705 Script: Checking for changes in folder 1...
. 2020-03-08 15:07:06.707 Keep up to date: Checking for changes in folder 1...
. 2020-03-08 15:07:36.532 Sending dummy command to keep session alive.
> 2020-03-08 15:07:36.532 TYPE A
< 2020-03-08 15:07:37.032 200 Type set to A.

然后一切都卡住了。

keepuptodate 命令仅在某些内容发生变化时执行某些操作。它不同步目录,如果它们不同步,当命令启动时。

要同步目录,请使用 synchronize command

如果您仍想持续同步更改,可以按 keepuptodate 进行操作。