Topic "Synchronization Problem"

Author Message
tyyong87

Guest


Hi all,

I have a batch file performing the sync task, the problem that i facing is changes in local does not reflect to the server. Please refer to my command below, thanks.


Batch File
WinSCP.com /script=sync.txt
exit

sync.txt
open ftp://username:pw@ip:21 -passive
synchronize remote "source" "target" -delete -criteria=both
bye


Local PC:
-one of the MDB in sub directory
-last modification time = 02 August 2011 10:40:10
-win xp

Remote PC
-last modification time = 02 August 2011 10:00:07
-win server 2008


The changes from the local does not reflect to the server, may i know where is my mistake? Thanks a lot!
Advertisements
tyyong87

Guest


tyyong87 wrote:
Hi all,

I have a batch file performing the sync task, the problem that i facing is changes in local does not reflect to the server. Please refer to my command below, thanks.


Batch File
WinSCP.com /script=sync.txt
exit

sync.txt
open ftp://username:pw@ip:21 -passive
synchronize remote "source" "target" -delete -criteria=both
bye


Local PC:
-one of the MDB in sub directory
-last modification time = 02 August 2011 10:40:10
-win xp

Remote PC
-last modification time = 02 August 2011 10:00:07
-win server 2008


The changes from the local does not reflect to the server, may i know where is my mistake? Thanks a lot!



Type with local last modification time: 02 August 2011 10:10:40
ciove
[View user's profile]

Joined: 2011-06-22
Posts: 9
Hi,
Two things came to my mind:

1. To debug use:
WinSCP.com /script=sync.txt /log=Sync.log

Sync.log will contain detailed data of the transfer.

2. With "MDB", do you refer to a database file?
If so, is the database closed? If it's open, you cannot copy the file. If you try to copy while the database is open, and if this succeeds, the copy will not contain the same content as the original.
tyyong
[View user's profile]

Joined: 2011-08-08
Posts: 2
Below are part of the log file, could anyone help on this?
I couldn't see any mistake from the log file Confused


. 2011-08-09 05:51:34.750 --------------------------------------------------------------------------
. 2011-08-09 05:51:34.750 WinSCP Version 4.2.8 (Build 818) (OS 5.1.2600 Service Pack 3)
. 2011-08-09 05:51:34.750 Login time: Tuesday, August 09, 2011 5:51:34 AM
. 2011-08-09 05:51:34.750 --------------------------------------------------------------------------
. 2011-08-09 05:51:34.765 Host name: (IP) (Port: 21)
. 2011-08-09 05:51:34.765 User name: (USER) (Password: Yes, Key file: No)
. 2011-08-09 05:51:34.765 Tunnel: No
. 2011-08-09 05:51:34.765 Transfer Protocol: FTP
. 2011-08-09 05:51:34.765 Ping type: C, Ping interval: 30 sec; Timeout: 15 sec
. 2011-08-09 05:51:34.765 Proxy: none
. 2011-08-09 05:51:34.765 FTP: FTPS: None; Passive: Yes [Force IP: No]
. 2011-08-09 05:51:34.765 Local directory: default, Remote directory: home, Update: No, Cache: Yes
. 2011-08-09 05:51:34.765 Cache directory changes: Yes, Permanent: Yes
. 2011-08-09 05:51:34.765 DST mode: 1
. 2011-08-09 05:51:34.765 --------------------------------------------------------------------------
. 2011-08-09 05:51:34.765 Connecting to (IP) ...
. 2011-08-09 05:51:34.765 Connected with (IP). Waiting for welcome message...
< 2011-08-09 05:51:34.765 220-Microsoft FTP Service
< 2011-08-09 05:51:34.765 220 (NAME) FTP
> 2011-08-09 05:51:34.765 USER (USER)
< 2011-08-09 05:51:34.765 331 Password required for (USER).
> 2011-08-09 05:51:34.765 PASS **********
< 2011-08-09 05:51:34.765 230-Welcome
< 2011-08-09 05:51:34.765 230 User logged in.
> 2011-08-09 05:51:34.765 SYST
< 2011-08-09 05:51:34.765 215 Windows_NT
> 2011-08-09 05:51:34.765 FEAT
< 2011-08-09 05:51:34.765 211-Extended features supported:
< 2011-08-09 05:51:34.765 LANG EN*
< 2011-08-09 05:51:34.765 UTF8
< 2011-08-09 05:51:34.765 AUTH TLS;TLS-C;SSL;TLS-P;
< 2011-08-09 05:51:34.765 PBSZ
< 2011-08-09 05:51:34.765 PROT C;P;
< 2011-08-09 05:51:34.765 CCC
< 2011-08-09 05:51:34.765 HOST
< 2011-08-09 05:51:34.765 SIZE
< 2011-08-09 05:51:34.765 MDTM
< 2011-08-09 05:51:34.765 REST STREAM
< 2011-08-09 05:51:34.765 211 END
> 2011-08-09 05:51:34.765 OPTS UTF8 ON
< 2011-08-09 05:51:34.765 200 OPTS UTF8 command successful - UTF8 encoding now ON.
. 2011-08-09 05:51:34.765 Connected
. 2011-08-09 05:51:34.765 --------------------------------------------------------------------------
. 2011-08-09 05:51:34.765 Using FTP protocol.
. 2011-08-09 05:51:34.765 Doing startup conversation with host.
> 2011-08-09 05:51:34.765 PWD
< 2011-08-09 05:51:34.781 257 "/" is current directory.
. 2011-08-09 05:51:34.781 Getting current directory name.
. 2011-08-09 05:51:34.781 Startup conversation with host finished.
< 2011-08-09 05:51:34.781 Script: Active session: [1] (USER)@(IP)
> 2011-08-09 05:51:34.781 Script: option include "*.mdb; */"
< 2011-08-09 05:51:34.781 Script: include *.mdb; */



. 2011-08-09 05:51:34.843 Collecting synchronization list for local directory 'C:\Documents and Settings\CTT\My Documents\L10H1-Calibration\2011\AUGUST' and remote directory 'Calibration\Line10 Head1/2011/AUGUST', mode = 0, params = 1027
. 2011-08-09 05:51:34.843 Retrieving directory listing...
> 2011-08-09 05:51:34.843 CWD /Calibration/Line10 Head1/2011/AUGUST/
< 2011-08-09 05:51:34.843 250 CWD command successful.
> 2011-08-09 05:51:34.843 PWD
< 2011-08-09 05:51:34.843 257 "/Calibration/Line10 Head1/2011/AUGUST" is current directory.
> 2011-08-09 05:51:34.843 TYPE A
< 2011-08-09 05:51:34.843 200 Type set to A.
> 2011-08-09 05:51:34.843 PASV
< 2011-08-09 05:51:34.843 227 Entering Passive Mode (10,5,10,118,227,167).
> 2011-08-09 05:51:34.843 LIST -a
< 2011-08-09 05:51:34.843 150 Opening ASCII mode data connection.
< 2011-08-09 05:51:34.843 226 Transfer complete.
. 2011-08-09 05:51:34.843 Directory listing successful
tyyong
[View user's profile]

Joined: 2011-08-08
Posts: 2
I remember synchronizing is based on the last modified time
Will it cause the problem if both computer is set in different time zone?

FYI, the local PC is set to (GMT +09:00) Osaka, Sapporo, Tokyo
and the remote PC is set to (UTC +08:00) Kuala Lumpur, Singapore


Please advise, thank you in advance. Wink
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24991
Location: Prague, Czechia
First, try to compare the directories in the GUI visually. Check the timestamps of local and remote file. Is the local file indeed seen as newer by WinSCP?
_________________
Martin Prikryl
none

Guest


i have sync issue as well
Guest




i tested winscp today for first time - downloaded all files from web server, then purposely changed one file locally, and tried to sync / check for changes using both time and file size as criteria - files were reported as no differences detected. i also setup a script and ran from the command line with same results - no differences detected.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24991
Location: Prague, Czechia
Anonymous wrote:
i tested winscp today for first time - downloaded all files from web server, then purposely changed one file locally, and tried to sync / check for changes using both time and file size as criteria - files were reported as no differences detected. i also setup a script and ran from the command line with same results - no differences detected.

Please read FAQ:
https://winscp.net/eng/docs/faq_synchronize

If that does not help, come back.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License