2

I can move it but rmdir and rm -rf fail even as root (failed to remove '/home': Operation not permitted). lsattr is all ----------.

Whenever I mv /home /home.bakN I get directories that are also unremovable plus a recreated /home with the same restriction after I reboot ("single" mode). I can remove everything else, I can create new files and directories, not a read-only partition.

I used to use a /home partition but I disabled it (replaced /home with /media/home in /etc/fstab) and I can successfully use a /home directory. I just don't understand why I can't remove it (again: it's not busy and no application uses it and no /home user is logged in).

argle
  • 523
  • Is /home exported via NFS? Is /home an automount point for autofs? (http://man7.org/linux/man-pages/man5/autofs.5.html) – Andrew Henle Nov 04 '15 at 12:05
  • maybe inside /home there are some files/directory with a or i attribute? http://unix.stackexchange.com/questions/29902/unable-to-delete-file-even-when-running-as-root – LilloX Nov 04 '15 at 12:07
  • As I showed, /home is empty (I would have gotten a different error message for that). – argle Nov 04 '15 at 12:40

1 Answers1

3

It's a btrfs-specific issue: /home is a subvolume.

btrfs subvolume list -a /parent shows all subvolumes and btrfs subvolume delete dirname deletes them.

argle
  • 523