User Tools

Site Tools


ubuntu:services:list_running_service

Ubuntu - Services - List Running Services

Using systemd Service to get a list of all services

systemctl -t service 

or

systemctl list-units --type=service

returns:

UNIT                                                  LOAD   ACTIVE SUB     DESCRIPTION                                                                  
accounts-daemon.service                               loaded active running Accounts Service                                                             
acpid.service                                         loaded active running ACPI event daemon                                                            
alsa-restore.service                                  loaded active exited  Save/Restore Sound Card State                                                
apparmor.service                                      loaded active exited  AppArmor initialization                                                      
apport.service                                        loaded active exited  LSB: automatic crash report generation                                       
avahi-daemon.service                                  loaded active running Avahi mDNS/DNS-SD Stack                                                      
binfmt-support.service                                loaded active exited  Enable support for additional executable binary formats                      
blk-availability.service                              loaded active exited  Availability of block devices                                                
bluetooth.service                                     loaded active running Bluetooth service                                                            
...

Only running services

systemctl | grep running

Get Service Settings

systemctl list-unit-files -t service 

returns:

UNIT FILE                                  STATE          
accounts-daemon.service                    enabled        
acpid.service                              disabled       
alsa-restore.service                       static         
alsa-state.service                         static         
alsa-utils.service                         masked         
anacron.service                            enabled        
apparmor.service                           enabled        
apport-autoreport.service                  static         
apport-forward@.service                    static         
apport.service                             generated      
apt-daily-upgrade.service                  static         
apt-daily.service                          static         
autovt@.service                            enabled        
avahi-daemon.service                       enabled        
binfmt-support.service                     enabled        
blk-availability.service                   enabled        
bluetooth.service                          enabled        

Using systemd Status

systemctl status

returns:

● peter-bigmamba
    State: running
     Jobs: 0 queued
   Failed: 0 units
    Since: Tue 2019-12-03 19:02:51 GMT; 4 days ago
   CGroup: /
           ├─user.slice
           │ ├─user-1000.slice
           │ │ ├─user@1000.service
           │ │ │ ├─gvfs-goa-volume-monitor.service
           │ │ │ │ └─19454 /usr/lib/gvfs/gvfs-goa-volume-monitor
           │ │ │ ├─xdg-permission-store.service
           │ │ │ │ └─19404 /usr/libexec/xdg-permission-store
           │ │ │ ├─evolution-calendar-factory.service
           │ │ │ │ ├─19690 /usr/lib/evolution/evolution-calendar-factory
           │ │ │ │ └─19738 /usr/lib/evolution/evolution-calendar-factory-subprocess --factory all --bus-name org.gnome.evolution.dataserver.Subprocess.Backend.Calendarx19690x2 --own-path /org/gnome/evolution/dataserver/Subprocess/Backend/Calendar/19690/2
           │ │ │ ├─gvfs-daemon.service
           │ │ │ │ ├─19338 /usr/lib/gvfs/gvfsd
           │ │ │ │ ├─19343 /usr/lib/gvfs/gvfsd-fuse /run/user/1000/gvfs -f -o big_writes
           │ │ │ │ ├─19628 /usr/lib/gvfs/gvfsd-trash --spawner :1.22 /org/gtk/gvfs/exec_spaw/0
...

Using Upstart

initctl list
ubuntu/services/list_running_service.txt · Last modified: 2021/06/22 12:26 by peter

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki