MEPX
Chapter 4 of 10All chapters

Chapter 4 of 10

Permissions

Who may read, write and execute.

Reading them

A listing such as rwxr-xr-- shows three groups of three: owner, group and everyone else, each with read, write and execute. On a directory, execute means the right to enter it.

  • chmod changes permissions and chown changes the owner.
  • The numeric form adds read 4, write 2 and execute 1, so 755 is rwxr-xr-x.

Root and sudo

sudo runs a single command with administrator rights and logs it. Staying as root all day removes the boundary that turns a bad command into a small mistake instead of a disaster.