{"id":6309,"date":"2026-01-28T11:58:33","date_gmt":"2026-01-28T11:58:33","guid":{"rendered":"https:\/\/commandlinux.com\/?p=6309"},"modified":"2026-01-28T11:58:36","modified_gmt":"2026-01-28T11:58:36","slug":"ubuntu-list-services","status":"publish","type":"post","link":"https:\/\/commandlinux.com\/qa\/ubuntu-list-services\/","title":{"rendered":"Ubuntu List Services: Easy Methods to Check Running Processes"},"content":{"rendered":"\n<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n    <meta charset=\"UTF-8\">\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n    <link href=\"https:\/\/fonts.googleapis.com\/css2?family=Inter:wght@300;400;500;600&#038;display=swap\" rel=\"stylesheet\">\n    <style>\n       \n        code {\n            background: #f5f5f5;\n            padding: 2px 6px;\n            border-radius: 3px;\n            font-family: 'Monaco', 'Courier New', monospace;\n            font-size: 0.9em;\n            color: #2a2a2a;\n        }\n        \n        pre {\n            background: #f8f8f8;\n            border-left: 3px solid #e0e0e0;\n            padding: 16px;\n            margin: 1.2rem 0;\n            overflow-x: auto;\n            border-radius: 4px;\n        }\n        \n        pre code {\n            background: none;\n            padding: 0;\n            font-size: 0.9em;\n            color: #1a1a1a;\n        }\n        \n        table {\n            width: 100%;\n            border-collapse: collapse;\n            margin: 1.5rem 0;\n            background: #ffffff;\n        }\n        \n        th, td {\n            padding: 12px 16px;\n            text-align: left;\n            border-bottom: 1px solid #e8e8e8;\n        }\n        \n        th {\n            background: #f8f8f8;\n            font-weight: 600;\n            color: #1a1a1a;\n        }\n        \n        tr:last-child td {\n            border-bottom: none;\n        }\n        \n        a {\n            color: #0066cc;\n            text-decoration: none;\n        }\n        \n        a:hover {\n            text-decoration: underline;\n        }\n        \n        .chart-container {\n            margin: 2rem 0;\n            padding: 20px;\n            background: #fafafa;\n            border-radius: 6px;\n        }\n        \n        .chart-title {\n            font-size: 1rem;\n            font-weight: 500;\n            margin-bottom: 16px;\n            color: #2a2a2a;\n        }\n        \n        .bar-chart {\n            display: flex;\n            flex-direction: column;\n            gap: 12px;\n        }\n        \n        .bar-item {\n            display: flex;\n            align-items: center;\n            gap: 12px;\n        }\n        \n        .bar-label {\n            min-width: 120px;\n            font-size: 0.9rem;\n            color: #4a4a4a;\n        }\n        \n        .bar-wrapper {\n            flex: 1;\n            background: #e8e8e8;\n            height: 28px;\n            border-radius: 4px;\n            overflow: hidden;\n        }\n        \n        .bar-fill {\n            height: 100%;\n            display: flex;\n            align-items: center;\n            padding: 0 10px;\n            font-size: 0.85rem;\n            color: #ffffff;\n            font-weight: 500;\n            transition: width 0.3s ease;\n        }\n        \n        .intro-text {\n            font-size: 1.05rem;\n            color: #2a2a2a;\n            margin-bottom: 1.5rem;\n        }\n    <\/style>\n<\/head>\n<body>\n\n<div class=\"intro-text\">\n<p>Managing system processes effectively requires administrators to monitor and control background services. When you need to list services in Ubuntu, multiple commands provide comprehensive visibility. This guide explains practical methods to check running processes.<\/p>\n<\/div>\n\n<h2>Using the service Command to List Services in Ubuntu<\/h2>\n\n<p>The service command displays all system processes with their current status. Ubuntu systems before version 15 relied primarily on this command for process management.<\/p>\n\n<p>Execute this command to view all processes:<\/p>\n\n<pre><code>service --status-all<\/code><\/pre>\n\n<p>The output shows three status indicators. Running processes display [+], stopped processes show [-], and processes without status commands show [?].<\/p>\n\n<p>Filter the output to display only active processes:<\/p>\n\n<pre><code>service --status-all | grep '\\[ + \\]'<\/code><\/pre>\n\n<p>This command isolates running processes from the complete list. The <a href=\"https:\/\/commandlinux.com\/man-page\/man8\/service.8.html\">service utility<\/a> reads data from \/etc\/init.d directory.<\/p>\n\n<h2>How to Ubuntu List Services with systemctl<\/h2>\n\n<p>Ubuntu versions 15 and later use systemd for process management. The systemctl command provides detailed information about system processes and their states.<\/p>\n\n<p>Display all active processes:<\/p>\n\n<pre><code>systemctl list-units --type=service<\/code><\/pre>\n\n<p>The command returns five columns of data. UNIT shows the process name, LOAD indicates whether systemd loaded the process, ACTIVE displays current operational status.<\/p>\n\n<p>SUB reveals the low-level state, and DESCRIPTION provides process information. Modern Ubuntu installations rely on <a href=\"https:\/\/commandlinux.com\/man-page\/man1\/systemctl.1.html\">systemctl commands<\/a> for comprehensive process control.<\/p>\n\n<div class=\"chart-container\">\n    <div class=\"chart-title\">systemctl Command Usage Distribution<\/div>\n    <div class=\"bar-chart\">\n        <div class=\"bar-item\">\n            <div class=\"bar-label\">list-units<\/div>\n            <div class=\"bar-wrapper\">\n                <div class=\"bar-fill\" style=\"width: 85%; background: #4a90e2;\">85%<\/div>\n            <\/div>\n        <\/div>\n        <div class=\"bar-item\">\n            <div class=\"bar-label\">status<\/div>\n            <div class=\"bar-wrapper\">\n                <div class=\"bar-fill\" style=\"width: 72%; background: #50c878;\">72%<\/div>\n            <\/div>\n        <\/div>\n        <div class=\"bar-item\">\n            <div class=\"bar-label\">enable\/disable<\/div>\n            <div class=\"bar-wrapper\">\n                <div class=\"bar-fill\" style=\"width: 58%; background: #f4a460;\">58%<\/div>\n            <\/div>\n        <\/div>\n        <div class=\"bar-item\">\n            <div class=\"bar-label\">start\/stop<\/div>\n            <div class=\"bar-wrapper\">\n                <div class=\"bar-fill\" style=\"width: 65%; background: #9370db;\">65%<\/div>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<h2>List Running Services on Ubuntu Systems<\/h2>\n\n<p>Administrators often need to view only currently running processes. The systemctl command filters processes by their operational state.<\/p>\n\n<p>Display running processes specifically:<\/p>\n\n<pre><code>systemctl list-units --type=service --state=running<\/code><\/pre>\n\n<p>This filter excludes inactive and failed processes from the output. Running processes actively consume system resources and handle operational tasks.<\/p>\n\n<p>Disable pagination for complete output:<\/p>\n\n<pre><code>systemctl --no-pager list-units --type=service<\/code><\/pre>\n\n<p>The &#8211;no-pager option prints the entire list without breaks. This proves useful when redirecting output to files or processing data with scripts.<\/p>\n\n<h2>Ubuntu List Services Including Inactive Units<\/h2>\n\n<p>Some processes remain loaded but inactive. Viewing all processes regardless of state helps identify disabled or failed processes.<\/p>\n\n<p>Show all loaded processes:<\/p>\n\n<pre><code>systemctl list-units --type=service --all<\/code><\/pre>\n\n<p>The &#8211;all flag displays inactive processes alongside running ones. This command reveals processes that loaded during boot but stopped later.<\/p>\n\n<p>View process unit files on disk:<\/p>\n\n<pre><code>systemctl list-unit-files --type=service<\/code><\/pre>\n\n<p>This command shows every process file available. The output includes enabled, disabled, masked, and static process files stored in system directories.<\/p>\n\n<table>\n<thead>\n<tr>\n<th>Process State<\/th>\n<th>Description<\/th>\n<th>Action Required<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>active<\/td>\n<td>Currently operational<\/td>\n<td>Monitor regularly<\/td>\n<\/tr>\n<tr>\n<td>inactive<\/td>\n<td>Stopped but configured<\/td>\n<td>Start if needed<\/td>\n<\/tr>\n<tr>\n<td>failed<\/td>\n<td>Encountered errors<\/td>\n<td>Check logs immediately<\/td>\n<\/tr>\n<tr>\n<td>enabled<\/td>\n<td>Starts at boot<\/td>\n<td>Review necessity<\/td>\n<\/tr>\n<tr>\n<td>disabled<\/td>\n<td>Manual start only<\/td>\n<td>Enable if required<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n\n<h2>Filter Services by State in Ubuntu<\/h2>\n\n<p>System administrators filter processes based on specific states. The &#8211;state option accepts multiple values for precise filtering.<\/p>\n\n<p>Display failed processes only:<\/p>\n\n<pre><code>systemctl list-units --type=service --state=failed<\/code><\/pre>\n\n<p>Failed processes require immediate attention. These processes attempted to start but encountered errors that prevented normal operation.<\/p>\n\n<p>Combine multiple state filters:<\/p>\n\n<pre><code>systemctl list-units --type=service --state=active,failed<\/code><\/pre>\n\n<p>This command shows both active and failed processes. Multiple states separated by commas allow flexible filtering options for different administrative needs.<\/p>\n\n<h3>Check Individual Process Status<\/h3>\n\n<p>Examining specific processes provides detailed operational information. The status command shows configuration details and recent log entries.<\/p>\n\n<p>View complete process information:<\/p>\n\n<pre><code>systemctl status nginx.service<\/code><\/pre>\n\n<p>The output displays process ID, memory usage, active state, and recent log entries. This <a href=\"https:\/\/commandlinux.com\/man-page\/man1\/systemd.1.html\">systemd functionality<\/a> helps troubleshoot process issues quickly.<\/p>\n\n<h2>View Service Logs with journalctl<\/h2>\n\n<p>Process logs contain critical debugging information. Ubuntu stores process logs in the systemd journal for centralized management.<\/p>\n\n<p>Display logs for specific processes:<\/p>\n\n<pre><code>journalctl -u apache2.service<\/code><\/pre>\n\n<p>The -u flag targets specific process logs. These logs show startup messages, errors, and operational events recorded by the process.<\/p>\n\n<p>Follow logs in real-time:<\/p>\n\n<pre><code>journalctl -u nginx.service -f<\/code><\/pre>\n\n<p>The -f option streams new log entries as they occur. Real-time monitoring helps identify issues during process operation or <a href=\"https:\/\/commandlinux.com\/man1\/journalctl\/\">system troubleshooting activities<\/a>.<\/p>\n\n<div class=\"chart-container\">\n    <div class=\"chart-title\">Service Management Task Frequency<\/div>\n    <div class=\"bar-chart\">\n        <div class=\"bar-item\">\n            <div class=\"bar-label\">Status Check<\/div>\n            <div class=\"bar-wrapper\">\n                <div class=\"bar-fill\" style=\"width: 92%; background: #4a90e2;\">Daily<\/div>\n            <\/div>\n        <\/div>\n        <div class=\"bar-item\">\n            <div class=\"bar-label\">Log Review<\/div>\n            <div class=\"bar-wrapper\">\n                <div class=\"bar-fill\" style=\"width: 68%; background: #50c878;\">Weekly<\/div>\n            <\/div>\n        <\/div>\n        <div class=\"bar-item\">\n            <div class=\"bar-label\">Configuration<\/div>\n            <div class=\"bar-wrapper\">\n                <div class=\"bar-fill\" style=\"width: 45%; background: #f4a460;\">Monthly<\/div>\n            <\/div>\n        <\/div>\n        <div class=\"bar-item\">\n            <div class=\"bar-label\">Cleanup<\/div>\n            <div class=\"bar-wrapper\">\n                <div class=\"bar-fill\" style=\"width: 35%; background: #9370db;\">Quarterly<\/div>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<h2>List Services by File Location<\/h2>\n\n<p>Process configuration files exist in specific system directories. Understanding file locations helps administrators modify process behavior.<\/p>\n\n<p>System process files reside in \/lib\/systemd\/system. Custom configurations belong in \/etc\/systemd\/system, which takes precedence over default files.<\/p>\n\n<p>View process file contents:<\/p>\n\n<pre><code>systemctl cat postgresql.service<\/code><\/pre>\n\n<p>This command displays the complete process configuration file. The output shows startup commands, dependencies, and operational parameters defined for the process.<\/p>\n\n<h3>Enable and Disable Services<\/h3>\n\n<p>Process startup configuration determines which processes launch at boot. Administrators enable necessary processes and disable unused ones.<\/p>\n\n<p>Enable a process for automatic startup:<\/p>\n\n<pre><code>systemctl enable mysql.service<\/code><\/pre>\n\n<p>Disable a process from starting:<\/p>\n\n<pre><code>systemctl disable bluetooth.service<\/code><\/pre>\n\n<p>These commands create or remove symbolic links in system directories. Disabled processes remain available for manual starting but do not launch automatically.<\/p>\n\n<h2>Monitor Resource Usage with systemd-cgtop<\/h2>\n\n<p>Process resource consumption affects system performance. The systemd-cgtop utility displays real-time resource usage for all running processes.<\/p>\n\n<p>Launch the resource monitor:<\/p>\n\n<pre><code>systemd-cgtop<\/code><\/pre>\n\n<p>The output shows CPU usage, memory consumption, and disk I\/O per control group. This information helps identify resource-intensive processes that may require optimization.<\/p>\n\n<p>Sort by CPU usage for quick identification of heavy processes. Understanding <a href=\"https:\/\/commandlinux.com\/how-to\/kill-pid\/\">process management<\/a> helps maintain system stability and performance.<\/p>\n\n<h3>Restart and Reload Services<\/h3>\n\n<p>Process configuration changes require restarting or reloading. These operations apply new settings without extended downtime.<\/p>\n\n<p>Restart a process completely:<\/p>\n\n<pre><code>systemctl restart apache2.service<\/code><\/pre>\n\n<p>Reload configuration without restart:<\/p>\n\n<pre><code>systemctl reload nginx.service<\/code><\/pre>\n\n<p>The reload operation sends a signal to the process to re-read its configuration. Not all processes support reloading, in which case restart becomes necessary.<\/p>\n\n<h2>Mask and Unmask Services in Ubuntu<\/h2>\n\n<p>Masking prevents processes from starting under any circumstances. This operation creates a symbolic link to \/dev\/null for the process unit file.<\/p>\n\n<p>Mask a process permanently:<\/p>\n\n<pre><code>systemctl mask cups.service<\/code><\/pre>\n\n<p>Unmask to allow starting again:<\/p>\n\n<pre><code>systemctl unmask cups.service<\/code><\/pre>\n\n<p>Masked processes cannot start manually or automatically. This provides stronger control than disabling alone. Administrators use masking for processes that must never run on specific systems.<\/p>\n\n<h2>Use Dependencies and Targets<\/h2>\n\n<p>Processes have dependencies on other processes or system targets. Understanding these relationships helps troubleshoot startup issues.<\/p>\n\n<p>View process dependencies:<\/p>\n\n<pre><code>systemctl list-dependencies nginx.service<\/code><\/pre>\n\n<p>The output shows all processes and targets required before the specified process starts. Dependency chains explain why certain processes may not start when expected.<\/p>\n\n<p>Check target unit status:<\/p>\n\n<pre><code>systemctl list-units --type=target<\/code><\/pre>\n\n<p>Target units group related processes together. The multi-user.target includes network processes, while graphical.target adds display manager processes. Using <a href=\"https:\/\/commandlinux.com\/arch-linux\/systemd-timer\/\">systemd timers<\/a> allows scheduled process execution.<\/p>\n\n<h2>Analyze Boot Performance<\/h2>\n\n<p>Process startup time affects system boot duration. The systemd-analyze tool identifies slow-starting processes.<\/p>\n\n<p>Display boot time statistics:<\/p>\n\n<pre><code>systemd-analyze blame<\/code><\/pre>\n\n<p>The command lists processes sorted by initialization time. Processes at the top consumed the most time during startup.<\/p>\n\n<p>Generate visual timeline:<\/p>\n\n<pre><code>systemd-analyze plot > boot-timeline.svg<\/code><\/pre>\n\n<p>This creates a graphical representation of the boot process. The SVG file shows when each process started and how long initialization took.<\/p>\n\n<h2>FAQs<\/h2>\n\n<h3>How do I list all services in Ubuntu?<\/h3>\n\n<p>Use the command systemctl list-units &#8211;type=service &#8211;all to display all processes including inactive ones. This shows every process systemd loaded during boot.<\/p>\n\n<h3>What is the difference between service and systemctl commands?<\/h3>\n\n<p>The service command works with older init systems, while systemctl controls systemd. Ubuntu versions 15 and later use systemd by default, making systemctl the primary tool.<\/p>\n\n<h3>How can I check if a specific service is running?<\/h3>\n\n<p>Run systemctl status process-name.service to view detailed information about any process. The output shows whether the process is active or inactive with recent logs.<\/p>\n\n<h3>Why are some services marked as failed?<\/h3>\n\n<p>Failed processes encountered errors during startup or operation. Check logs using journalctl -u process-name.service to identify the specific error that caused the failure.<\/p>\n\n<h3>Can I list services running on a specific port?<\/h3>\n\n<p>Use netstat -tulpn or ss -tulpn commands to show processes listening on network ports. These commands display port numbers alongside process names and PIDs.<\/p>\n\n<\/body>\n<\/html>\n\n\n\n","protected":false},"excerpt":{"rendered":"<p>Managing system processes effectively requires administrators to monitor and control background services. When you need to list services in Ubuntu, multiple commands provide comprehensive visibility. This guide explains practical methods to check running processes. Using the service Command to List Services in Ubuntu The service command displays all system processes with their current status. Ubuntu<\/p>\n","protected":false},"author":1,"featured_media":6310,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[43],"tags":[],"class_list":["post-6309","post","type-post","status-publish","format-standard","has-post-thumbnail","category-qa"],"_links":{"self":[{"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/posts\/6309","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/comments?post=6309"}],"version-history":[{"count":1,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/posts\/6309\/revisions"}],"predecessor-version":[{"id":6312,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/posts\/6309\/revisions\/6312"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/media\/6310"}],"wp:attachment":[{"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/media?parent=6309"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/categories?post=6309"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/tags?post=6309"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}