Home Explore Blog CI



man-pages

10th chunk of `systemctl.man`
d3b2c3fc22702fa90af2ed2c75db2d4d2367942e316a4b300000000100000fa2
 exiting with non-zero error code, terminating abnormally or
           timing out), it will automatically enter the "failed" state and its exit code and status is recorded for introspection by the administrator until the service is stopped/re-started or reset with this command.

           In addition to resetting the "failed" state of a unit it also resets various other per-unit properties: the start rate limit counter of all unit types is reset to zero, as is the restart counter of service units.
           Thus, if a unit's start limit (as configured with StartLimitIntervalSec=/StartLimitBurst=) is hit and the unit refuses to be started again, use this command to make it startable again.

   Unit File Commands
       list-unit-files [PATTERN...]
           List unit files installed on the system, in combination with their enablement state (as reported by is-enabled). If one or more PATTERNs are specified, only unit files whose name matches one of them are shown
           (patterns matching unit file system paths are not supported).

           Unlike list-units this command will list template units in addition to explicitly instantiated units.

       enable UNIT..., enable PATH...
           Enable one or more units or unit instances. This will create a set of symlinks, as encoded in the [Install] sections of the indicated unit files. After the symlinks have been created, the system manager
           configuration is reloaded (in a way equivalent to daemon-reload), in order to ensure the changes are taken into account immediately. Note that this does not have the effect of also starting any of the units being
           enabled. If this is desired, combine this command with the --now switch, or invoke start with appropriate arguments later. Note that in case of unit instance enablement (i.e. enablement of units of the form
           foo@bar.service), symlinks named the same as instances are created in the unit configuration directory, however they point to the single template unit file they are instantiated from.

           This command expects either valid unit names (in which case various unit file directories are automatically searched for unit files with appropriate names), or absolute paths to unit files (in which case these
           files are read directly). If a specified unit file is located outside of the usual unit file directories, an additional symlink is created, linking it into the unit configuration path, thus ensuring it is found
           when requested by commands such as start. The file system where the linked unit files are located must be accessible when systemd is started (e.g. anything underneath /home/ or /var/ is not allowed, unless those
           directories are located on the root file system).

           This command will print the file system operations executed. This output may be suppressed by passing --quiet.

           Note that this operation creates only the symlinks suggested in the [Install] section of the unit files. While this command is the recommended way to manipulate the unit configuration directory, the administrator
           is free to make additional changes manually by placing or removing symlinks below this directory. This is particularly useful to create configurations that deviate from the suggested default installation. In this
           case, the administrator must make sure to invoke daemon-reload manually as necessary, in order to ensure the changes are taken into account.

           When using this operation on units without install information, a warning about it is shown.  --no-warn can be used to suppress the warning.

           Enabling units should not be confused with starting (activating) units, as done by the start command. Enabling and starting units is orthogonal: units may be enabled without being started and started without being
           enabled. Enabling simply hooks the unit into various suggested places (for example, so that the unit is

Title: systemctl Commands: reset-failed, list-unit-files, enable
Summary
This section details more systemctl commands, continuing from the previous section. `reset-failed` resets the 'failed' state of specified units, also resetting start rate limits and restart counters. `list-unit-files` lists unit files installed on the system along with their enablement state, optionally filtered by patterns. `enable` enables units or unit instances by creating symlinks as defined in the [Install] section of the unit files and reloads the system manager configuration. It accepts unit names or absolute paths to unit files, creates additional symlinks for files outside usual directories, and prints file system operations.