I see that it is possible to act on a Minshall-French symlink to change the timestamp of its target: ------------------------------ mcrs3:/TCS # ls -lh test* -rwxr-xr-x 1 root root 0 Sep 1 00:13 testfile lrwxrwxrwx 1 root root 8 Sep 1 00:13 testlink -> testfile mcrs3:/TCS # mcrs3:/TCS # touch -t 01011200 testlink mcrs3:/TCS # mcrs3:/TCS # ls -lh test* -rwxr-xr-x 1 root root 0 Jan 1 2020 testfile # January expected --> ok lrwxrwxrwx 1 root root 8 Sep 1 00:13 testlink -> testfile ------------------------------ But the "-h" option of "touch" does not work to trigger a change to the timestamp of the mfsymlink itself. Neither the mfsymlink nor its target gets the specified timestamp: ------------------------------ mcrs3:/TCS # touch -h -t 02011200 testlink mcrs3:/TCS # mcrs3:/TCS # ls -lh test* -rwxr-xr-x 1 root root 0 Jan 1 2020 testfile lrwxrwxrwx 1 root root 8 Sep 1 00:13 testlink -> testfile # February expected --> not ok mcrs3:/TCS # ------------------------------ When I use the "-h" option against a regular file, it does get the specified timestamp: ------------------------------ mcrs3:/TCS # touch -h -t 02011200 testfile mcrs3:/TCS # mcrs3:/TCS # ls -lh test* -rwxr-xr-x 1 root root 0 Feb 1 2020 testfile # February expected --> ok lrwxrwxrwx 1 root root 8 Sep 1 00:13 testlink -> testfile mcrs3:/TCS # ------------------------------ Details of the mount, and versions: ------------------------------ mcrs3:/TCS # grep "TCS " /etc/fstab //mcrs3/TCS /TCS cifs user=cifsuser,multiuser,domain=VPTC3,sec=krb5,mfsymlinks,vers=3.0 0 0 mcrs3:/TCS # mcrs3:/TCS # mount.cifs --version mount.cifs version: 6.5 mcrs3:/TCS # mcrs3:/TCS # head -n 2 /etc/os-release NAME="SLES" VERSION="15" mcrs3:/TCS # ------------------------------ Minshall-French symlinks are not "standard" symlinks, so maybe it's to be expected that standard linux utilities cannot manage them properly, but perhaps it is possible for Samba to address this.
moving this to the cifsvfs product because the Minshall-French symlink are a client-only thing.
David Howells spotted the problem - cifs.ko is missing setattr in the cifs_symlink_inode_operations
This change fixes it: diff --git a/fs/smb/client/cifsfs.c b/fs/smb/client/cifsfs.c index 22869cda1356..ea3a7a668b45 100644 --- a/fs/smb/client/cifsfs.c +++ b/fs/smb/client/cifsfs.c @@ -1191,6 +1191,7 @@ const char *cifs_get_link(struct dentry *dentry, struct inode *inode, const struct inode_operations cifs_symlink_inode_ops = { .get_link = cifs_get_link, + .setattr = cifs_setattr, .permission = cifs_permission, .listxattr = cifs_listxattr, };