Mission 14

Editing config notes

Copy a system config into your lab, edit it safely, and compare the result.

Nano and editing
10 minutes Beginner Lesson 14 of 360
cpnanogrepcat
Lesson 14 of 360 0/360 lessons 0/17 missions Nano and editing · 10 minutes
0%
Continue View profile
Ops lab terminal Training lab
New learnerrank 0XP 0%complete
learner@clairos:/home/learner $ Unix ops lab: type a command, press Enter
Instructions 10 minutes

Click any instruction for the command details, the why, and the common mistake to avoid.

Copy config

Run mkdir lab, then cp /etc/nginx/sites-available/learn.conf lab/learn.conf.

mkdir labcp /etc/nginx/sites-available/learn.conf lab/learn.conf
Edit the copy

Run nano lab/learn.conf.

nano lab/learn.conf
Verify text

Run grep server_name lab/learn.conf.

grep server_name lab/learn.conf
Lesson support

What to notice while you play.

Objective

Practice editing a copy instead of touching protected system config.

Hint

Copy /etc/nginx/sites-available/learn.conf into lab first.

Why it matters

Change control starts with preserving the original.

Common mistakes
  • Editing production config first.
  • Skipping verification after a config edit.
Reference

Commands in this lesson.

nano <file>

Open a simulated nano editor.

cat <file>

Print text file contents.

grep [-i] <text> <file>

Find literal text inside a file.

cp <src> <dst>

Copy a file.