Back to commands

Hosting Operations

Read-only

Check Inodes When Disk Space Looks Fine

The system says there is no space left, but byte usage looks fine, so you need to check whether the filesystem ran out of inodes.

Command

df -ih

Before you run this

System impact: Read-only. Low when scoped to the shown target.

When not to use it: Do not use it to locate the directory with too many files. Follow up with targeted file-count inspection inside the affected mount.

Expected output

A filesystem table with inode totals, used/free inodes, IUse%, and mount points. High IUse% means new files can fail even when df -h still shows free bytes.

System impact

Read-only. Nothing changes. The command reports inode availability by filesystem, which is separate from free bytes.

Recovery / rollback: no state is changed.

When to use it

Use when package installs, mail queues, caches, or session files fail despite apparently available disk space.

When not to use it

Do not use it to locate the directory with too many files. Follow up with targeted file-count inspection inside the affected mount.

Why df -h can look fine

Byte space and inode space are separate. A filesystem can have free GBs and still fail to create files when IUse% is near 100%.

  1. df -h /var
  2. df -ih /var

Next safe command

After confirming inode pressure, count file-heavy directories on the same filesystem before deleting anything.

  1. find /var -xdev -type f -printf '%h\n' 2>/dev/null | sort | uniq -c | sort -nr | head

next steps

Related commands

Hosting Operations Read-only

Summarize Docker Disk Usage

See how Docker storage is split across images, containers, volumes, and cache.

docker system df -v
Hosting Operations Can be slow

Create a SHA256 Checksum Manifest

A file list says what exists; checksums say whether bytes match.

sha256sum source/app/config.yml source/content/index.md source/content/about.md source/assets/logo.svg
Hosting Operations Can be slow

Find Directories Burning Inodes

Inode cleanup starts by finding the directory with too many files.

find /var/cache -xdev -type f -printf '%h\n' 2>/dev/null | sort | uniq -c | sort -nr | head
Hosting Operations Can be slow

Summarize Cache File Ages

Cache cleanup is safer when you know whether files are stale or still active.

find /var/cache -xdev -type f -printf '%TY-%Tm-%Td\n' 2>/dev/null | sort | uniq -c

next diagnostic step

Where to go from this command

Study mapping

Use this as independent command practice: read the notes, predict the output, then compare it with the example before using a real shell.

  • LPIC-1 style command-line practice
  • LFCS style performance-task practice
  • Linux+ style troubleshooting review

Independent study support only. No affiliation, endorsement, exam dumps, or real exam questions.