Skip to content
EgyKode
01 · FoundationsLab 4 / 59
Guided labnetworking

Linux Networking & Troubleshooting

Work a connection failure from the outside in: DNS, route, port, firewall, application — and know which layer you are on.

Time
50 min
Level
Beginner
Objectives
4 objectives
Cost
Free

Where this fits in the platform

This lab adds

  • A method for following a connection to the layer that broke it

Before you start

You will need

  • Linux with `dig`, `ss`, `curl`, `ip`
  • sudo access

You do not need these already — the lab environment below provides them.

You will be able to

  • Resolve a name and read the TTL that explains a stale answer
  • Read a routing table and say where a packet would go
  • Prove whether a port is open, listening, or filtered
  • Work a failure in layers instead of guessing

CostFree

— no cloud resources

Nothing to pay in the browser. Open the terminal runs this against a simulated cloud — the same API calls and the same commands, with no account and no bill. The figure above applies only if you build it in your own.

The scenario#

An application cannot reach its database. The developer says "the network is down". It almost never is.

This lab builds the sequence that finds the real cause in under two minutes, instead of restarting things until something changes.

Hands-on environment

Run this lab in a real terminal, free and in your browser. The environment is temporary and yours alone — break it as much as you like.

Open the terminal

Opens in Killercoda, in a new tab — keep this page open for the steps.

Run it on your own machine

Run this lab on your own machine. One command starts the environment, with everything the lab needs already installed:

You will need:

  • bash
  • curl
git clone https://github.com/EgyKode/EgyKode-lab.git
cd EgyKode-lab
./egykode start
./egykode shell

You need Docker and Git installed. Everything else runs inside the environment. The first start downloads it and takes a few minutes; later starts are seconds.

Not sure what you already have? Run: npm run doctor — it checks and changes nothing.

Anything you tick here is your own record. EgyKode cannot see inside that terminal, so the success criteria stay self-assessed even when the environment checks your work for you.

Does the name resolve?

Step 1 of 4

The order matters#

Work outside-in. Each step rules out a layer, so you never guess:

text
name resolves?  ->  route exists?  ->  port open?  ->  app answers?
   dig               ip route           ss / curl       logs

Success criteria

0 of 4

The concept behind it

Ready to try it without help?Do the challenge

Next up

Lab 4 of 59 on the project path

Bash Automation: A Script You Can TrustWrite a backup script that fails loudly instead of silently, and schedule it so a missed run does not go unnoticed.40 minBeginner

Previous: Linux Security & SSH Hardening