3 ms·
What if it gets mounted just before you run chattr +i :) I agree setting the flag is the superior option.
by switch007 9y ago
What if it gets mounted just before you run chattr +i :)
I agree setting the flag is the superior option.
- xorcist 9y agoYou miss the point of making a directory immutable which doubles as a mountpoint. Mounting something just creates a new filsystem namespace over a path. It doesn't touch the existing directory. So you can safely leave the directory in question immutable, you never remove the flag, and it will only prevent writes to the directory when it is not overlaid by a mount.