Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Unix Permissions

Status
Not open for further replies.

felix001

Technical User
Nov 15, 2008
102
GB
Im just trying to build a better understanding of UNIX permissions but one thing confuses me...

When i have the permissions of 555 on a text file i can still edit the file in VI using the :wq! command. But this seems odd as root doesnt have write permissions to the file ???
 
Root has all permissions on all files. It makes sense because if root is not the owner or belong to the group assigned to the file's ownership, then he would be 'other' and regular users could lock him out of their files and directories.

 
you may look at the "immovable" bit to prevent root from accidentally overwriting a file.

But still you can't prevent root from accessing and modifying its permissions and attributes.

man chattr
man lsattr


QatQat



If I could have sex each time I reboot my server, I would definitely prefer Windoz over Linux!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top