FTP - 'Preserve file dates' - but not hundredths of a second
Moderators: Hacker, petermad, Stefan2, white
FTP - 'Preserve file dates' - but not hundredths of a second
Hi!
It's quite well thought out, that you can choose 'Preserve file dates' when you copy to an FTP-server, but on the FTP-server, that I am trying to use as an online backup, the hundredths (fractions of a second) in the time-stamp are not preserved on the FTP-server, and that destroys "the perfect match" of the "Synchronize directories" function.
Can that problem be solved?
It seems the FTP-server is running something called Pure-FTPd - http://pureftpd.org/ .
Thank you everybody.
Love,
HeRo
It's quite well thought out, that you can choose 'Preserve file dates' when you copy to an FTP-server, but on the FTP-server, that I am trying to use as an online backup, the hundredths (fractions of a second) in the time-stamp are not preserved on the FTP-server, and that destroys "the perfect match" of the "Synchronize directories" function.
Can that problem be solved?
It seems the FTP-server is running something called Pure-FTPd - http://pureftpd.org/ .
Thank you everybody.
Love,
HeRo
- sqa_wizard
- Power Member
- Posts: 3869
- Joined: 2003-02-06, 11:41 UTC
- Location: Germany
Bad cards ...Can that problem be solved?
Let me first explain how 'Preserve file dates' works:
- After you transfered your file to the FTP server, the file time is set by the FTP server directly to its own local time.
- Next TC has to set the time for this file individually.
For this task TC has to use a command, which is supported by the FTP server.
Depending of the FTP server brand and version it may be one of SITE UTIME or MDTM or MFMT or alike.
AFAIK none of this commands supports fractions of a second.
This means, even is TC wants to set it like this, there is no command to do it
#5767 Personal license
MFMT does. It uses time format defined in RFC 3659 and it allows optional fractions of seconds.sqa_wizard wrote:AFAIK none of this commands supports fractions of a second.
But according to my testing, TC does not set them when uploading the file (it calls MFMT without fractions of second). They're only preserved when downloading (server reports fractions of seconds and TC sets them in local filesystem).
But what I find really strange, in Synchronize directories, my TC seems to ignore time differences up to whole three seconds. It clearly shows different times for those files, but marks them as same. And it does that for both FTP and local FS. So how your TC can show files as different when their modification time differs by less than second, it's mystery for me...
Hello, HeRo.
There is a special section inside the Total Commander helpfile which explains how to use the "Synchronize Directories" function towards an FTP server.
Menus => Menu Commands => Synchronizes Dirs and from there
=> Synchronize dirs and FTP servers
=> Synchronize dirs with FTP and MLSD command
Are you sure that you are following the procedures explained there exactly?
If you use Synchronisze Dirs to an FTP server, the local files will receive the timestamps found on the FTP server after upload. So there is little chance of the timestamps differing by milliseconds.
If the FTP connection can use MLSD, timestamps will have hh24:mi:ss, no fractions of seconds.
If the FTP connection cannot use MLSD, but LIST, timestamps may not hold any seconds at all, which would equal 0, but only hh24:mi.
Kind regards,
Karl
There is a special section inside the Total Commander helpfile which explains how to use the "Synchronize Directories" function towards an FTP server.
Menus => Menu Commands => Synchronizes Dirs and from there
=> Synchronize dirs and FTP servers
=> Synchronize dirs with FTP and MLSD command
Are you sure that you are following the procedures explained there exactly?
If you use Synchronisze Dirs to an FTP server, the local files will receive the timestamps found on the FTP server after upload. So there is little chance of the timestamps differing by milliseconds.
If the FTP connection can use MLSD, timestamps will have hh24:mi:ss, no fractions of seconds.
If the FTP connection cannot use MLSD, but LIST, timestamps may not hold any seconds at all, which would equal 0, but only hh24:mi.
Kind regards,
Karl
Hello, HeRo.
In case the FTP connection which is used for a "Synchronize Dirs" operation has been set to use the FTP LIST command, it may happen that the FTP server does not report seconds in the timestamps at all. - Depends on the FTP server. - Missing seconds will be interpreted as 0 by T.C.
In case the FTP connection which is used for a "Synchronize Dirs" operation has been set to use the FTP MLSD command, the FTP server will report timestamps including seconds.
Now I guess you know what the potential pitfall can be:
FTP server ABCD can handle both, LIST and MLSD.
Interchangeably, you use a configuration which tells the server to use LIST, and another configuration which tells the server to used MLSD,
then the effect may be that a part of your local files will suddenly differ from the server by a few seconds.
Could this have happened?
Kind regards,
Karl
In case the FTP connection which is used for a "Synchronize Dirs" operation has been set to use the FTP LIST command, it may happen that the FTP server does not report seconds in the timestamps at all. - Depends on the FTP server. - Missing seconds will be interpreted as 0 by T.C.
In case the FTP connection which is used for a "Synchronize Dirs" operation has been set to use the FTP MLSD command, the FTP server will report timestamps including seconds.
Now I guess you know what the potential pitfall can be:
FTP server ABCD can handle both, LIST and MLSD.
Interchangeably, you use a configuration which tells the server to use LIST, and another configuration which tells the server to used MLSD,
then the effect may be that a part of your local files will suddenly differ from the server by a few seconds.
Could this have happened?
Kind regards,
Karl
I don't think so. I have only uploaded files with T.C., and I have only 1 TC-definition for that server (and I uploaded with 'Preserve file dates').karlchen wrote:Hello, HeRo.
... ...
Now I guess you know what the potential pitfall can be:
FTP server ABCD can handle both, LIST and MLSD.
Interchangeably, you use a configuration which tells the server to use LIST, and another configuration which tells the server to used MLSD,
then the effect may be that a part of your local files will suddenly differ from the server by a few seconds.
Could this have happened?
Kind regards,
Karl
And my first problem was that T.C. > v.7.50 didn't work, because the server doesn't understand MLSD.
- HeRo
- ghisler(Author)
- Site Admin
- Posts: 48241
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
TC accepts a difference of up to 3 seconds as identical to work with FAT/FAT32 file systems which have an accuracy of 2 seconds. Due to rounding errors, there can be a difference of up to 3 seconds.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com