Back to commands

Linux Survival Basics

Read-only

Check Whether a Service Starts at Boot

A service is manually started during an incident, but nobody verifies whether systemd will start it after reboot.

Command

systemctl is-enabled 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 to check whether the service is currently running; use systemctl is-active for that.

Expected output

enabled

System impact

Read-only. Nothing changes. systemctl prints enabled, disabled, static, masked, or another enablement state.

Recovery / rollback: no state is changed.

When to use it

Use after installing services, recovering incidents, or manually starting daemons.

When not to use it

Do not use it to check whether the service is currently running; use systemctl is-active for that.

Watch this command run

Command transcript

This sanitized transcript shows the commands and output shape without exposing host details.

demo@lab:~$

$ systemctl is-enabled nginx

enabled

$ systemctl is-active nginx

active
View commands shown

These are the commands shown in the sanitized transcript.

Commands shown

  1. systemctl is-enabled nginx
  2. systemctl is-active nginx

next steps

Related commands

Linux Survival Basics Read-only

Inspect One Service Without Pager Traps

Make systemctl status safe for scripts, screenshots, and quick incident notes.

systemctl status nginx --no-pager --lines=30
Linux Survival Basics Read-only

Check If a Service Is Active

Get a clean yes-or-no service state without the full status page.

systemctl is-active nginx
Linux Survival Basics Read-only

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
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.

  • lpic1:101-system-architecture
  • lpic1:103-gnu-unix-commands
  • lpic1:108-essential-services
  • lfcs:essential-commands
  • lfcs:operations-deployment
  • lfcs:services-logs
  • linuxplus:provisional
  • linuxplus:services-users
  • linuxplus:troubleshooting
  • risk:read-only

Useful for

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

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