Systemctl

From NovaOrdis Knowledge Base
Revision as of 22:23, 19 August 2023 by Ovidiu (talk | contribs) (→‎Internal)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Internal

Overview

See

systemd Concepts - Services

-q (quiet)

Suppress output to standard output in snapshot, is-active, is-failed, is-enabled, is-system-running, enable and disable. However, it does not suppress output to stderr, which happens when the unit in question does not exists, etc.

You may want to consider:

systemctl -q .... 2>/dev/null

Commands

list-units

Lists loaded active units.

In order to list all loaded units (active or inactive), use -a or --all:

systemctl list-units --all

is-enabled

Tells whether the service is enabled at boot.

is-active

Tells whether the service is running, or it was shut down.

status

show

Show properties of one or more units.

enable

Enable a Service at Boot

disable

systemctl disable haproxy

start

Start (activate) one or more units.

Start a service

stop

Stop (deactivate) one or more units.