Linux Guides
Production Linux incidents rarely look like the textbook. High CPU with no obvious culprit, memory that grows without a clear leak, a systemd service that fails on start but works fine when you run the binary manually.
These guides are written for engineers already in an incident. They skip the basics and get to the diagnostic workflow: which tool to run first, what the output actually means, and what to change to fix it.
The focus is on tools you already have — strace, ss, lsof, top, ps, systemd journal — and how to use them effectively when something is wrong and you need an answer fast.
55 articles
How to Trace Route in Linux: traceroute Examples
Use traceroute in Linux to diagnose network path issues — read hop output, interpret timeouts, use TCP mode to bypass firewalls, and identify where packets are being dropped.
Too Many Open Files Linux: Fix Guide
Fix 'too many open files' errors on Linux — increase file descriptor limits for processes and system-wide, diagnose FD leaks, and configure permanent limits for production services.
How to Test TCP Connection in Linux: nc, curl, telnet
Test TCP connections in Linux using nc, curl, telnet, and /dev/tcp — verify port reachability, measure response time, and debug connection failures with real examples.
SSH Connection Refused Linux: Fix Guide
Fix SSH connection refused on Linux — diagnose why SSH won't connect, check sshd service and firewall, recover from lockout, and harden SSH without breaking access.
How to Search Text in Files Linux: grep Examples
Search text in files in Linux with grep — recursive search, regex patterns, context lines, count matches, and real-world log investigation examples.
How to Restart Network Service in Linux (All Distros)
Restart network service in Linux using systemctl, nmcli, and ip commands — covering Ubuntu, RHEL, Debian, and CentOS with real examples and what to do when restart fails.
Port Already in Use Linux: How to Find and Fix It
Fix 'port already in use' errors on Linux — find what process owns the port, kill it safely, handle TIME-WAIT sockets, and prevent the issue from recurring.
ping vs curl vs telnet: Which to Use for Network Testing
Know when to use ping, curl, and telnet for network testing — what each tool tests, what its limitations are, and which to reach for first when debugging connectivity issues.
Permission Denied Linux: Fix with chmod and chown
Fix 'permission denied' errors in Linux — read permission bits correctly, use chmod and chown safely, debug with ls -la and stat, and avoid common mistakes that break applications.
netstat vs ss: Which to Use and What's the Difference
netstat vs ss — understand the differences, when to use each, equivalent command translations, and why ss is the modern replacement for netstat on Linux.
How to Monitor Real-Time Logs in Linux: tail, journalctl, multitail
Monitor real-time logs in Linux using tail -f, journalctl -f, and multitail — follow multiple log files simultaneously, filter live output, and build production log monitoring workflows.
Linux tail Multiple Files: Real Examples and Techniques
tail multiple files in Linux simultaneously — using tail -f, multitail, and journalctl to monitor several log files at once in real production scenarios.
Linux sort Command: Real Usage Examples
Use the Linux sort command effectively — sort by column, numerically, by size, reverse order, deduplicate, and combine with other commands for real log and data analysis.
Linux Move Files Between Directories: mv and rsync Examples
Move files between directories in Linux using mv and rsync — handle cross-filesystem moves, rename files, move with wildcards, and avoid common mistakes.
Linux Kill Process by Port: Step-by-Step Guide
Kill a process by port number on Linux — using fuser, lsof, ss + kill, and pkill. Step-by-step with real examples for each method.
How to Find Process by Name in Linux: pgrep, ps, pidof
Find a Linux process by name using pgrep, ps, pidof, and top — with real examples for scripting, killing, and monitoring processes in production.
Linux Find Files Older Than X Days: find -mtime Examples
Find files older than X days in Linux using find -mtime — with real examples for log cleanup, archiving old files, and safe deletion workflows.
Linux Find File by Name and Size: Real Examples
Use Linux find command to locate files by name pattern, size, date, and permissions — with real production examples and combined search techniques.
Linux Check Open Connections: ss, netstat, lsof Examples
Check open network connections in Linux using ss, netstat, and lsof — see established connections, connection counts by state, and find which process owns each connection.
Linux Check Memory Usage: free vs top Explained
Check memory usage in Linux using free, top, and /proc/meminfo — understand available vs free, detect memory pressure, and identify memory-hungry processes.
Linux Check Listening Ports with ss: Complete Guide
Check listening ports in Linux with ss — see TCP and UDP listeners, find which process owns each port, filter by interface binding, and detect unexpected services.
Linux Check Last Login Users: last, lastlog, who
Check last login history in Linux using last, lastlog, and who — find recent logins, failed attempts, and suspicious access patterns for security audits.
Linux Check File Size: ls, du, stat Command Examples
Check file size in Linux using ls -lh, du, and stat — understand apparent size vs disk usage, find files by size, and script size checks with real examples.
Linux Check Disk Usage by Folder: du Command Guide
Check disk usage by folder in Linux with du — sort directories by size, drill down to find what's consuming space, and use ncdu for interactive exploration.
Linux Check Disk I/O Usage: iostat Examples
Check disk I/O usage in Linux using iostat — read utilization, throughput, and latency metrics, identify saturated disks, and correlate I/O with application slowdowns.
How to Extract tar.gz in Linux: All Formats Covered
Extract tar.gz files in Linux — handle .tar.gz, .tar.bz2, .tar.xz, and .zip formats, extract to specific directories, and handle common extraction errors.
How to Delete Large Files in Linux Safely
Delete large files in Linux safely — handle open file handles, free disk space immediately with truncate, use rm correctly, and recover from accidental deletion.
How to Copy Files Recursively in Linux: cp, rsync Examples
Copy files recursively in Linux with cp and rsync — preserve permissions, sync directories, copy over SSH, and handle large transfers efficiently.
How to Check Uptime in Linux: uptime, w, and Beyond
Check Linux server uptime with uptime, w, and /proc/uptime — read load average correctly, find when the last reboot happened, and script uptime checks.
How to Check DNS Server in Linux: dig, nslookup, resolvectl
Check which DNS server Linux is using with resolvectl, dig, and cat /etc/resolv.conf — verify DNS resolution, test specific servers, and debug DNS configuration.
How to Find Large Files in Linux: Practical Guide
Find large files in Linux using find, du, and ncdu — with real command examples for disk cleanup, log hunting, and storage audits on production servers.
DNS Not Resolving in Linux: Fix Guide
Fix DNS not resolving in Linux — diagnose with dig and nslookup, check resolv.conf and systemd-resolved, and fix DNS for containers, VMs, and production servers.
Disk Full Linux: How to Clean Up and Free Space Fast
Fix a full disk on Linux fast — find what's taking space with df and du, clean logs, Docker, package caches, and deleted-but-open files in production.
How to Compress Files in Linux: tar Examples
Compress files in Linux with tar — create .tar.gz and .tar.bz2 archives, choose the right compression level, and handle common tar use cases with real examples.
How to Check Open Ports in Linux: ss vs netstat
Check open ports in Linux using ss and netstat — with real command examples, output explanation, and when to use each tool in production troubleshooting.
How to Check Network Interface in Linux: ip, ifconfig, ethtool
Check network interfaces in Linux with ip link, ip addr, and ethtool — see IP addresses, interface state, link speed, and diagnose interface-level network problems.
How to Check Listening Ports in Linux (2026 Guide)
Check listening ports in Linux with ss, netstat, lsof, and nmap — know which service owns each port, detect unexpected listeners, and troubleshoot connection refused errors.
Check Disk Usage in Linux: du vs df Explained
Check disk usage in Linux using df and du — understand the difference, read the output correctly, and find what's filling your disk with real command examples.
How to Check CPU Usage in Linux: Real Command Examples
Check CPU usage in Linux using top, mpstat, ps, and vmstat — read per-core breakdown, identify CPU-hungry processes, and diagnose high load in production.
Cannot Connect to Server Linux: Step-by-Step Troubleshooting
Troubleshoot 'cannot connect to server' on Linux — diagnose connection refused, timeout, and network unreachable errors with a systematic step-by-step approach.
top Command Linux: Real-World Guide to CPU and Process Monitoring
Learn how to use the top command on Linux for production troubleshooting — reading CPU, load average, memory metrics, interpreting process states, and diagnosing high CPU and stuck processes in real incidents.
strace Tutorial: Debug Linux Processes Like a Senior Engineer
A practical strace tutorial for production debugging — trace system calls, diagnose hung processes, find missing files, and debug permission errors with real command examples and incident workflows.
ps Command Linux: The Engineer's Troubleshooting Guide
How to use the ps command on Linux to debug high CPU, memory leaks, zombie processes, and unresponsive services — with real production workflows, common mistakes, and a quick-reference cheat sheet.
Linux Process States Explained: R, S, D, Z and What They Mean for Troubleshooting
A practical guide to Linux process states — R, S, D, Z, T — what each means, how to read them in ps and top, why D state can freeze a system, and how to handle zombie processes in production.
Linux Performance Troubleshooting: Complete Engineer's Guide
The complete guide to Linux performance troubleshooting — CPU, memory, disk I/O, process states, and network — with step-by-step workflows, real production scenarios, and links to deep-dive articles on every topic.
Linux Memory Leak Troubleshooting: RSS vs VSZ Explained
How to troubleshoot memory leaks on Linux — understanding RSS vs VSZ, tracking memory growth over time, identifying the leaking process, and real debugging steps from production systems.
Linux Log Analysis: How to Debug Issues Like a Senior Engineer
A practical Linux log analysis guide — journalctl usage, grep techniques, log correlation across services, and real-world debugging workflows used in production incident response.
Linux High CPU Usage: Step-by-Step Troubleshooting Guide
Step-by-step guide to diagnosing Linux high CPU usage — using ps, top, and htop to identify the culprit, distinguish user vs kernel vs I/O wait CPU, and resolve the issue in production.
Top Linux Debugging Tools Every Engineer Should Know
The essential Linux debugging tools for production troubleshooting — ps, top, htop, lsof, strace, iotop, vmstat, dmesg, and more — with real use cases and a comparison table.
htop vs top: Which Should You Use in Production?
htop vs top — a practical comparison for Linux engineers. When to use each, key differences in UI and usability, performance overhead, and real production scenarios where one beats the other.
How to Check Running Processes in Linux: Complete Guide
How to check running processes in Linux using ps, top, and htop — with filtering techniques, real troubleshooting workflows, and common mistakes engineers make when investigating process issues.
Check Open Ports in Linux: ss vs netstat Explained
How to check open ports in Linux using ss and netstat — with real troubleshooting scenarios, filtering techniques, and a clear comparison of when to use each tool.
Linux TIME_WAIT Explained: Why It Causes Connection Failures and How to Fix It
Linux TIME_WAIT exhausts ephemeral ports and causes ECONNREFUSED under load — even when your app is healthy. Learn what TIME_WAIT is, how to detect port exhaustion with ss and netstat, and the exact sysctl fixes that resolve it.
Reading Logs Like a Detective: A Field Guide to Incident Triage
The exact commands and mental models I use to go from 'something is wrong' to 'I know exactly what happened' in under 15 minutes.
strace, lsof, and ss: The Trio That Solves Every Mystery
When logs give you nothing and the debugger isn't an option, these three tools let you see exactly what a running process is doing at the system call level.