Welcome to InfoTech Ninja

IT professional writing about cybersecurity, cloud & DevOps, automation, networking, and systems administration. Real-world guides for real-world problems.

#Cybersecurity #Cloud #Automation #Networking #SysAdmin

Latest Articles

Linux Networking Errors: 10 Common Connection Problems and Fixes

Working reference for the 10 most common Linux networking errors. Connection refused vs timed out (RST vs silent drop), No route to host, NXDOMAIN DNS failures (dig +short / resolv.conf / nsswitch), SSL certificate verify failed (expired / CN mismatch / clock skew), Network unreachable, Address already in use (EADDRINUSE with ss -tlnp 'sport = :PORT'), TIME_WAIT exhaustion, ARP resolution, SSH permission denied (publickey). Each error covers description, root cause, and step-by-step fix using the OSI-ladder diagnostic order. Cross-linked to the Linux networking command reference and the advanced-networking-errors deep-dive.

Linux Process & Memory Errors: OOM, ulimit, fork failures

Working reference for the 10 most common Linux process and memory errors. OOM killer victim selection (oom_score / oom_score_adj), ENOMEM and vm.overcommit_memory, EMFILE too-many-open-files (ulimit -n vs systemd LimitNOFILE vs fs.file-max), EAGAIN on fork (nproc limit), SIGSEGV with core-dump analysis, swap-thrash kills, D-state uninterruptible sleep diagnosis (/proc/PID/wchan + stack), system-wide ENFILE, pthread_create failures, silent cron failures. Cross-links to Process Management and System Monitoring command references.

Linux Filesystem & Disk Errors: 10 Common Problems and Fixes

Working reference for the 10 most common Linux filesystem and disk errors. No space left on device, Read-only filesystem (errors=remount-ro after I/O failure), inode exhaustion (df -i), Permission denied (and the SELinux/AppArmor twin), Bad magic number in super-block, Disk quota exceeded, Stale file handle (NFS ESTALE), generic I/O errors with SMART correlation, /tmp full, fsck failure during boot. Each error covers description, root cause, common scenarios, and step-by-step fix. Includes cross-links to the Linux Disk & Filesystem command reference and to related troubleshooting topics (Storage/RAID, Performance).

Linux User & Service Management: useradd, sudo, systemctl, journalctl

Working reference for Linux user and service management. The /etc/passwd / shadow / group files behind the tools, useradd vs adduser (scripting vs interactive), the critical usermod -aG (vs -G alone wiping groups), su vs sudo with sudo as the preferred default, visudo and per-file /etc/sudoers.d/ drop-ins, group management with groupadd / gpasswd. The systemd toolkit: systemctl start / stop / restart / reload / enable / disable / mask, list-units --state=failed, daemon-reload after unit edits, journalctl with -u SERVICE -f / -p err / --since / -b -1 previous boot / --vacuum-time. Minimal custom unit file template. Pitfalls: usermod -G without -a, editing sudoers with vim directly, forgetting daemon-reload, restart instead of reload, userdel -r vs without.

Linux Archives & Compression: tar, gzip, xz, zstd, zip

Working reference for Linux archives and compression. tar bundles, gzip / bzip2 / xz / zstd / lz4 squeeze - speed vs ratio trade-offs (zstd as modern Pareto-optimal default, gzip for compatibility, xz for tightest), tar create / extract / list flags (c / x / t / f / v / z / j / J / a auto-detect), the c-vs-x mnemonic, common --exclude patterns, the zcat / zless / zgrep family for working with compressed files in place, zip for cross-platform Windows-friendly archives, 7z for strong AES encryption, recipes (timestamped backups, archive verification, streaming over SSH, parallel compression with pigz / pbzip2 / zstd -T0). Pitfalls: tar c-vs-x mixup, recursive backup-includes-itself, re-compressing already-compressed media, xz memory hunger on small VMs, gzip removing the original.

Linux Networking Commands: ip, ss, ssh, curl, dig, tcpdump

Working reference for Linux networking from the command line. The modern iproute2 toolchain (ip a / ip r / ip link replacing ifconfig / route, ss replacing netstat, bridge replacing brctl), the killer ip route get DESTINATION command, ss flag combos for listening sockets and established connections, ping / traceroute / mtr for path diagnosis, dig +short and dig +trace for DNS, ssh with port-forward (-L / -R / -D / -J jump host) and ~/.ssh/config persistence, scp vs rsync (rsync -avPn for dry-run before destructive sync), the trailing-slash gotcha on rsync source, curl flags (-I headers / -L follow / -X POST / -v verbose), wget -c continue, and tcpdump for packet capture (-w to save for Wireshark). Pitfalls: deprecated ifconfig misleads on multi-IP, DNS-vs-network confusion, scp -P / ssh -p capital mismatch, MTU surprises over tunnels.

Linux System Monitoring: vmstat, top, iostat, sar, journalctl

Working playbook for diagnosing a slow Linux server. The 60-second triage sequence (uptime, dmesg -T, vmstat 1 5, free -h, df -h + df -i), reading load average against nproc CPU count, what each %CPU breakdown means in top (us/sy/id/wa, with iowait being the disk-pressure tell), the eight vmstat numbers that matter (r runnable, b blocked, swpd / si / so swap activity, bi / bo block I/O), available vs free memory (Linux file caching makes free deceptively small), iostat -x for per-device IOPS / await / %util, dmesg -T for kernel-level errors and OOM-killer activity, journalctl -u SERVICE -f as the systemd tail -f, sar / sysstat for historical data so you can answer 'was it slow at 3 AM yesterday', ss / lsof / strace / pmap for per-process deep dives. Pitfalls: looking at free not available, one vmstat sample is meaningless, high load isn't always CPU.

Linux Disk & Filesystem: lsblk, mount, fstab, fsck

Working reference for Linux disk and filesystem management. The four-layer model (block device > partition > filesystem > mount point), lsblk for orientation, df -h vs df -i (inode exhaustion looks like out-of-space), du and ncdu for finding disk hogs, partitioning with fdisk / parted / cfdisk (and when MBR vs GPT), mkfs for ext4 / xfs / btrfs / vfat, manual mount and umount with -l lazy and lsof / fuser to find what's blocking unmount, persistent /etc/fstab (UUID-not-device, six-field syntax, mount -a to test before reboot, nofail for non-critical), the menu of mount options (noatime, nosuid, noexec), fsck only on unmounted FS, swap setup with fallocate / mkswap / swapon. Pitfalls: out of inodes, fstab blocks boot, sdX name shift, fsck on mounted, missing chmod 600 on swap.