snippetbashTip
systemctl preset — Reset the enablement state of unit files to the defaults specified in preset policy files. See also:
Viewed 0 times
theunitcommandstatecliresetenablementsystemctl preset
linux
Problem
How to use the
systemctl preset command: Reset the enablement state of unit files to the defaults specified in preset policy files. See also: systemctl preset-all, systemctl list-unit-files. More information: <https://www.freedesktop.org/software/systemd/man/latest/systemctl.html#preset%20UNIT%E2%80%A6>.Solution
systemctl preset — Reset the enablement state of unit files to the defaults specified in preset policy files. See also: systemctl preset-all, systemctl list-unit-files. More information: <https://www.freedesktop.org/software/systemd/man/latest/systemctl.html#preset%20UNIT%E2%80%A6>.Reset the enablement state to preset defaults:
systemctl preset {{unit1 unit2 ...}}Enable only if marked as enabled in the preset policy:
systemctl preset {{unit}} --preset-mode enable-onlyDisable only if marked as disabled in the preset policy:
systemctl preset {{unit}} --preset-mode disable-onlySuppress output and return only the exit code:
systemctl preset {{unit}} {{[-q|--quiet]}}Code Snippets
Reset the enablement state to preset defaults
systemctl preset {{unit1 unit2 ...}}Enable only if marked as enabled in the preset policy
systemctl preset {{unit}} --preset-mode enable-onlyDisable only if marked as disabled in the preset policy
systemctl preset {{unit}} --preset-mode disable-onlySuppress output and return only the exit code
systemctl preset {{unit}} {{[-q|--quiet]}}Context
tldr-pages: linux/systemctl preset
Revisions (0)
No revisions yet.