Advertisement
Interview Question
Disk usage looks low, but new files cannot be created and services fail with ENOSPC. How do you confirm inode exhaustion and fix it?
Key Points to Cover
- Confirm with df -i; identify directories with many small files
- Clean up temp/cache directories and rotate logs
- Bundle small files, adjust app temp file behavior
- Consider filesystem with higher inode density or reformat
- Add alerts on inode utilization
Evaluation Rubric
Detects inode exhaustion precisely30% weight
Finds directories causing inode pressure30% weight
Applies cleanup and longer-term solutions20% weight
Adds monitoring to prevent recurrence20% weight
Hints
- 💡Look for per-user caches and build artifacts.
Common Pitfalls to Avoid
- ⚠️Assuming low disk space percentage means no inode issue, overlooking `df -i`.
- ⚠️Performing blanket `rm -rf /` or similar destructive commands without first identifying the specific directories consuming inodes.
- ⚠️Not understanding the impact of small, numerous files on inode consumption.
- ⚠️Ignoring application-specific file creation patterns and focusing solely on system-level cleanup.
- ⚠️Failing to implement or regularly check log rotation configurations, leading to recurring log file inode issues.
Potential Follow-up Questions
- ❓How to design apps to avoid inode issues?
- ❓Would object storage help?
Advertisement
Related Questions
Questions that share similar topics with this one
Node Disk Full
Intermediate🔧 Troubleshooting Scenarios•10 min•Scenario
du and df Show Different Disk Usage
Intermediate🔧 Troubleshooting Scenarios•10 min•Scenario
Check Disk Space in Linux
Beginner📞 Phone Screen•1 min•Phone
SSH Keys vs Password Authentication
Beginner📞 Phone Screen•1 min•Phone
Find Top CPU Processes in Linux
Beginner📞 Phone Screen•1 min•Phone
Related Articles
Deepen your knowledge with these related blog posts
Real-Time Monitoring with eBPF: Low-Overhead Insights for Linux & K8s
eBPF is reshaping observability by enabling low-overhead, high-fidelity monitoring directly from the Linux kernel. Learn how it works, practical use cases, and tooling for real-time insights.
15 min read
Building a Security Operations Center (SOC) That Actually Works: A Practical Guide for Modern Organizations
Learn how to build and operate an effective Security Operations Center (SOC) that strengthens your organization's security posture, ensures compliance, and scales with your business needs.
12 min read