Back to commands

Web Server Rescue

Read-only, can be slow

Inspect Release Disk Usage

A host is low on disk and release directories may be taking too much space.

Command

du -sh releases/* 2>/dev/null | sort -h | tail -10

Before you run this

System impact: Read-only. Can create load on large logs, directories, filesystems, or process tables.

When not to use it: Do not run recursive disk scans on extremely busy hosts if the extra I/O is unacceptable.

Expected output

The largest release directories, sorted by human-readable size.

System impact

Read-only, can be slow. Nothing changes. Disk usage is calculated and printed.

Scope this to the smallest useful path or service on busy systems.

Recovery / rollback: no state is changed.

When to use it

Use when deploys fail due to disk space or cleanup policies need review.

When not to use it

Do not run recursive disk scans on extremely busy hosts if the extra I/O is unacceptable.

next steps

Related commands

Web Server Rescue Can be slow

Find Large Directories with du

Once you know a filesystem is full, the next question is where.

du -xh --max-depth=1 /var 2>/dev/null | sort -h
Web Server Rescue Sensitive output

Show TLS Certificate Dates

The outage was not the web server. The edge certificate had expired.

openssl s_client -connect example.com:443 -servername example.com </dev/null 2>/dev/null | openssl x509 -noout -dates
Web Server Rescue Sensitive output

Show TLS Certificate Names

The cert was valid, but not for this hostname.

openssl s_client -connect example.com:443 -servername example.com </dev/null 2>/dev/null | openssl x509 -noout -subject -ext subjectAltName
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.