recently we had to transfer some files between our servers(both ubuntu server 18.04). apparently the person who did this, didn't use the -a option of rsync(to preserve ownership information). So now, those files in the new server are owned by nobody:nogroup.

Well, I thought this was no problem, I just had to use chown. But sudo chown -R $USER:$USER <directory> just gives operation not permitted. This is already weird, but I logged in as root using sudo -i and tried to chang the ownership and the result was the same.

I googled the problem and people were talking about the directory being immutable. But lsattr -d <directory> returns ------------------ which means the directory is not immutable. But looking at ls -ld <directory> shows that only the owner(nobody:nogroup) has write access. So I try sudo chmod -R 666 <directory> but I get operation not permitted again.

At this point I just wanted to get it over with, so I edited /etc/passwd so that I can login using nobody. But even as nobody I got operation not permitted.

So now I have this huge space taken by these files that I can't delete but I also can't use in production.

Any suggestions? thanks

  • sudo -s then try again. – nobody Oct 26 '19 at 9:46
  • operation not permitted – massivefermion Oct 26 '19 at 10:04
  • How is the filesystem on which the directory resides mounted? what is the output of findmnt -T <directory>? – steeldriver Oct 26 '19 at 13:44
  • / rpool/subvol-6883-disk-0 zfs rw,noatime,xattr,posixacl – massivefermion Oct 26 '19 at 17:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.