The file and folder are owned by root but I did sudo chmod ugo+rw
on both, which I confirmed with ls -l
.
Still, I cannot remove the file as normal user.
❯ ls -ld /tmp /tmp/perm
drwxrwxrwt 46 root root 1160 Jan 9 17:41 /tmp
-rw-rw-rw- 1 root root 3 Jan 9 17:40 /tmp/perm
❯ rm /tmp/perm
rm: cannot remove '/tmp/perm': Operation not permitted
No attr and no ACL configured:
❯ lsattr -d /tmp
---------------------- /tmp
❯ getfacl /tmp
getfacl: Removing leading '/' from absolute path names
# file: tmp
# owner: root
# group: root
# flags: --t
user::rwx
group::rwx
other::rwx
Doing the same within subfolders works.
/tmp
is part of an ext4 system mounted at /
running under Arch Linux.
/tmp
.