How to keep directory Date when using rsync sync in Windows?

What is the problem you are having with rclone?

I am trying to use rclone to sync file from a small SSD to a large SSD.

Run the command 'rclone version' and share the full output of the command.

rclone v1.63.1

  • os/version: Microsoft Windows 10 Enterprise LTSC 2021 21H2 (64 bit)
  • os/kernel: 10.0.19044.3208 (x86_64)
  • os/type: windows
  • os/arch: amd64
  • go/version: go1.20.6
  • go/linking: static
  • go/tags: cmount

Which cloud storage system are you using? (eg Google Drive)

Windows File System (NTFS)

The command you were trying to run (eg rclone copy /tmp remote:tmp)

rclone sync R:\ E:\ -P --exclude "/System Volume Information/**" --exclude "/$RECYCLE.BIN/**" --exclude "/Config.Msi/**"

The rclone config contents with secrets removed.

I am not using config
2023/08/04 03:31:05 NOTICE: Config file "C:\\Users\\xxx\\AppData\\Roaming\\rclone\\rclone.conf" not found - using defaults

A log from the command with the -vv flag

Paste  log here

Do not use rclone for this. I am not sure what is the best tool on Windows but look for rsync for windows.

Rclone is not the best tool for everything.

on windows:
fastcopy: uses checksums to verify file transfers. command line + gui. rock stable
robocopy, many, many flags, can do most anything, but cannot verify file transfers.

edit: fastcopy is a portable app same as rclone. tho there is an installer

edit2: rclone is just fine for local to local, but it is very limited, have close to no concept of directories.

1 Like

Also you can try Total Commander - it has sync folders option.

Using rclone for your task is mistake.

rsync do not exist on Windows command, the nearest way I guess should be doing rsync in git bash...

you can also install WSL and then you will have many other options - fascinating way to learn something new.

I don't like the WSL design. The fastest method might be using a Live ubuntu and simple do rsync.

However, the compatibility of using NTFS in Linux is a concern.

rclone was designed with cloud in mind - and lacks nitty gritty details to work perfectly on local to local. In theory it could be fixed but I think it is much better to focus on cloud than trying to do something other tools do much better

yeah, that built-in compatibility layer is very complex.
tho, wsl is great and should consider it.
to avoid the compatibility issue, use smb/samba for the file copying.

about six years ago, i moved on to double commander.
--- open source
--- runs on windows and linux. huge bonus for me
--- built-in scripting via lua

double commander has that, tho never have used it.

fwiw, now, combine double commander and fastcopy. also, total commander works fine.

  1. use double commander to select the source and dest
  2. feed that to fastcopy. use fastcopy for the actual copy.

edit: as for command line usage, this is what i mostly use from script
fastcopy.exe /cmd=sync /verify /no_ui /filelog="${FCLogLFN}" "${SourceDir}\*" /to="${DestDir}\files\backup"
if you want a dry run mode, add /error_stop /no_exec


Always learning something new on this forum:) As usual there is no one best path.

I just tried rsync on Git Bash following this guide

First, download the latest zstd from facebook GitHub

Second, download the latest package from MSYS2

In my case, I downloaded

Third, follow the guide to extract the .zst file.

Then, you can use 7-zip to open the .tar file and copy the required .exe and .dll to C:\Program Files\Git\usr\bin\

After that, you should able to use rsync in Windows Git Bash.

Remind to add -N option to preserve the creation time.

rsync -avN --exclude "*System Volume Information*" --exclude "*$RECYCLE.BIN*" --exclude "*Config.Msi*" /r/ /e/
This command do the job, and change the directory creation time automatically if it already exists. So I don't need to delete the destination data before running the command.

I will try robocopy solution later.

1 Like

Thank you, asdffdsa.

I just download fastcopy, install fastcopy use default option but it shows error.

FindFirstFileEx(The filename, directory name, or volume label syntax is incorrect.123) : C:\Users\xxx\FastCopy\‪C:\Users\xxx\Desktop\test1

I remove the install, use extract in the installer to get the software without installation and it works.

After the test, I think rsync is a better option. It is an open source software and it works in both Windows + MSYS2, Linux and BSD. fastcopy/robocopy is now a closed source software and require license to get some features.

good to hear.

interesting, as i think just the opposite.
I took a read of the links you shared.
imho, way too many parts, from too many locations, too much of a kludge/hack.
cannot trust a hack based on a single weblink from 2 1/2 years ago.

for backups, i choose the best tool, stable, well tested software optimized for the host platform.
open-source is low on that scale.

yeah, that is a bummer, but so far, i have not needed the new features.

At first, I think it is a hack too.

After doing a search on Google, I finally understand that the rsync on Windows platform is based on MSYS2, which is a fork of cygwin. The Git for Windows include the minimal MSYS2, so it is not a hack. I just download the missing package to Git's MSYS2. Also, both Git for Windows and MSYS2 are keep updating.

To make it simple, you can just install MSYS2, do pacman -S rysnc in MSYS2 shell (e.g. UCRT64) to install rsync. Then you will have the great sync tool in Windows. It may also help you to backup file to Unix-based NAS over SSH.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.