Time stamps using PUT or SYNCHRONIZE commands

Advertisement

XRoss
Joined:
Posts:
5

Time stamps using PUT or SYNCHRONIZE commands

Hi,
At the moment I can copy files from a windows server to my local windows server and the time is keep correct using WinSCP. I use the “get” command, and I use the preserve time parameter. This is working correctly as I expect.
The next problem is with the time stamps that are created when I attempt to copy the files from a local windows directory to another windows server. It does not matter whether I use the “put” or “synchronize” command with the preserve time parameter. All it does is create a file with today’s date. I have updated to the latest version of WinSCP and the latest version of putty however there has been no change to the result. I have also removed all the files before the commands have been entered, it will still fail with the time stamps. I have run it manually with “Synchronize time stamps”, it picks up the incorrect time on the remote windows server, but does not change the time stamp when it is ticked to update the time stamps.

Is there a way to fix this issue?

To replicate the problem.
“Get” a file from a windows remote server to a local windows server. Works as I expect with the correct time stamps.
Use either “Put” or “Synchronize” with the preserve time parameter. It fails with today’s time stamps.

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,468
Location:
Prague, Czechia

Re: Time stamps using PUT or SYNCHRONIZE commands

Please attach a full session log file showing the problem (using the latest version of WinSCP).

To generate the session log file, use /log=C:\path\to\winscp.log command-line argument. Submit the log with your post as an attachment. 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 can mark the attachment as private.

Reply with quote

XRoss

Have you had any luck with the log file that I sent to you.
I did the log file using the manual method and set the log file to debug.
Many thanks.

Reply with quote

Advertisement

martin
Site Admin
martin avatar

Were you able to upload the files with correct timestamp using any SFTP client?

As you are using some rare SFTP server (SilverSHielD), I guess it's a server-side problem.

Reply with quote

XRoss
Joined:
Posts:
5

I have been unable to do an upload using "PSCP" to the server. I keep getting a network error, which is not surprising since it will only allow SSH commands.

I am surprised that I can download using the "GET" and keep the time stamps also using a SilverShield SSH server on the other end.

I have now worked around the problem.

Thanks

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
41,468
Location:
Prague, Czechia

XRoss wrote:

I have been unable to do an upload using "PSCP" to the server. I keep getting a network error, which is not surprising since it will only allow SSH commands.
If you can connect with WinSCP, you must be able to connect with PSCP too.

I am surprised that I can download using the "GET" and keep the time stamps also using a SilverShield SSH server on the other end.
Because the server does not seem to support updating timestamps of the remote files. It has nothing to do with updating local files, as theirs timestamps can be updated directly by WinSCP, as the are local.

I have now worked around the problem.
How?

Reply with quote

XRoss
Joined:
Posts:
5

I have now worked around the problem.

I now use the Windows PowerShell command line functions that is included in the server build. It keeps the date function correctly of each files within the folders.

Reply with quote

Advertisement

You can post new topics in this forum