Lesson 21 — Linux Troubleshooting Capstone Lab

Lesson 21 • Linux Capstone

Linux Troubleshooting Capstone Lab

This capstone pulls together the skills you have been building: checking service status, reading logs, confirming network settings, validating permissions, and documenting your work like a real support tech.

systemctl journalctl ip / ping chmod / chown ticket notes
Difficulty Capstone / intermediate beginner
Estimated Time 20–30 minutes
Focus Structured troubleshooting

What this lab is training

  • Do not guess. Check the system first.
  • Use command output to narrow the problem.
  • Separate symptoms from root cause.
  • Make a clean fix, then verify the result.
  • Write a short ticket update that proves what you did.

Capstone mindset

A weak troubleshooter jumps to random fixes. A strong troubleshooter follows a sequence: observe → check status → read logs / test → identify cause → fix → verify → document.

That sequence is what employers trust.

Simulated Ticket Queue

You are the support tech on shift. Three Linux issues have come in.

Ticket 1 — Website Down
User says the internal test site stopped loading after a reboot.
Ticket 2 — No Network Reachability
User says the server is up, but cannot reach the gateway or external hosts.
Ticket 3 — Script Fails with “Permission denied”
User says the backup script exists, but will not run.
Scenario 1 • Services + Logs

Website Down — Service Fails to Start

User report: “The internal web page won’t load after the reboot.”

sudo systemctl start nginx Job for nginx.service failed because the control process exited with error code.

Break

The service does not start successfully.

systemctl status nginx Active: failed (Result: exit-code)

Diagnose

Read status first, then read the service logs.

journalctl -u nginx -n 20 nginx[812]: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)

This tells you the web service is failing because another process is already using port 80.

Fix

Find the conflict, stop it, and verify nginx starts.

sudo lsof -i :80 sudo systemctl stop apache2 sudo systemctl start nginx sudo systemctl status nginx

Root cause: another service was already bound to port 80.

Scenario 2 • Network Checks

No Network — Adapter / IP / Gateway

User report: “The server is on, but it can’t reach anything.”

ping -c 2 8.8.8.8 connect: Network is unreachable

Break

The machine has no usable network route.

ip addr 2: ens33: <BROADCAST,MULTICAST,UP,LOWER_UP> inet 192.168.1.50/24

Diagnose

The interface has an IP, so now check the route and gateway path.

ip route 192.168.1.0/24 dev ens33 proto kernel scope link src 192.168.1.50

There is no default gateway route listed, so traffic to outside networks has nowhere to go.

Fix

Add or restore the correct default route, then test again.

sudo ip route add default via 192.168.1.1 ping -c 2 192.168.1.1 ping -c 2 8.8.8.8

Root cause: missing default gateway route.

Scenario 3 • Permissions

Backup Script Won’t Run — Permission Denied

User report: “The backup script is there, but it won’t execute.”

./backup.sh bash: ./backup.sh: Permission denied

Break

The file exists, but execution fails immediately.

ls -l backup.sh -rw-r–r– 1 student student 842 Mar 20 09:12 backup.sh

Diagnose

Check the permission bits before changing anything.

The file is readable, but not executable. There is no x bit in the permission string.

Fix

Add execute permission, then run the script again.

chmod +x backup.sh ./backup.sh

Root cause: the script did not have execute permission.

Command-to-Problem Map

Command What it helps you check Why it matters
systemctl status <service> Current service state Shows whether the service is running, failed, or disabled.
journalctl -u <service> Service-specific logs Logs usually expose the actual cause, not just the symptom.
ip addr Interface state and IP address Confirms whether the adapter is up and whether it has an address.
ip route Routing table Tells you whether the system knows where to send traffic off-network.
ls -l Permissions and ownership Fast way to spot missing execute bits or wrong ownership.

Ticket Note Practice

Write a short support note as if you completed all three issues during a shift handoff.

Gold-standard note:

Investigated three Linux support issues. For the web service outage, used systemctl status nginx and journalctl -u nginx to identify a port 80 conflict with another service; stopped the conflicting service and verified nginx started successfully. For the network issue, confirmed interface IP with ip addr and identified a missing default route using ip route; restored the gateway route and verified connectivity with ping. For the backup script failure, used ls -l to confirm missing execute permissions, applied chmod +x, and verified successful execution.

Micro-Quiz

Score at least 75% to unlock the next lesson.

1) Which command is the best first check when a Linux service will not start?

2) What is journalctl -u nginx mainly used for?

3) A server has an IP address, but cannot reach outside networks. Which command helps reveal a missing default gateway?

4) If a script exists but returns “Permission denied” when you run it, what is the most likely issue?

5) What is the strongest troubleshooting habit in this lesson?

Lesson complete saved. Nice work.
You need 75% or higher to unlock the next lesson.

Next Lesson

Advance once you pass the quiz or mark the lesson complete.

Next: Linux Help Desk Review Lab

Leave a Comment