Skip to content

Operation not supported when copying symlinks from a BSD system #1147

Closed

Description

@ckujau

This looks a bit like #173 resurfacing, but this only happened today with the new v3.5.2 release:

freebsd-14$ cd /var/tmp && touch foo; ln -s foo bar; ln -s nop baz

Trying to copy this file via rsync to a Linux machine:

debian-13$ ./rsync --recursive --links --perms 192.168.178.130:/var/tmp/ /var/tmp/test/
rsync: [generator] failed to set permissions on "/var/tmp/test/bar": Operation not supported (95)
rsync: [generator] failed to set permissions on "/var/tmp/test/baz": Operation not supported (95)
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1987) [generator=3.5.2-ga6b31adf]

debian-13$ ls -lgo /var/tmp/test/{foo,bar,baz}
lrwxrwxrwx 1 3 Nov  4 16:18 /var/tmp/test/bar -> foo
lrwxrwxrwx 1 3 Nov  4 16:18 /var/tmp/test/baz -> nop
-rw-r----- 1 0 Nov  4 16:18 /var/tmp/test/foo

This only happens when --perms is set, and only happens when trying to rsync symbolic links from a FreeBSD 14 or macOS 27 system. The local machine is running Debian 13.

As v3.5.1 did not show this behaviour, I started a git bisect session that pointed to:

first bad commit: [750012c34fe54418ffccd87f640247f6aabbacd9]
(Add fchmodat() as an option to set symlink Unix access permissions (#1108)

With that commit reverted, the error message is gone. CC @mtsapv, just in case.

Activity

  1. steadytao commented on Nov 4, 2026

    @steadytao
    Member

    Ah yes. Thank you for reporting this and my apologies. Will prepare a patch and ensure that #1122 is complete for the next release which will catch cases like this better.

  2. mtsapv commented on Nov 4, 2026

    @mtsapv
    Contributor

    Interesting scenario. I'm looking at it "as we speak". Shouldn't take long to come up with an appropriate correction.

    Not sure how we can (automatically) test for this since it involves two separate systems of different architectures. I'll keep giving that some thought as well.

  3. steadytao commented on Nov 4, 2026

    @steadytao
    Member

    One example is that a Linux receiver test can supply a non-0777 symlink mode through a protocol fixture. Unsupported symlink chmod should return the existing skipped-operation result without hiding permission failures or touching the target.

  4. mtsapv commented on Nov 4, 2026

    @mtsapv
    Contributor

    OK. Thanks. Will look into that.

  5. steadytao commented on Nov 8, 2026

    @steadytao
    Member

    Reached out to package maintainers -- Confirmed merged into 3.5.2 for Arch + pkgsrc

  6. steadytao commented on Nov 9, 2026

    @steadytao
    Member

    PPAs updated. Build in ~10 minutes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions