xattrs: Permission denied?

Wesley W. Terpstra wesley at terpstra.ca
Fri Nov 9 23:48:01 GMT 2007


Things are not quite so simple b/c linux->linux works!?

This fails on osx:
> kiwiw:~/foo terpstra$ uname -a
> Darwin kiwiw.lan 8.10.0 Darwin Kernel Version 8.10.0: Wed May 23  
> 16:50:59 PDT 2007; root:xnu-792.21.3~1/RELEASE_PPC Power Macintosh  
> powerpc
> kiwiw:~/foo terpstra$ mkdir y
> kiwiw:~/foo terpstra$ xattr --set broken "this is" y
> kiwiw:~/foo terpstra$ chmod 0555 y
> kiwiw:~/foo terpstra$ ~/src/rsync-3.0.0pre5/rsync -aX y z
> rsync: rsync_xal_set: lsetxattr("z","broken") failed: Permission  
> denied (13)
> rsync error: some files could not be transferred (code 23) at main.c 
> (1054) [sender=3.0.0pre5]

But works on linux:
> pumpkin:/c/debian/x# rmdir y z
> pumpkin:/c/debian/x# mkdir y
> pumpkin:/c/debian/x# setfattr -n user.broken -v "this is" y
> pumpkin:/c/debian/x# chmod 0555 y
> pumpkin:/c/debian/x# ../root/rsync-3.0.0pre5/rsync -aX y z

... and yet fails when going from osx->linux:
> kiwiw:~/foo terpstra$ ~/src/rsync-3.0.0pre5/rsync -aX y  
> pumpkin::staging/tmp/
> rsync: rsync_xal_set: lsetxattr("y","user.broken") failed:  
> Permission denied (13)
> rsync: rsync_xal_set: lsetxattr("y","user.com.apple.crtime96")  
> failed: Permission denied (13)
> rsync: rsync_xal_clear: lremovexattr("y","user.rsync.%stat")  
> failed: Permission denied (13)
> rsync error: some files could not be transferred (code 23) at main.c 
> (1054) [sender=3.0.0pre5]

... and also fails from linux->osx:
> pumpkin:/c/debian/x# ../root/rsync-3.0.0pre5/rsync --rsync-path / 
> usr/bin/rsync-3.0 -aX y terpstra at kiwiw:~/
> rsync: rsync_xal_set: lsetxattr("y","broken") failed: Permission  
> denied (13)
> rsync error: some files could not be transferred (code 23) at main.c 
> (1054) [sender=3.0.0pre5]

All cases work when the directory is 0755.



More information about the rsync mailing list