Ubuntu 20.04に稼働中のサービスを確認する

2021年10月31日

OSバージョンを確認
# cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=20.04
DISTRIB_CODENAME=focal
DISTRIB_DESCRIPTION="Ubuntu 20.04.3 LTS"

1.サービスの稼働状況一覧を確認

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
# service --status-all
[ + ] acpid
[ - ] alsa-utils
[ - ] anacron
[ + ] apparmor
[ + ] apport
[ + ] avahi-daemon
# service --status-all [ + ] acpid [ - ] alsa-utils [ - ] anacron [ + ] apparmor [ + ] apport [ + ] avahi-daemon 略
# service --status-all
 [ + ]  acpid
 [ - ]  alsa-utils
 [ - ]  anacron
 [ + ]  apparmor
 [ + ]  apport
 [ + ]  avahi-daemon
略

2.サービスの稼働詳細を確認
書式 service サービス名 status
操作例

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
# service nginx status
● nginx.service - A high performance web server and a reverse proxy server
Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset:>
Active: active (running) since Sun 2021-10-31 13:59:06 JST; 1h 15min ago
# service nginx status ● nginx.service - A high performance web server and a reverse proxy server Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset:> Active: active (running) since Sun 2021-10-31 13:59:06 JST; 1h 15min ago 略
# service nginx status
● nginx.service - A high performance web server and a reverse proxy server
     Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset:>
     Active: active (running) since Sun 2021-10-31 13:59:06 JST; 1h 15min ago
       略

 

Ubuntu 20.04

Posted by arkgame