Какой вариант или команда systemctl я использовал бы для отображения сводки всех запущенных в данный момент сервисов?
Это (см. man 1 systemctl):
systemctl list-units | grep -E 'service.*running'
или (см. также man 1 systemctl )
service --status-all
Где [+] указывает службы, которые фактически запущены.
Вы можете использовать некоторые из опций systemctl:
-t, --type=
The argument should be a comma-separated list of unit types such as
service and socket.
If one of the arguments is a unit type, when listing units, limit
display to certain unit types. Otherwise, units of all types will
be shown.
As a special case, if one of the arguments is help, a list of
allowed values will be printed and the program will exit.
--state=
The argument should be a comma-separated list of unit LOAD, SUB, or
ACTIVE states. When listing units, show only those in the specified
states. Use --state=failed to show only failed units.
As a special case, if one of the arguments is help, a list of
allowed values will be printed and the program will exit.
Возможно, вы хотите:
systemctl --type=service --state=active list-units
В списке перечислены все активные службы, в том числе те, которые вышли , Если вы только после тех, кто работает в данный момент, вы можете использовать:
systemctl --type=service --state=running list-units
Это (см. man 1 systemctl):
systemctl list-units | grep -E 'service.*running'
или (см. также man 1 systemctl )
service --status-all
Где [+] указывает службы, которые фактически запущены.
Вы можете использовать некоторые из опций systemctl:
-t, --type=
The argument should be a comma-separated list of unit types such as
service and socket.
If one of the arguments is a unit type, when listing units, limit
display to certain unit types. Otherwise, units of all types will
be shown.
As a special case, if one of the arguments is help, a list of
allowed values will be printed and the program will exit.
--state=
The argument should be a comma-separated list of unit LOAD, SUB, or
ACTIVE states. When listing units, show only those in the specified
states. Use --state=failed to show only failed units.
As a special case, if one of the arguments is help, a list of
allowed values will be printed and the program will exit.
Возможно, вы хотите:
systemctl --type=service --state=active list-units
В списке перечислены все активные службы, в том числе те, которые вышли , Если вы только после тех, кто работает в данный момент, вы можете использовать:
systemctl --type=service --state=running list-units