Linux disk full or no space left on device
Prove which filesystem is full, check inodes, then rank directories and files before deleting anything.
df -h
problem hubs
Repair paths for common Linux failures: first safe command, expected output, what to read next, and what not to change yet.
32 problem hubs
Prove which filesystem is full, check inodes, then rank directories and files before deleting anything.
df -h
Measure Docker image, container, volume, and build-cache usage before pruning anything that may hold data.
docker system df -v
Measure systemd journal usage and retention before vacuuming logs or deleting journal directories.
journalctl --disk-usage
Check mount options and kernel storage errors before remounting read-write or editing fstab.
findmnt -no TARGET,OPTIONS /
Check system file-handle pressure, process open files, and service limits before raising limits or restarting services.
cat /proc/sys/fs/file-nr
Check the active crontab, cron service, logs, user, environment, and script assumptions before rewriting the schedule.
crontab -l
Inspect auth logs, authorized_keys, file modes, and effective sshd policy before changing access.
grep -E 'Failed publickey|Accepted publickey|Authentication refused' /var/log/auth.log | tail -50
Trace owner, mode, ACL, symlink, and parent-directory permissions before recursive chmod or chown.
namei -l /var/www/example/index.html
Separate Nginx config, upstream listener, proxy target, and application failure before reloading services.
sudo nginx -t
Read service state, result fields, current-boot logs, restart loops, and unit drop-ins before restarting or editing a service.
systemctl status app-worker --no-pager --lines=50
Compare resolver answers, authoritative answers, TTL, direct HTTP checks, and server reachability before changing DNS again.
dig +short example.com A
Find the listener, process, bind address, and firewall context before killing or restarting anything.
ss -ltnp
Inspect package state, held packages, candidates, and simulated changes before running repair commands.
apt-get -s upgrade
Rank CPU consumers and capture process context before killing or restarting a service.
ps -eo pid,ppid,stat,pcpu,pmem,comm,args --sort=-pcpu | head
Check memory, swap, top memory processes, containers, and OOM logs before restarting workloads.
free -h
Find the package manager process, lock owner, and timer before deleting lock files or forcing package repair.
ps -ef | grep -E 'apt|dpkg|dnf|yum|pacman' | grep -v grep
Inspect the shebang and line endings before rewriting scripts or changing execute permissions.
head -1 script.sh | cat -v
Prove the service is listening, then read host firewall rules before opening ports.
ss -ltnp
Verify fstab entries and boot-time mount failures before rebooting or editing storage paths.
findmnt --verify
Confirm whether the kernel killed a process for memory pressure before restarting workloads or changing limits.
journalctl -k --since '24 hours ago' --no-pager | grep -iE 'out of memory|oom-killer|killed process'
Check identity, groups, and sudo policy before editing sudoers or adding broad admin access.
id username
Diagnose path permissions, Nginx root/alias config, access rules, and error logs before changing modes or ownership.
sudo nginx -t
Use dry-run renewal, certificate inventory, Certbot logs, and DNS checks before editing live TLS config.
sudo certbot renew --dry-run
Inspect route table, interface addresses, NetworkManager state, and resolver state before restarting networking.
ip route
Debug logrotate config and timer state before forcing rotation or truncating logs.
logrotate -d /etc/logrotate.conf
Check /boot usage, installed kernels, and the running kernel before cleanup.
df -h /boot
Verify stored and presented host keys out of band before editing known_hosts.
ssh-keygen -F hostname
Inspect the live certificate, Nginx server block, Certbot inventory, and DNS before reissuing or reloading TLS config.
openssl s_client -connect example.com:443 -servername example.com </dev/null 2>/dev/null | openssl x509 -noout -subject -issuer -dates
Check Apache syntax, enabled sites, document root, Directory rules, path permissions, and error logs before chmod or ownership changes.
sudo apachectl configtest
Inspect container status, logs, restart policy, exit code, and recent events before rebuilding or deleting containers.
docker ps -a --format 'table {{.Names}}\t{{.Image}}\t{{.Status}}\t{{.RestartCount}}'
Inspect timer schedule, status, unit file, and recent journal entries before enabling, starting, or editing timers.
systemctl list-timers --all --no-pager
Check auth logs, loaded agent keys, explicit identity selection, and verbose client output before changing sshd or deleting keys.
grep -i 'Too many authentication failures' /var/log/auth.log /var/log/secure 2>/dev/null | tail -20