chattr is known as one of the permission util to set additional attributes to file.This util even can create a magic by setting a file as an immutable which root can delete the file if he wish to.
First of all, the common commands in using chattrs are + and -
chattr +i ( to set the attribute)
chattr -i ( to unset the attribute)
For example :
chattr +i test.odt ( To set the immutable permission )
chattr -i test.odt ( To unset the immutable permission )
A normal ls -l will not show the attributes that chattr sets.
So we use lsattr to see them.
To know more about other available attributes, check it here
Subscribe to:
Post Comments (Atom)
Home

0 comments:
Post a Comment