Page 1 of 1

Make files undeletable with chattr

Posted: Mon 14 Nov 2005, 17:53
by Lobster
Here is a cool tip on how you can make files on your system immutable. By immutable, I mean even root can't delete the files if he choose to. Linux ships with a tool called chattr which can be used for the purpose. 'chattr' is similar to the 'attrib' DOS equivalent tool but much more powerful and flexible.
To make your file (test_file) immutable

# chattr +i test_file

Full info
http://tinyurl.com/9mkzk

Thanks.

Posted: Tue 15 Nov 2005, 10:48
by brad_chuck
Cool.. This could be usefull some day.

chattr +i brad's_10_page_paper.txt

Posted: Tue 15 Nov 2005, 22:57
by Pizzasgood
Lobster-proof system:
chattr +i -R /*
(assuming it has the -R recursive option)

Just kidding. I haven't heard of you crashing and burning in months. You must have learned to waddle over ice like a true penguin-puppy-lobster hybrid :wink: