At 8:19 pm, Thursday, November 1 2001, Jeff Waugh mumbled:
> I reckon someone should write a "What is chattr, and why is it cool?" email
> for the list. I won't, because I won't do it well enough. :)
>
chattr is used to change the extended attributes of an inode on a ext2
partition.
Okay, that's the stiff tech defition, here's what you can do with it.
You can set file attributes such as, don't update atime (Last time accessed)
synchronous updates
append only (Very useful if you keep using > instead of >>)
compressed - I'm not sure why this is here, as I haven't seen it used.
no dump - Can't use file with dump(8)
immutable - File is untouchable and unchangeable.
data journalling - For ext3, I think. It's unused in ext2 from memory.
secure deletion
undeletable
Why is chattr cool? Well, why isn't it? You can make sure you can't
accidently delete your *cough* special files, you can set +d (no dump) on a
file to see that dump won't back it up, and you can make files totally
impervious to rm(1).
slinky:~# chattr +iu slapd.conf
slinky:~# rm slapd.conf
rm: remove write-protected file `slapd.conf'? y
rm: cannot unlink `slapd.conf': Operation not permitted
slinky:~# lsattr slapd.conf
-u-i--------- slapd.conf
--
Steve
<doogie_> Subject: ->Have Bigger Breasts -- Men will Notice! (140949)
<doogie_> yeah, that's for me!
* Viiru wants to see a picture of doogie_ with bigger breasts.
PGP signature