Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have been trying to sort out my backups, so that when files are restored the owners/groups and any other metadata are correctly restored. For my testing I have been backing up from a Ubuntu 9.10 server (with rsync version 3.0.6, protocol version 30 installed) via ssh, to either an OSX 10.6 laptop or Ubuntu 9.10 server.

Making the backup has been done using the following command (executed as root):

# rsync -avz --fake-super /var/www/myfolder

No errors are reported when doing this.

I then use the following to fetch back my test directory:

# rsync -avz --fake-super /tmp

And for every file it reports the error:

rsync: failed to write xattr user.rsync.%stat for "/tmp/myfolder/path/to/file": Operation not supported (95)

Originally I thought this must be because I was backing up to OSX, so I tried again backing up to a Ubuntu server - only to get the same error when restoring files. I have Googled and looked in the manpage for rsync, but found nothing of help.

My local Ubuntu server uses ext3, the remote Ubuntu server ext4, and the Mac has HFS

share|improve this question
up vote 7 down vote accepted

You are doing at least one thing wrong.

First of all you are using --fake-super on the wrong side of the connection. Let me quote the rsync man page.

The --fake-super option only affects the side where the option is used. To affect the remote side of a remote-shell connection, specify an rsync path:

rsync -av --rsync-path="rsync --fake-super" /src/ host:/dest/

What you are doing is running --fake-super on the side of the connection where you are already root anyway.

The part about "failed to write xattr user.rsync.%stat for" is because the file system used with --fake-super hasn't been mounted with the flag user_xattr. This mount option has to be in effect on the side of the connection where you are using --fake-super, which in your cause would be "".

To summarize, these are the commands you should have been running:

# rsync -avz --rsync-path="rsync --fake-super" /var/www/myfolder
# rsync -avz --rsync-path="rsync --fake-super" /tmp

...with the mount option user_xattr in effect on

share|improve this answer
Note that at least as of rsync 3.1.2 (but probably already earlier versions) there is a --remote-option parameter which might generally be preferable. There is also the shortcut "-M" for it. So instead of --rsync-path="rsync --fake-super" one could also have written -M--fake-super. – evotopid Apr 30 at 20:24
I can confirm that --remote-option aka -M is also in rsync 3.1.1. – Sparhawk May 25 at 6:26

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.