Linux Survival Basics
Read-onlyCheck If a Service Is Active
Full status output is noisy when a script, checklist, or quick human check only needs the current active state.
Command
systemctl is-active nginx
Before you run this
System impact: Read-only. Low when scoped to the shown target.
When not to use it: Do not use it as a replacement for endpoint checks, logs, or dependency checks.
Expected output
active
System impact
Read-only. Nothing changes. systemctl prints a compact state such as active, inactive, failed, or activating.
Recovery / rollback: no state is changed.
When to use it
Use in runbooks, smoke checks, and quick recovery validation after restarting a service.
When not to use it
Do not use it as a replacement for endpoint checks, logs, or dependency checks.
next steps
Related commands
Inspect One Service Without Pager Traps
Make systemctl status safe for scripts, screenshots, and quick incident notes.
systemctl status nginx --no-pager --lines=30
Check Whether a Service Starts at Boot
Running now does not mean it will survive the next reboot.
systemctl is-enabled nginx
Read the Failure Cause in systemctl Status
The status page often tells you the failed startup step before you open every log.
systemctl status app-worker --no-pager --lines=50
Print the Exact systemd Exit Fields
Turn a noisy service failure into four fields you can paste into an incident note.
systemctl show app-worker --property=Result,ExecMainCode,ExecMainStatus,NRestarts --no-pager
Show a Service LimitNOFILE
A shell ulimit is not the service limit.
systemctl show nginx -p LimitNOFILE --no-pager
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.
Independent study support only. No affiliation, endorsement, exam dumps, or real exam questions.