grep -rl "networking" ./blog

Linux Networking

Addresses, DNS, ports, and connections. How Linux networking is configured and inspected, plus the tools for diagnosing why something cannot reach something else.

39 articles

CrowdSec vs Fail2ban: Blocking Attackers on Linux Servers Fail2ban bans IPs that fail too often in your logs. CrowdSec does the same and shares signals with every other CrowdSec user. How each works, setup for SSH, the bouncer model, privacy trade-offs, and which to run. Docker Volumes, Bind Mounts, and Networks Explained Where container data should live and how containers talk to each other. Named volumes vs bind mounts vs tmpfs, permissions and SELinux labels, backing up volumes, user-defined bridge networks and DNS, publishing ports safely, and the firewall surprise. The nmap Command Explained: Scanning Your Own Network the Right Way How to use nmap to discover devices on your network, find open ports, identify services and versions, and read the results, with the scan types that matter and the legal line you should not cross. The ip Command Explained: Addresses, Routes, Links, and Neighbours ip replaced ifconfig, route, and arp as the standard Linux networking tool. How its object and command structure works, the commands you will actually use for addresses, links, routes, and neighbours, and why changes do not survive a reboot. sshfs and rclone mount: Mounting Remote Storage as a Local Folder Mount a server's files over SSH with sshfs, or cloud storage like S3, Backblaze B2, and Google Drive with rclone mount, and use them like any local directory. Setup, fstab and systemd mounts, caching, and when a sync is better than a mount. Syncthing Explained: Peer-to-Peer File Sync Without a Cloud Syncthing keeps folders in sync directly between your own devices, encrypted, with no server or account. How device IDs, folder sharing, and relays work, how to run it as a service on Linux, and how to avoid the mistakes that lose data. iperf3 Explained: Measuring Network Throughput Properly A speed test to the internet measures your provider. iperf3 measures the link you actually care about. Server and client setup, why a single TCP stream understates fast links, and how to tell a bandwidth problem from a latency one. tcpdump Explained: Capturing Packets and Reading What You Caught When the logs say a connection failed and both sides insist they are fine, the packets settle it. Filter syntax that actually narrows things down, reading a TCP handshake, and why you capture to a file and analyse it elsewhere. Unbound: Running Your Own Recursive DNS Resolver Pi-hole filters. A forwarder caches. Unbound resolves from the root servers itself, which means no provider sees your queries at all. Setup, DNSSEC, and the one setting that makes it feel slow when it is not. systemd-resolved Explained: Why /etc/resolv.conf Is a Symlink Now What systemd-resolved does, why 127.0.0.53 appears in resolv.conf, how split DNS works, and how to actually configure or disable it. Wi-Fi on Linux: iwd vs wpa_supplicant How the two Wi-Fi supplicants differ, which one your system is using, connecting from the command line, and diagnosing the driver and regulatory problems behind most failures. HAProxy: Load Balancing and Health Checking for Self-Hosted Services A reverse proxy built for distributing traffic across backends with real health checks, connection limits, and a statistics page that tells you what is actually happening. Network Bonding on Linux: Combining Interfaces for Redundancy or Speed Bonding aggregates several network interfaces into one. Some modes give failover with no switch configuration, others give more bandwidth and need the switch to cooperate. Traffic Shaping with tc: Fixing Bufferbloat and Limiting Bandwidth tc controls how the kernel queues outgoing packets. The most valuable thing it does is not limiting bandwidth but fixing the latency spikes that make a saturated link feel broken. IPv6 on Linux: Addresses, Autoconfiguration, and Why Your Firewall Might Be Open IPv6 is on by default and most people never configure it, which is exactly how a machine ends up firewalled on IPv4 and reachable on IPv6. Here is what the address types mean and what to check. VLANs and Bridges on Linux: Segmenting a Network on One Cable A bridge is a software switch and a VLAN tags traffic so one physical link carries several logical networks. Together they are how virtual machines and containers reach a real network. Container Networking Explained: Bridges, Ports, and Why Your Containers Cannot Talk Published ports, user-defined networks, DNS between containers, and why binding to 0.0.0.0 exposes a service your firewall thinks is closed. Pi-hole and Network-Wide DNS Filtering Blocking ads at the DNS layer covers every device on the network including the ones that cannot run an extension. Here is how it works, what it cannot do, and how to avoid making yourself the network outage. WireGuard vs OpenVPN vs Tailscale: Choosing a VPN for a Homelab Three tools, three different problems. One is a protocol, one is an older protocol with more options, and one is a coordination layer that removes the hard part. Here is which to use when. dig Explained: Diagnosing DNS From the Command Line Half of all networking problems are DNS problems, and dig is how you find out which half. Here is how to query specific servers, trace a lookup from the root, and read what comes back. netcat Explained: Testing Ports, Moving Files, and Debugging Protocols netcat reads and writes arbitrary TCP and UDP connections, which makes it the fastest way to answer is this port actually open and what is that service really saying. lsof Explained: Finding What Has a File, Port, or Mount Open Everything on Linux is a file, which means one tool can answer what is using this port, why can I not unmount this disk, and what is holding onto deleted data. That tool is lsof. sysctl Explained: Reading and Changing Kernel Parameters IP forwarding, swappiness, file descriptor limits, and connection backlogs are all kernel parameters you can read and change at runtime. Here is how sysctl works and which settings are actually worth touching. TLS Certificates on Linux: Let's Encrypt, certbot, and What Actually Happens Free automated certificates removed the last excuse for running services over plain HTTP. Here is how the ACME challenge works, how to get a certificate with certbot, and how to handle wildcards and renewal properly. NFS vs Samba Explained: Sharing Files Between Machines NFS and Samba both put one machine s storage on another machine s filesystem, but they come from different worlds. Here is how each works, which to choose, and minimal working configs for both. Reverse Proxies Explained: Nginx, Caddy, and Traefik for Self-Hosters A reverse proxy sits in front of your services, routing incoming requests by hostname and terminating HTTPS in one place. Here is why every self-hosted setup grows one, and how the three big options differ. SSH Tunneling Explained: Local, Remote, and Dynamic Port Forwarding SSH can carry more than shells. With -L, -R, and -D it forwards ports through encrypted tunnels, reaching firewalled services, exposing local apps, and acting as a instant SOCKS proxy. WireGuard Explained: The Modern Linux VPN WireGuard is a VPN protocol built into the Linux kernel: a few thousand lines of code, public-key pairs instead of certificate bureaucracy, and configs short enough to read. Here is how it works and a working two-peer setup. Checking Network Connections: ss and nmcli Explained ss inspects active sockets and connections, and nmcli configures and queries NetworkManager. Together they cover the two most common modern network troubleshooting and configuration tasks on Linux. curl and wget Explained curl and wget are the two standard command-line tools for making HTTP requests and downloading files on Linux. This guide covers when to use each, common flags, and practical examples for downloads, APIs, and scripting. Checking Open Ports on Linux Knowing which ports are open and which processes are listening on them is essential for security audits, debugging, and firewall configuration. This guide covers ss, lsof, nmap, and related tools. DNS Explained DNS translates human-readable hostnames into IP addresses. This guide covers how the resolution process works, the most important record types, and the Linux tools used to query and debug DNS. IP Addresses Explained IP addresses are how devices on a network identify themselves. This guide covers IPv4 and IPv6 addressing, CIDR notation, public vs private addresses, subnetting basics, and how Linux assigns and displays addresses. Linux Firewall Basics Linux firewalls control which network traffic is allowed in and out of your system. This guide covers the concepts, ufw for simple setups, and an introduction to the underlying nftables rules that power them all. Linux Networking Basics Understanding how Linux handles networking -- interfaces, IP addresses, routing, DNS, and the tools to inspect all of it -- is foundational for anyone administering a Linux system or working with servers. Network Troubleshooting Commands A practical guide to diagnosing Linux network problems -- from basic connectivity checks with ping, through route tracing with mtr and traceroute, to packet capture with tcpdump and DNS debugging with dig. nftables vs iptables nftables replaced iptables as the standard Linux packet filtering framework. This guide explains the differences, how to use both, and how to migrate from iptables rules to nftables. SCP vs SFTP vs rsync SCP, SFTP, and rsync are the three main tools for transferring files over SSH on Linux. This guide covers when to use each, how they work, and practical command examples for common transfer scenarios. SSH Beginner's Guide SSH (Secure Shell) lets you log into remote Linux systems, run commands, and transfer files over an encrypted connection. This guide covers key-based authentication, the SSH config file, port forwarding, and common SSH patterns.