Practice Use drills for recall and labs for real operating judgment.

LAB-PERM-02 - UGO and the chmod Command

Use symbolic chmod safely to add or remove specific permissions in a practice folder without overwriting everything.

ACL Permission Management

UGO and the chmod Command

Use symbolic chmod safely to add or remove specific permissions in a practice folder without overwriting everything.

30 min BEGINNER LINUX Field-verified
Success criteria
  • Add or remove a specific permission using symbolic chmod.
  • Explain the difference between +, -, and = in chmod.
Safety notes
  • Practice only in a disposable folder so mistakes are easy to undo.

Part A: The Field Guide

Symbolic chmod is useful when you want to change one part of the permission state without replacing everything.

The structure is:

chmod [who][operator][what] file

Examples:

  • u+x add execute for the owner
  • g-w remove write from the group
  • o= remove all permissions for others

The main pieces

  • u owner
  • g group
  • o other
  • a all

Operators:

  • + add
  • - remove
  • = replace that target’s permissions exactly

Safe Default

When you only want to make a small change, prefer + or -. Use = when you truly mean to replace the full target state.


Part B: The Drill Deck

Terminal required: create a sandbox and keep all changes there.

G
Guided Step by step - type exactly this and compare the result
>

Exercise G1: Build the sandbox

Create a practice area

mkdir -p ~/perm_lab cd ~/perm_lab touch test.txt ls -l test.txt

Exercise G2: Add one permission

  1. Run chmod u+x test.txt
  2. Run ls -l test.txt
  3. Explain exactly what changed and who it affected

Exercise G3: Remove one permission

  1. Run chmod g-w test.txt
  2. Run ls -l test.txt
  3. Explain exactly what changed and who it affected

Exercise G4: Replace one target

  1. Run chmod o= test.txt
  2. Run ls -l test.txt
  3. Explain why o= is stronger than o-w
S
Solo Task described, hints available - figure it out
>

Exercise S1: Predict before running

Starting from -rw-r--r--, predict the result of each command:

  1. chmod u+x file.txt
  2. chmod g-w file.txt
  3. chmod o= file.txt

Then test your predictions in the sandbox.

Exercise S2: One-line reasoning

Write one sentence for each operator:

  • what + is for
  • what - is for
  • what = is for
M
Mission Real scenario - no hints, combine multiple skills
>

Mission M1: Secure one private file

In your sandbox:

  1. create a file called private.txt
  2. use symbolic chmod to give the owner read and write
  3. remove all permissions from group and other
  4. verify the final string with ls -l

If you can do that without defaulting to 777 or guessing, the symbolic model is working.