retitle 784555 attr: getfattr -d -m - file does not report set file attributes thanks
TL;DR: when some attributes are associated, getfattr -d -m - sometimes gives empty output. So it's a bit more confusing as initially reported. Tested on an xfs filesystem, attr version 1:2.4.48-4 on Debian GNU/Linux 10 (buster) x86_64. Details: On the system, ls -ld /srv/www/vhost-1 gives drwxrwxr-x+ 17 root laravel 4096 Oct 8 10:25 /srv/www/vhost-1/ . root@host:/srv/www# getfattr -d -m - vhost-1 # file: vhost-1 system.posix_acl_access=0sAgAAAAEABwD/////AgAHADqVCQAEAAQA/////wgABwArAgAAEAAHAP////8gAAUA/////w== trusted.SGI_ACL_FILE=0sAAAABgAAAAH/////AAcAAAAAAAIACZU6AAcAAAAAAAT/////AAQAAAAAAAgAAAIrAAcAAAAAABD/////AAcAAAAAACD/////AAUAAA== root@host:/srv/www# setfattr --remove=trusted.SGI_ACL_FILE vhost-1 root@host:/srv/www# getfattr -d -m - vhost-1 root@host:/srv/www# I'd expect to see: system.posix_acl_access=0sAgAAAAEABwD/////AgAHADqVCQAEAAQA/////wgABwArAgAAEAAHAP////8gAAUA/////w== Since that isn't shown, I assume no extended attributes are associated with the file. However: laravel@host:/$ strace /bin/sh -c "cd /srv/www/vhost-1; cd /" chdir("/srv/www/vhost-1") = -1 EACCES (Permission denied) Running explicitly: root@host:~# setfattr --remove=system.posix_acl_access /srv/www/vhost-1 fixes it, as can be seen by e.g. 'ls': root@host:~# ls -ld /srv/www/vhost-1 drwxrwxr-x 17 root laravel 4096 Oct 8 10:25 /srv/www/vhost-1/ No more extended attributes are associated with the file. I've found only 'ls -l' reliably reports wether any extended attributes are associated (by listing a trailing '+' in the permission report). HTH, Bye, Joost -- Joost van Baal-Ilić http://abramowitz.uvt.nl/ Tilburg University mailto:joostvb.uvt.nl The Netherlands