InterviewStack.io LogoInterviewStack.io

Command Line Proficiency and Troubleshooting Questions

Comfortable using shell commands for system troubleshooting and administration. Key tools: ps (process information), top and htop (real-time monitoring), grep, sed, awk (text processing), curl (HTTP requests), netstat and ss (network statistics), du and df (disk usage), kill and killall (process termination), tar and gzip (compression). Know how to redirect I/O, pipe commands together, and create simple scripts. Understand how to use man pages.

MediumTechnical
36 practiced
Create a small, well-documented shell function to retry a given command up to N times with exponential backoff and jitter. The function should accept the command as arguments, the max retries, and a base delay. Provide the function in bash and explain how it handles exit codes and signal propagation.
HardTechnical
37 practiced
Problem solving: A background job process is spawning many short-lived child processes that create excessive load. From the shell, how would you detect which parent PID is spawning children most frequently and then throttle or stop that parent process safely? Provide commands to monitor spawn rate and a safe approach to mitigate immediate load.
HardTechnical
42 practiced
Parsing challenge: Given a CSV-like output from a diagnostic tool that uses commas and quoted fields, write an awk one-liner or small script that safely extracts the Nth column even when commas appear inside quotes. Example input: "2025-11-22,\"/api/v1/users,123\",200,120". Provide the command and explain limitations.
EasyTechnical
38 practiced
As an SRE responding to high CPU alerts, what one-liner commands would you run to list the top 10 processes consuming CPU and top 10 by resident memory, including full command lines? Provide a bash one-liner pipeline using common commands (ps, sort, head) that works on most Linux distributions.
HardTechnical
43 practiced
Provide a sed command that in-place edits a config file /etc/myapp/config.conf to change 'max_connections = 100' to 'max_connections = 150' only if the line is not commented out, and create a backup of the original file named config.conf.bak. Explain how your regex handles whitespace and comment characters.

Unlock Full Question Bank

Get access to hundreds of Command Line Proficiency and Troubleshooting interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.