summaryrefslogtreecommitdiffstats
path: root/man/systemd.unit.xml (follow)
Commit message (Collapse)AuthorAgeFilesLines
* tree-wide: use "_" rather than "-" as separator in kernel cmdline optionsLennart Poettering2024-02-281-2/+2
| | | | | | | | | | | Most of our kernel cmdline options use underscores as word separators in kernel cmdline options, but there were some exceptions. Let's fix those, and also use underscores. Since our /proc/cmdline parsers don't distinguish between the two characters anyway this should not break anything, but makes sure our own codebase (and in particular docs and log messages) are internally consistent.
* man: mention that preset-all is performed during early bootZbigniew Jędrzejewski-Szmek2024-02-081-1/+9
| | | | | | | | The intro of systemd-firstboot is rewritten to make it clearer how it fits into the big picture. Systemd does some machine-id and presets and systemd-firstboot.service is used to interactively fill in the blanks. Closes #22225.
* core: Add %D specifier for $XDG_DATA_HOMEAdrian Vovk2024-01-051-0/+5
| | | | | | | | | | | We already have specifiers that resolve to $XDG_STATE_HOME, and $XDG_CONFIG_HOME. $XDG_DATA_HOME is in a similar vein. It allows units belonging to the user service manager to correctly look into ~/.local/share. I imagine this would be most useful inside of condition checks (i.e. only run a service on session startup if some data is not found in ~/.local/share) or in the inotify monitoring of a .path unit
* man: use same version in public and system ident.David Tardon2023-12-251-1/+1
|
* man: use <simplelist> at one more placeDavid Tardon2023-12-251-11/+13
|
* man: use <simplelist> for 'See also' sectionsDavid Tardon2023-12-231-22/+22
| | | | | This is just a slight markup improvement; there should be no difference in rendering.
* man: use <simplelist> for file lists in synopsisZbigniew Jędrzejewski-Szmek2023-12-151-27/+31
| | | | | | | | | | | | | | | | | | With <para><filename>…</filename></para>, we get a separate "paragraph" for each line, i.e. entries separated by empty lines. This uses up a lot of space and was only done because docbook makes it hard to insert a newline. In some other places, <literallayout> was used, but then we cannot indent the source text (because the whitespace would end up in the final page). We can get the desired result with <simplelist>. With <simplelist> the items are indented in roff output, but not in html output. In some places this looks better then no indentation, and in others it would probably be better to have no indent. But this is a minor issue and we cannot control that. (I didn't convert all spots. There's a bunch of other man pages which have two lines, e.g. an executable and service file, and it doesn't matter there so much.)
* analyze: add "architectures" verb that lists all known architecturesLennart Poettering2023-12-061-0/+4
|
* core: add WantsMountsFor=Luca Boccassi2023-11-291-0/+10
| | | | | | | | This is the equivalent of RequiresMountsFor=, but adds Wants= instead of Requires=. It will be useful for example for the autogenerated systemd-cryptsetup units. Fixes https://github.com/systemd/systemd/issues/11646
* man: document StartLimitIntervalSec=infinityZbigniew Jędrzejewski-Szmek2023-11-151-0/+2
| | | | | | | | | This seems to work as expected. In the issue, doubts were raised whether it works fine with daemon-reload/daemon-reexec, and it seems to work fine. (The property cannot be set via set-property, the dbus property is 'const'. We could relax this, but that'd be a separate feature.) Closes #29574.
* man: more hyperlinks and other fixesZbigniew Jędrzejewski-Szmek2023-11-061-6/+6
| | | | Closes https://github.com/systemd/systemd/issues/29814.
* man/systemd.unit: add PropagatesStopTo= to reverse property tableMike Yuan2023-10-251-5/+14
|
* pid1: add SurviveFinalKillSignal= to skip units on final sigterm/sigkill spreeLuca Boccassi2023-09-281-0/+14
| | | | | | | | | | | Add a new boolean for units, SurviveFinalKillSignal=yes/no. Units that set it will not have their process receive the final sigterm/sigkill in the shutdown phase. This is implemented by checking if a process is part of a cgroup marked with a user.survive_final_kill_signal xattr (or a trusted xattr if we can't set a user one, which were added only in kernel v5.7 and are not supported in CentOS 8).
* condition: add ConditionSecurity=measured-ukiLennart Poettering2023-09-271-5/+61
| | | | | We have various services that should only run in a measured UKI environment. Let's add an explicit high-level check for that.
* man: update version informationAbderrahim Kitouni2023-09-191-20/+72
| | | | | | | | As I noticed a lot of missing information when trying to implement checking for missing info. I reimplemented the version information script to be more robust, and here is the result. Follow up to ec07c3c80b2b1bfa6788500202006ff85f5ae4f4
* man: add version infoAbderrahim Kitouni2023-08-291-13/+95
| | | | | | | | This tries to add information about when each option was added. It goes back to version 183. The version info is included from a separate file to allow generating it, which would allow more control on the formatting of the final output.
* man/systemd.unit: DefaultTimeoutStartSec= -> DefaultDeviceTimeoutSec=Mike Yuan2023-08-041-1/+1
| | | | | | for device unit job timeouts Follow-up for #24044
* Revert "core: add IgnoreOnSoftReboot= unit option"Luca Boccassi2023-07-231-10/+0
| | | | | | The feature is not ready, postpone it This reverts commit b80fc61e8971283606f9cd0a48e31d0f701c82f1.
* core: add IgnoreOnSoftReboot= unit optionLuca Boccassi2023-07-211-0/+10
| | | | | | | | | | | | | | | | | As it says on the tin, configures the unit to survive a soft reboot. Currently all the following options have to be set by hand: Conflicts=reboot.target kexec.target poweroff.target halt.target Before=reboot.target kexec.target poweroff.target halt.target After=sysinit.target basic.target DefaultDependencies=no IgnoreOnIsolate=yes This is not very user friendly. If new default dependencies are added, or new shutdown/reboot types, they also have to be added manually. The new option is much simpler, easy to find, and does the right thing by default.
* man/systemd.unit: document restart behavior on Upholds=Christian Hesse2023-07-071-1/+1
| | | | | Behavior on constantly failing (or oneshot) unit was unclear. Let's document it here.
* unit: add "cvm" option for ConditionSecurityDaniel P. Berrangé2023-07-061-2/+2
| | | | | | | | The "cvm" flag indicates whether the OS is running inside a confidential virtual machine. Related: https://github.com/systemd/systemd/issues/27604 Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
* execute: add support for XDG_STATE_HOME for placing service state data in ↵Lennart Poettering2023-06-281-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | --user mode This adds support for the new XDG_STATE_HOME env var that was added to the xdg basedir spec. Previously, because the basedir spec didn't know the concept we'd alias the backing dir for StateDirectory= to the one for ConfigurationDirectory= when runnin in --user mode. With this change we'll make separate. This brings us various benefits, such as proper "systemctl clean" support, where we can clear service state separately from service configuration, now in user mode too. This does not come without complications: retaining compatibility with older setups is difficult, because we cannot possibly identitfy which files in existing populated config dirs are actually "state" and which one are true" configuration. Hence let's deal with this pragmatically: if we detect that a service that has both dirs configured only has the configuration dir existing, then symlink the state dir to the configuration dir to retain compatibility. This is not great, but it's the only somewhat reasonable way out I can see. Fixes: #25739
* core: Add halt and kexec emergency actionsDaan De Meyer2023-06-221-11/+15
| | | | | Let's complete the picture by adding the missing halt and kexec emergency actions.
* man: document OnSuccessJobMode=Frantisek Sumsal2023-06-061-2/+3
| | | | Introduced in 294446dcb9.
* man: document the soft reboot operationLennart Poettering2023-06-021-21/+28
|
* core/unit: make JoinsNamespaceOf= implies the inverse dependencyYu Watanabe2023-05-261-5/+7
| | | | | | | | | | | | | | | Previously, even if a.service has JoinsNamespaceOf=b.service, the inverse direction of reference was not introduced. Hence, a.service is started earlier than b.service, the namespace will not shared with b.service. Also, even if a.service had the reference to b.service, b.service did not. If b.service is freed earlier, then unit_clear_dependencies() does not clear the reference from a to b, and will cause use-after-free on unit_free() for a.service. Let's make JoinsNamespaceOf=b.service in a.service implies the inverse dependency, i.e. JoinsNamespaceOf=a.service for b.service. Then, we can safely free b.service.
* Revert (partially) "man: Clarify when OnFailure= activates after restarts ↵Mike Yuan2023-05-181-2/+1
| | | | | | | | | (#7646)" This reverts part of commit bd2538b50ba283c9ce39142d5d16d90184a55b90, specifically changes to the description of service state between auto-restarts. Fixes #27594
* unit-file: support UpheldBy= in [Install] settings (adding Upholds= depsMike Yuan2023-05-151-17/+22
| | | | | | from .upholds/) Closes #26896
* man: restore description of ConditionControlGroupController=v1|v2Zbigniew Jędrzejewski-Szmek2023-04-011-5/+14
| | | | | | | | | | We use ConditionControlGroupController=v2 in systemd-oomd.service, and also this condition makes sense in general, so it should be documented. This reverts a part of 6d48c7cf736ced70c1c2fef1e1f03618911d04bc. Deprecated commandline options and v1 controller names were removed from the description.
* man: correct/tweak text about unit name syntaxLennart Poettering2023-03-291-12/+12
| | | | | | | | Unit names can be 255 characters long, not 256. We first say "name prefix" and then continue with "unit prefix". Confusing. Couldn't figure out which term is better hence settled on "unit name prefix".
* docs, man: consistently use comma after "For example"Dmitry V. Levin2023-01-231-1/+1
|
* man: minor correctionsZbigniew Jędrzejewski-Szmek2023-01-221-1/+1
| | | | Two issues that were missed in 8b9f092112ce097dd5c72a58a092c4176458889c.
* virt: Support detection of LMHS SRE guestsNeil Moore2022-12-021-0/+1
|
* man: Add documentation for AssertCredential= (#25178)Steve Ramage2022-10-291-0/+1
| | | | | Fixes #25177. Co-authored-by: Steve Ramage <gitcommits@sjrx.net>
* man: use a list for description of ConditionFirmware=Zbigniew Jędrzejewski-Szmek2022-10-091-27/+32
| | | | | Also reduce confusion of <replaceable> and <literal> and reword things for legibility a bit.
* manager: fix/change evaluation of ConditionFirstBootZbigniew Jędrzejewski-Szmek2022-10-011-5/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The code to evaluate the kernel command line option was busted because it was doing 'return b == !!r' at a point where 'r > 0'. Thus we'd return "true" in both cases: $ SYSTEMD_PROC_CMDLINE=systemd.condition-first-boot build/systemd-analyze condition 'ConditionFirstBoot=true' test.service: ConditionFirstBoot=true succeeded. Conditions succeeded. $ SYSTEMD_PROC_CMDLINE=systemd.condition-first-boot build/systemd-analyze condition 'ConditionFirstBoot=false' test.service: ConditionFirstBoot=false succeeded. Conditions succeeded. We only use 'ConditionFirstBoot=true' in units, so this wasn't noticed. But I think the logic is broken in general: the condition should evaluate as true only during initial boot. If we rerun the units at later points, we should not consider ConditionFirstBoot to be true. Also, the first boot logic is also used in pid1 itself. AFAICT, for two things: in first boot machine-id is initialized transiently (this allows first-boot operations to be restarted if boot fails), and preset-all is executed. But this logic was different and separate from the logic to evaluate ConditionFirstBoot. The distinction is abolished, and the operations in pid1 now use the same logic as ConditionFirstBoot, which means that the kernel command line option is checked, and condition_test_first_boot() just tests whether pid1 thinks we're in first boot. This makes things easier to grok for the user: there's just one condition for "first boot" and it applies to both pid1 and units.
* tree-wide: fix typoYu Watanabe2022-09-241-1/+1
|
* docs: add a note about selectively overriding default dependenciesLuca BRUNO2022-09-201-4/+4
| | | | | | | | | | | | | This documents that explicit `Before=`/`After=` dependencies can be used to selectively override implicit ordering coming from default dependencies. That allows for more granular control compared to the already documented `DefaultDependencies=no` option. The alternative approach came up in a discussion around the ordering of `boot-complete.target`, so this also adds an explicit suggestion in that direction to the "Automatic Boot Assessment" documentation. Ref: https://lists.freedesktop.org/archives/systemd-devel/2022-September/048330.html
* condition: change operator logic to use $= instead of =$ for glob comparisonsLennart Poettering2022-09-011-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | So this is a bit of a bikeshedding thing. But I think we should do this nonetheless, before this is released. Playing around with the glob matches I realized that "=$" is really hard to grep for, since in shell code it's an often seen construct. Also, when reading code I often found myself thinking first that the "$" belongs to the rvalue instead of the operator, in a variable expansion scheme. If we move the $ character to the left hand, I think we are on the safer side, since usually lvalues are much more restricted in character sets than rvalues (at least most programming languages do enforce limits on the character set for identifiers). It makes it much easier to grep for the new operator, and easier to read too. Example: before: ConditionOSRelease=ID=$fedora-* after: ConditionOSRelease=ID$=fedora-*
* condition: change ConditionKernelVersion= so that =/!= mean literal string ↵Lennart Poettering2022-09-011-3/+3
| | | | | | | | | | | | comparison, and ==/<> version comparison The only reason to do this is to ensure uniformity with the other options, that work like this, i.e. ConditionOSRelease= or ConditionSecurity=. This is a compatibility break, but a minor one, given that string comparison and version comparison is mostly the same for equality and inequality.
* condition: allow fnmatch() matches in ConditionKernelVersion=Lennart Poettering2022-09-011-5/+5
| | | | | | This is mostly to make things systematic, and brings no new functionality, as not specifying any operator is identical to prefixing with =$ anyway.
* compare: add two new operators "==" and "<>"Lennart Poettering2022-09-011-29/+33
| | | | | | | | These two operators always indicate ordering comparisons, as opposed to "=" and "!=" which depending on context mean literal string compares. This is useful for ConditionOSRelease= for example, as this means there's now always a way to do version compares.
* condition: allow fnmatch compares for ConditionOSRelease=Lennart Poettering2022-09-011-4/+7
| | | | | We support this for smbios matches, hence do so for /etc/os-release matches too.
* tree-wide: Use "unmet" for condition checks, not "failed"Colin Walters2022-09-011-2/+2
| | | | | | | | | | | | | | | | | | | Often I end up debugging a problem on a system, and I do e.g. `journalctl --grep=failed|error`. The use of the term "failed" for condition checks adds a *lot* of unnecessary noise into this. Now, I know this regexp search isn't precise, but it has proven to be useful to me. I think "failed" is too strong of a term as a baseline, and also just stands out to e.g. humans watching their servers boot or whatever. The term "met condition" is fairly widely used, e.g. https://stackoverflow.com/questions/63751794/what-does-the-condition-is-met-exactly-mean-in-programming-languages Use that instead.
* pid1: extend "ConditionFirmware=" for checking SMBIOS system identification ↵Daniel Braunwarth2022-08-251-4/+18
| | | | information
* Merge pull request #24370 from keszybz/sysusers-equivsLuca Boccassi2022-08-241-1/+1
|\ | | | | Use /bin/bash for root shell and suppress some warnings from sysusers
| * various: try to use DEFAULT_USER_SHELL for root tooZbigniew Jędrzejewski-Szmek2022-08-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | /bin/sh as a shell is punishing. There is no good reason to make the occasional root login unpleasant. Since /bin/sh is usually /bin/bash in compat mode, i.e. if one is available, the other will be too, /bin/bash is almost as good as a default. But to avoid a regression in the situation where /bin/bash (or DEFAULT_USER_SHELL) is not installed, we check with access() and fall back to /bin/sh. This should make this change in behaviour less risky. (FWIW, e.g. Fedora/RHEL use /bin/bash as default for root.) This is a follow-up of sorts for 53350c7bbade8c5f357aa3d1029ef9b2208ea675, which added the default-user-shell option, but most likely with the idea of using /bin/bash less ;) Fixes #24369.
* | Merge pull request #24072 from poettering/remove-cgroupsv1-docsLennart Poettering2022-08-241-16/+5
|\ \ | | | | | | decgroupsv1ification: first steps – remove from docs, and generate warnings
| * | docs: remove documentation about cgroupsv1 settingsLennart Poettering2022-08-231-16/+5
| |/ | | | | | | | | it's legacy. We'll continue to support it in code, but let's simplify the docs a bit, and not mention this legacy stuff anymore.
* / virt: Support detection of Apple Virtualization.framework guestsZhaofeng Li2022-08-241-0/+1
|/