After rebuilding coreutils against glibc 2.35 we now have an issue where
# cp -a this-is-a-symlink-file dst fails with the error cp: failed to preserve ownership for this-is-a-symlink-file: Operation not supported
This is causing a bunch of issues in our tooling due to exit code 1 from cp.
Here is a successful strace from coreutils rel25: P27
Here is the failing strace from coreutils rel26: P28
In the failed strace we notice that
utimensat(AT_FDCWD, "./libz.so", [{tv_sec=1649628485, tv_nsec=721821996} /* 2022-04-10T23:08:05.721821996+0100 */, {tv_sec=1649250247, tv_nsec=338613658} /* 2022-04-06T14:04:07.338613658+0100 */], AT_SYMLINK_NOFOLLOW) = 0
llistxattr("/usr/lib64/libz.so", NULL, 0) = 0
llistxattr("/usr/lib64/libz.so", 0x7ffcba1b2140, 0) = 0No longer happens.
Build log coreutils 25: https://build.getsol.us//logs/coreutils-8.32-25.log.gz
Build log coreutils 26: https://build.getsol.us//logs/coreutils-8.32-26.log.gz
In the build log for coreutils 26 we notice that the preserve-slink-time test is failing whereas it wasn't failing before.
This is the where the error is coming from in the coreutils source:
https://github.com/coreutils/coreutils/blob/master/src/cp.c#L311
Things tried so far
Updating coreutils to 9.0
Updating acl and attr to latest versions and rebuild coreutils against them
Building coreutils with clang