rsync icon indicating copy to clipboard operation
rsync copied to clipboard

Rsync fails when timestamp is 2106-02-07 06:28:15 UTC

Open martinwguy opened this issue 11 months ago • 0 comments

My historic archives have some files created on 80286 MSDOS floppies whose datestamp is 2106-02-07 06:28:15 on which rsync fails saying: rsync: [generator] readlink_stat("/mnt/sdb2/martin/archivi/walters/gs/readme") failed: Value too large for defined data type (75)

The stat() system call fails with the same perror() message, though both the "stat" command and "ls -l " succeed in printing the time. The statx() system call succeeds on the file reporting stx_mtime.tv_sec as 4294967295 and stx_mtime.tv_usec as 0.

In fact, rsync is using stat() (or stat64()) so my suggestion is to check for and prefer statx() if it is available, assuming that the rsync protocol (of which I am ignorant) is not limited in the same way. I'd prepare a patch but someone who knows the codebase and protocol and is more proficient in autoconf is likely to make a better job of it than me.

This is on Debian stable (bookworm i386 with Linux kernel 6.1.0-15-amd64) rsync is version 3.2.7 protocol version 31 The filesytem is reiserfs3

martinwguy avatar Mar 03 '24 15:03 martinwguy