openzfsonosx / openzfs

OpenZFS on Linux and FreeBSD, and, macOS. This is where development for macOS happens.
https://github.com/openzfs/zfs/wiki
Other
144 stars 10 forks source link

Setting file modification times does not work #120

Closed EchterAgo closed 1 year ago

EchterAgo commented 1 year ago

When transferring files to ZFS using rclone sync I noticed that it keeps rechecking files and tries updating the modification time for ever yime each time you start the sync again. Investigating this I found that the modification time is not actually updated. I managed to also reproduce this using the touch command in an MSYS2 shell.

When diagnosing this with Process Monitor I saw this:

image

This seems to point to set_file_basic_information returning 0x84 (EOVERFLOW), which seems to come from the TIMESPEC_OVERFLOW check in zfs_setattr.

I found https://github.com/openzfsonosx/openzfs/issues/104#issuecomment-984326098 which indicates that the check is a "relic" but it still exists in the current release.

Any ideas, am I doing something wrong? The pool was created using zpool create -o ashift=12 -O atime=off -O compression=lz4 -O recordsize=1MB -O casesensitivity=insensitive Data raidz1 PHYSICALDRIVE5 PHYSICALDRIVE6 PHYSICALDRIVE7 PHYSICALDRIVE8 cache PHYSICALDRIVE1 PHYSICALDRIVE3 (also tried with atime=on)

I'll try removing the checks and compiling the module, but I need to get the development environment set up first, but I hope to have more info soon.

EchterAgo commented 1 year ago

Sorry, wrong repository.