Home › Linux Administration & Deployment
"Disk full" is one of the most common production incidents. Need Command Free space per filesystem df -h (and df -i for inodes) What uses space du -sh \ sort -h, ncdu Biggest files find / -xdev -type f -size +500M Deleted-but-open files lsof +L1 (space freed only when the process restarts) Block devices lsblk -f Mount / persist mount /dev/sdb1 /data + /etc/fstab (use UUID) Archives tar -czf a.tar.gz dir, tar -xzf a.tar.gz -C /dest, zip/unzip Log rotation /etc/logrotate.d/<app> Keep logs under control with logrotate and journald limits (SystemMaxUse= in /etc/systemd/journald.conf).