Mission 328

Nano config-copy edit

Edit a disposable config copy and compare it with the original.

Nano and editing
8 minutes Admin Lesson 328 of 360
cpnanodiff
Lesson 328 of 360 0/360 lessons 0/17 missions Nano and editing · 8 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 8 minutes

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

Create a config copy

Run cp data/config-a.conf lab/learn-copy.conf.

cp data/config-a.conf lab/learn-copy.conf
Edit the copied port

Run nano lab/learn-copy.conf. Replace listen 443 ssl; with listen 8443 ssl; and save with Ctrl+O.

nano lab/learn-copy.conf
Verify the changed port

Run grep 8443 lab/learn-copy.conf.

grep 8443 lab/learn-copy.conf
Review the exact change

Run diff data/config-a.conf lab/learn-copy.conf.

diff data/config-a.conf lab/learn-copy.conf
Lesson support

What to notice while you play.

Objective

Build repeatable confidence with editing a copy instead of a live configuration.

Hint

Copy first, change only 443 to 8443 in nano, save with Ctrl+O, then compare.

Why it matters

Editing a copy instead of a live configuration helps operators explain what they know before they change anything.

Common mistakes
  • Skipping the output that proves editing a copy instead of a live configuration.
  • Changing several things before recording a baseline.
Reference

Commands in this lesson.

nano <file>

Open a simulated nano editor.

diff <left> <right>

Compare two lab text files.

cp <src> <dst>

Copy a file.