RU RU

Network Troubleshooting for Beginners: Is the Door Open? (Ports)

Published on September 15, 2025

Network Troubleshooting for Beginners: Is the Door Open? (Ports)

Introduction

A server’s IP address is like the postal address of an apartment building. But to reach the right apartment, you need the door number. In networking, these doors are ports.

  • HTTP runs on port 80.
  • HTTPS — on port 443.
  • Mail, databases, and other services listen on their own ports.

If a port is closed or nothing is listening on it, the site won’t open — even if the server is “alive.”

Today we’ll learn how to check port availability using telnet, nc, and also see what’s listening on your own computer with netstat and ss.


telnet — Classic Way to Check a Door

What does it do?

Creates a simple text connection to the specified port.

Usage

telnet <server_address> <port_number>

Example:

telnet google.com 443

Results

Success:

Trying 142.250.184.110...
Connected to google.com.
Escape character is '^]'.

Connection established → port is open.

Failure:

Connecting To google.com...Could not open connection to the host, on port 443: Connect failed
  • Connection refused — the door exists but it’s locked.
  • Connection timed out — nobody is answering (or a firewall is blocking it).

⚠️ On Windows, the Telnet client is disabled by default. Enable it in Control Panel → Programs and Features → Turn Windows features on or off.


nc (netcat) — The Swiss Army Knife 🔪

netcat is more convenient and faster than telnet, giving clear answers.

Usage

nc -zv <server_address> <port_number>

Flags:

  • -z — scan only, no data transfer.
  • -v — verbose output.

Examples

Success:

Connection to google.com port 443 [tcp/https] succeeded!

Failure:

nc: connect to google.com port 81 (tcp) failed: Connection refused

👉 Conclusion: nc -zv is the most convenient way to check ports.


What’s Listening on My Computer?

To see which ports are open locally:

netstat

netstat -an

Works on Windows, macOS, and Linux. Shows all active connections and ports in LISTEN / LISTENING status.

ss (Linux, modern alternative)

ss -tuln
  • t — TCP
  • u — UDP
  • l — listening ports only
  • n — show port numbers instead of service names

Example:

tcp    LISTEN  0  128  0.0.0.0:22   0.0.0.0:*

Here an SSH server is listening for connections on port 22.


Conclusion

Now you know how to:

  • Check port availability on a remote server (telnet, nc).
  • See which ports are listening on your computer (netstat, ss).

This helps distinguish between:

  • “Server is unreachable” and
  • “Server is reachable, but the specific service isn’t working.”

What’s Next?

We’ve looked at basic, narrow-purpose tools. But there are multipurpose tools that combine several functions and give a broader picture.

In the next article, we’ll explore mtr, nmap, and curl — true all-in-one diagnostic utilities.


Resources

Need help?

Get in touch with me and I'll help solve the problem

Related Posts