1SYSTEMD.SYNTAX(7)               systemd.syntax               SYSTEMD.SYNTAX(7)
2
3
4

NAME

6       systemd.syntax - General syntax of systemd configuration files
7

INTRODUCTION

9       This page describes the basic principles of configuration files used by
10       systemd(1) and related programs for:
11
12       ·   systemd unit files, see systemd.unit(5), systemd.service(5),
13           systemd.socket(5), systemd.device(5), systemd.mount(5),
14           systemd.automount(5), systemd.swap(5), systemd.target(5),
15           systemd.path(5), systemd.timer(5), systemd.slice(5),
16           systemd.scope(5)
17
18       ·   daemon config files, see systemd-system.conf(5), systemd-
19           user.conf(5), logind.conf(5), journald.conf(5), journal-
20           remote.conf(5), journal-upload.conf(5), systemd-sleep.conf(5),
21           timesyncd.conf(5)
22
23       The syntax is inspired by XDG Desktop Entry Specification[1] .desktop
24       files, which are in turn inspired by Microsoft Windows .ini files.
25
26       Each file is a plain text file divided into sections, with
27       configuration entries in the style key=value. Empty lines and lines
28       starting with "#" or ";" are ignored, which may be used for commenting.
29
30       Lines ending in a backslash are concatenated with the following line
31       while reading and the backslash is replaced by a space character. This
32       may be used to wrap long lines. The limit on line length is very large
33       (currently 1 MB), but it is recommended to avoid such long lines and
34       use multiple directives, variable substitution, or other mechanism as
35       appropriate for the given file type. When a comment line or lines
36       follow a line ending with a backslash, the comment block is ignored, so
37       the continued line is concatenated with whatever follows the comment
38       block.
39
40       Example 1.
41
42           [Section A]
43           KeyOne=value 1
44           KeyTwo=value 2
45
46           # a comment
47
48           [Section B]
49           Setting="something" "some thing" "..."
50           KeyTwo=value 2 \
51                  value 2 continued
52
53           [Section C]
54           KeyThree=value 2\
55           # this line is ignored
56           ; this line is ignored too
57                  value 2 continued
58
59       Various settings are allowed to be specified more than once, in which
60       case the interpretation depends on the setting. Often, multiple
61       settings form a list, and setting to an empty value "resets", which
62       means that previous assignments are ignored. When this is allowed, it
63       is mentioned in the description of the setting. Note that using
64       multiple assignments to the same value makes the file incompatible with
65       parsers for the XDG .desktop file format.
66

NOTES

68        1. XDG Desktop Entry Specification
69           http://standards.freedesktop.org/desktop-entry-spec/latest/
70
71
72
73systemd 239                                                  SYSTEMD.SYNTAX(7)
Impressum