| 1 |
# SOME DESCRIPTIVE TITLE |
| 2 |
# Copyright (C) YEAR Free Software Foundation, Inc. |
| 3 |
# This file is distributed under the same license as the PACKAGE package. |
| 4 |
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. |
| 5 |
# |
| 6 |
#, fuzzy |
| 7 |
msgid "" |
| 8 |
msgstr "" |
| 9 |
"Project-Id-Version: PACKAGE VERSION\n" |
| 10 |
"POT-Creation-Date: 2026-06-05 06:21+0200\n" |
| 11 |
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
| 12 |
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
| 13 |
"Language-Team: LANGUAGE <[email protected]>\n" |
| 14 |
"Language: \n" |
| 15 |
"MIME-Version: 1.0\n" |
| 16 |
"Content-Type: text/plain; charset=UTF-8\n" |
| 17 |
"Content-Transfer-Encoding: 8bit\n" |
| 18 |
|
| 19 |
#. type: TH |
| 20 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 21 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 22 |
#, no-wrap |
| 23 |
msgid "DAEMON" |
| 24 |
msgstr "" |
| 25 |
|
| 26 |
#. type: TH |
| 27 |
#: archlinux |
| 28 |
#, no-wrap |
| 29 |
msgid "systemd 260.2" |
| 30 |
msgstr "" |
| 31 |
|
| 32 |
#. type: TH |
| 33 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 34 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 35 |
#, no-wrap |
| 36 |
msgid "daemon" |
| 37 |
msgstr "" |
| 38 |
|
| 39 |
#. ----------------------------------------------------------------- |
| 40 |
#. * MAIN CONTENT STARTS HERE * |
| 41 |
#. ----------------------------------------------------------------- |
| 42 |
#. type: SH |
| 43 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 44 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 45 |
#, no-wrap |
| 46 |
msgid "NAME" |
| 47 |
msgstr "" |
| 48 |
|
| 49 |
#. type: Plain text |
| 50 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 51 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 52 |
msgid "daemon - Writing and packaging system daemons" |
| 53 |
msgstr "" |
| 54 |
|
| 55 |
#. type: SH |
| 56 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 57 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 58 |
#, no-wrap |
| 59 |
msgid "DESCRIPTION" |
| 60 |
msgstr "" |
| 61 |
|
| 62 |
#. type: Plain text |
| 63 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 64 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 65 |
msgid "" |
| 66 |
"A daemon is a service process that runs in the background and supervises the " |
| 67 |
"system or provides functionality to other processes\\&. Traditionally, " |
| 68 |
"daemons are implemented following a scheme originating in SysV Unix\\&. " |
| 69 |
"Modern daemons should follow a simpler yet more powerful scheme (here called " |
| 70 |
"\"new-style\" daemons), as implemented by B<systemd>(1)\\&. This manual page " |
| 71 |
"covers both schemes, and in particular includes recommendations for daemons " |
| 72 |
"that shall be included in the systemd init system\\&." |
| 73 |
msgstr "" |
| 74 |
|
| 75 |
#. type: SS |
| 76 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 77 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 78 |
#, no-wrap |
| 79 |
msgid "SysV Daemons" |
| 80 |
msgstr "" |
| 81 |
|
| 82 |
#. type: Plain text |
| 83 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 84 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 85 |
msgid "" |
| 86 |
"When a traditional SysV daemon starts, it should execute the following steps " |
| 87 |
"as part of the initialization\\&. Note that these steps are unnecessary for " |
| 88 |
"new-style daemons (see below), and should only be implemented if " |
| 89 |
"compatibility with SysV is essential\\&." |
| 90 |
msgstr "" |
| 91 |
|
| 92 |
#. type: Plain text |
| 93 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 94 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 95 |
msgid "" |
| 96 |
"Close all open file descriptors except standard input, output, and error " |
| 97 |
"(i\\&.e\\&. the first three file descriptors 0, 1, 2)\\&. This ensures that " |
| 98 |
"no accidentally passed file descriptor stays around in the daemon " |
| 99 |
"process\\&. On Linux, this is best implemented by iterating through /proc/" |
| 100 |
"self/fd, with a fallback of iterating from file descriptor 3 to the value " |
| 101 |
"returned by B<getrlimit()> for B<RLIMIT_NOFILE>\\&." |
| 102 |
msgstr "" |
| 103 |
|
| 104 |
#. type: Plain text |
| 105 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 106 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 107 |
msgid "" |
| 108 |
"Reset all signal handlers to their default\\&. This is best done by " |
| 109 |
"iterating through the available signals up to the limit of B<_NSIG> and " |
| 110 |
"resetting them to B<SIG_DFL>\\&." |
| 111 |
msgstr "" |
| 112 |
|
| 113 |
#. type: Plain text |
| 114 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 115 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 116 |
msgid "Reset the signal mask using B<sigprocmask()>\\&." |
| 117 |
msgstr "" |
| 118 |
|
| 119 |
#. type: Plain text |
| 120 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 121 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 122 |
msgid "" |
| 123 |
"Sanitize the environment block, removing or resetting environment variables " |
| 124 |
"that might negatively impact daemon runtime\\&." |
| 125 |
msgstr "" |
| 126 |
|
| 127 |
#. type: Plain text |
| 128 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 129 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 130 |
msgid "Call B<fork()>, to create a background process\\&." |
| 131 |
msgstr "" |
| 132 |
|
| 133 |
#. type: Plain text |
| 134 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 135 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 136 |
msgid "" |
| 137 |
"In the child, call B<setsid()> to detach from any terminal and create an " |
| 138 |
"independent session\\&." |
| 139 |
msgstr "" |
| 140 |
|
| 141 |
#. type: Plain text |
| 142 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 143 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 144 |
msgid "" |
| 145 |
"In the child, call B<fork()> again, to ensure that the daemon can never re-" |
| 146 |
"acquire a terminal again\\&. (This is relevant if the program \\(em and all " |
| 147 |
"its dependencies \\(em does not carefully specify `O_NOCTTY` on each and " |
| 148 |
"every single `open()` call that might potentially open a TTY device node\\&.)" |
| 149 |
msgstr "" |
| 150 |
|
| 151 |
#. type: Plain text |
| 152 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 153 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 154 |
msgid "" |
| 155 |
"Call B<exit()> in the first child, so that only the second child (the actual " |
| 156 |
"daemon process) stays around\\&. This ensures that the daemon process is re-" |
| 157 |
"parented to init/PID 1, as all daemons should be\\&." |
| 158 |
msgstr "" |
| 159 |
|
| 160 |
#. type: Plain text |
| 161 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 162 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 163 |
msgid "" |
| 164 |
"In the daemon process, connect /dev/null to standard input, output, and " |
| 165 |
"error\\&." |
| 166 |
msgstr "" |
| 167 |
|
| 168 |
#. type: Plain text |
| 169 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 170 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 171 |
msgid "" |
| 172 |
"In the daemon process, reset the umask to 0, so that the file modes passed " |
| 173 |
"to B<open()>, B<mkdir()> and suchlike directly control the access mode of " |
| 174 |
"the created files and directories\\&." |
| 175 |
msgstr "" |
| 176 |
|
| 177 |
#. type: Plain text |
| 178 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 179 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 180 |
msgid "" |
| 181 |
"In the daemon process, change the current directory to the root directory " |
| 182 |
"(/), in order to avoid that the daemon involuntarily blocks mount points " |
| 183 |
"from being unmounted\\&." |
| 184 |
msgstr "" |
| 185 |
|
| 186 |
#. type: Plain text |
| 187 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 188 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 189 |
msgid "" |
| 190 |
"In the daemon process, write the daemon PID (as returned by B<getpid()>) to " |
| 191 |
"a PID file, for example /run/foobar\\&.pid (for a hypothetical daemon " |
| 192 |
"\"foobar\") to ensure that the daemon cannot be started more than once\\&. " |
| 193 |
"This must be implemented in race-free fashion so that the PID file is only " |
| 194 |
"updated when it is verified at the same time that the PID previously stored " |
| 195 |
"in the PID file no longer exists or belongs to a foreign process\\&." |
| 196 |
msgstr "" |
| 197 |
|
| 198 |
#. type: Plain text |
| 199 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 200 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 201 |
msgid "In the daemon process, drop privileges, if possible and applicable\\&." |
| 202 |
msgstr "" |
| 203 |
|
| 204 |
#. type: Plain text |
| 205 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 206 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 207 |
msgid "" |
| 208 |
"From the daemon process, notify the original process started that " |
| 209 |
"initialization is complete\\&. This can be implemented via an unnamed pipe " |
| 210 |
"or similar communication channel that is created before the first B<fork()> " |
| 211 |
"and hence available in both the original and the daemon process\\&." |
| 212 |
msgstr "" |
| 213 |
|
| 214 |
#. type: Plain text |
| 215 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 216 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 217 |
msgid "" |
| 218 |
"Call B<exit()> in the original process\\&. The process that invoked the " |
| 219 |
"daemon must be able to rely on that this B<exit()> happens after " |
| 220 |
"initialization is complete and all external communication channels are " |
| 221 |
"established and accessible\\&." |
| 222 |
msgstr "" |
| 223 |
|
| 224 |
#. type: Plain text |
| 225 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 226 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 227 |
msgid "" |
| 228 |
"The BSD B<daemon()> function should not be used, as it implements only a " |
| 229 |
"subset of these steps\\&." |
| 230 |
msgstr "" |
| 231 |
|
| 232 |
#. type: Plain text |
| 233 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 234 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 235 |
msgid "" |
| 236 |
"A daemon that needs to provide compatibility with SysV systems should " |
| 237 |
"implement the scheme pointed out above\\&. However, it is recommended to " |
| 238 |
"make this behavior optional and configurable via a command line argument to " |
| 239 |
"ease debugging as well as to simplify integration into systems using " |
| 240 |
"systemd\\&." |
| 241 |
msgstr "" |
| 242 |
|
| 243 |
#. type: SS |
| 244 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 245 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 246 |
#, no-wrap |
| 247 |
msgid "New-Style Daemons" |
| 248 |
msgstr "" |
| 249 |
|
| 250 |
#. type: Plain text |
| 251 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 252 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 253 |
msgid "" |
| 254 |
"Modern services for Linux should be implemented as new-style daemons\\&. " |
| 255 |
"This makes it easier to supervise and control them at runtime and simplifies " |
| 256 |
"their implementation\\&." |
| 257 |
msgstr "" |
| 258 |
|
| 259 |
#. type: Plain text |
| 260 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 261 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 262 |
msgid "" |
| 263 |
"For developing a new-style daemon, none of the initialization steps " |
| 264 |
"recommended for SysV daemons need to be implemented\\&. New-style init " |
| 265 |
"systems such as systemd make all of them redundant\\&. Moreover, since some " |
| 266 |
"of these steps interfere with process monitoring, file descriptor passing, " |
| 267 |
"and other functionality of the service manager, it is recommended not to " |
| 268 |
"execute them when run as new-style service\\&." |
| 269 |
msgstr "" |
| 270 |
|
| 271 |
#. type: Plain text |
| 272 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 273 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 274 |
msgid "" |
| 275 |
"Note that new-style init systems guarantee execution of daemon processes in " |
| 276 |
"a clean process context: it is guaranteed that the environment block is " |
| 277 |
"sanitized, that the signal handlers and mask is reset and that no left-over " |
| 278 |
"file descriptors are passed\\&. Daemons will be executed in their own " |
| 279 |
"session, with standard input connected to /dev/null and standard output/" |
| 280 |
"error connected to the B<systemd-journald.service>(8) logging service, " |
| 281 |
"unless otherwise configured\\&. The umask is reset\\&." |
| 282 |
msgstr "" |
| 283 |
|
| 284 |
#. type: Plain text |
| 285 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 286 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 287 |
msgid "It is recommended for new-style daemons to implement the following:" |
| 288 |
msgstr "" |
| 289 |
|
| 290 |
#. type: Plain text |
| 291 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 292 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 293 |
msgid "" |
| 294 |
"If applicable, the daemon should notify the service manager about startup " |
| 295 |
"completion or status updates via the B<sd_notify>(3) interface, in " |
| 296 |
"particular I<READY=1> and I<STATUS=\\&...>\\&." |
| 297 |
msgstr "" |
| 298 |
|
| 299 |
#. type: Plain text |
| 300 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 301 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 302 |
msgid "" |
| 303 |
"If B<SIGTERM> is received, shut down the daemon and exit cleanly\\&. A " |
| 304 |
"I<STOPPING=1> notification should be sent via B<sd_notify>(3)\\&." |
| 305 |
msgstr "" |
| 306 |
|
| 307 |
#. type: Plain text |
| 308 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 309 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 310 |
msgid "" |
| 311 |
"If B<SIGHUP> is received, reload the configuration files, if this " |
| 312 |
"applies\\&. This should be combined with notifications via B<sd_notify>(3): " |
| 313 |
"I<RELOADING=1> and I<READY=1>\\&." |
| 314 |
msgstr "" |
| 315 |
|
| 316 |
#. type: Plain text |
| 317 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 318 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 319 |
msgid "" |
| 320 |
"Provide a correct exit code from the main daemon process, as this is used by " |
| 321 |
"the service manager to detect service errors and problems\\&. It is " |
| 322 |
"recommended to follow the exit code scheme as defined in the \\m[blue]B<LSB " |
| 323 |
"recommendations for SysV init scripts>\\m[]\\&\\s-2\\u[1]\\d\\s+2\\&." |
| 324 |
msgstr "" |
| 325 |
|
| 326 |
#. type: Plain text |
| 327 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 328 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 329 |
msgid "" |
| 330 |
"If possible and applicable, expose the daemon\\*(Aqs control interface via " |
| 331 |
"the D-Bus IPC system and grab a bus name as last step of initialization\\&." |
| 332 |
msgstr "" |
| 333 |
|
| 334 |
#. type: Plain text |
| 335 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 336 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 337 |
msgid "" |
| 338 |
"For integration in systemd, provide a \\&.service unit file that carries " |
| 339 |
"information about starting, stopping and otherwise maintaining the " |
| 340 |
"daemon\\&. See B<systemd.service>(5) for details\\&." |
| 341 |
msgstr "" |
| 342 |
|
| 343 |
#. type: Plain text |
| 344 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 345 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 346 |
msgid "" |
| 347 |
"As much as possible, rely on the service manager\\*(Aqs functionality to " |
| 348 |
"limit the access of the daemon to files, services, and other resources, " |
| 349 |
"i\\&.e\\&. in the case of systemd, rely on systemd\\*(Aqs resource limit " |
| 350 |
"control instead of implementing your own, rely on systemd\\*(Aqs privilege " |
| 351 |
"dropping code instead of implementing it in the daemon, and so on\\&. See " |
| 352 |
"B<systemd.exec>(5) for the available controls\\&." |
| 353 |
msgstr "" |
| 354 |
|
| 355 |
#. type: Plain text |
| 356 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 357 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 358 |
msgid "" |
| 359 |
"If D-Bus is used, make your daemon bus-activatable by supplying a D-Bus " |
| 360 |
"service activation configuration file\\&. This has multiple advantages: your " |
| 361 |
"daemon may be started lazily on-demand; it may be started in parallel to " |
| 362 |
"other daemons requiring it \\(em which maximizes parallelization and boot-up " |
| 363 |
"speed; your daemon can be restarted on failure without losing any bus " |
| 364 |
"requests, as the bus queues requests for activatable services\\&. See below " |
| 365 |
"for details\\&." |
| 366 |
msgstr "" |
| 367 |
|
| 368 |
#. type: Plain text |
| 369 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 370 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 371 |
msgid "" |
| 372 |
"If your daemon provides services to other local processes or remote clients " |
| 373 |
"via a socket, it should be made socket-activatable following the scheme " |
| 374 |
"pointed out below\\&. Like D-Bus activation, this enables on-demand starting " |
| 375 |
"of services as well as it allows improved parallelization of service start-" |
| 376 |
"up\\&. Also, for state-less protocols (such as syslog, DNS), a daemon " |
| 377 |
"implementing socket-based activation can be restarted without losing a " |
| 378 |
"single request\\&. See below for details\\&." |
| 379 |
msgstr "" |
| 380 |
|
| 381 |
#. type: Plain text |
| 382 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 383 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 384 |
msgid "" |
| 385 |
"If the service opens sockets or other files on it own, and those file " |
| 386 |
"descriptors shall survive a restart, the daemon should store them in the " |
| 387 |
"service manager via B<sd_notify>(3) with I<FDSTORE=1>\\&." |
| 388 |
msgstr "" |
| 389 |
|
| 390 |
#. type: Plain text |
| 391 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 392 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 393 |
msgid "" |
| 394 |
"Instead of using the B<syslog()> call to log directly to the system syslog " |
| 395 |
"service, a new-style daemon may choose to simply log to standard error via " |
| 396 |
"B<fprintf()>, which is then forwarded to syslog\\&. If log levels are " |
| 397 |
"necessary, these can be encoded by prefixing individual log lines with " |
| 398 |
"strings like \"E<lt>4E<gt>\" (for log level 4 \"WARNING\" in the syslog " |
| 399 |
"priority scheme), following a similar style as the Linux kernel\\*(Aqs " |
| 400 |
"B<printk()> level system\\&. For details, see B<sd-daemon>(3) and " |
| 401 |
"B<systemd.exec>(5)\\&." |
| 402 |
msgstr "" |
| 403 |
|
| 404 |
#. type: Plain text |
| 405 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 406 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 407 |
msgid "" |
| 408 |
"As new-style daemons are invoked without a controlling TTY (but as their own " |
| 409 |
"session leaders) care should be taken to always specify B<O_NOCTTY> on " |
| 410 |
"B<open>(2) calls that possibly reference a TTY device node, so that no " |
| 411 |
"controlling TTY is accidentally acquired\\&." |
| 412 |
msgstr "" |
| 413 |
|
| 414 |
#. type: Plain text |
| 415 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 416 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 417 |
msgid "" |
| 418 |
"These recommendations are similar but not identical to the \\m[blue]B<Apple " |
| 419 |
"MacOS X Daemon Requirements>\\m[]\\&\\s-2\\u[2]\\d\\s+2\\&." |
| 420 |
msgstr "" |
| 421 |
|
| 422 |
#. type: SH |
| 423 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 424 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 425 |
#, no-wrap |
| 426 |
msgid "ACTIVATION" |
| 427 |
msgstr "" |
| 428 |
|
| 429 |
#. type: Plain text |
| 430 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 431 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 432 |
msgid "" |
| 433 |
"New-style init systems provide multiple additional mechanisms to activate " |
| 434 |
"services, as detailed below\\&. It is common that services are configured to " |
| 435 |
"be activated via more than one mechanism at the same time\\&. An example for " |
| 436 |
"systemd: bluetoothd\\&.service might get activated either when Bluetooth " |
| 437 |
"hardware is plugged in, or when an application accesses its programming " |
| 438 |
"interfaces via D-Bus\\&. Or, a print server daemon might get activated when " |
| 439 |
"traffic arrives at an IPP port, or when a printer is plugged in, or when a " |
| 440 |
"file is queued in the printer spool directory\\&. Even for services that are " |
| 441 |
"intended to be started on system bootup unconditionally, it is a good idea " |
| 442 |
"to implement some of the various activation schemes outlined below, in order " |
| 443 |
"to maximize parallelization\\&. If a daemon implements a D-Bus service or " |
| 444 |
"listening socket, implementing the full bus and socket activation scheme " |
| 445 |
"allows starting of the daemon with its clients in parallel (which speeds up " |
| 446 |
"boot-up), since all its communication channels are established already, and " |
| 447 |
"no request is lost because client requests will be queued by the bus system " |
| 448 |
"(in case of D-Bus) or the kernel (in case of sockets) until the activation " |
| 449 |
"is completed\\&." |
| 450 |
msgstr "" |
| 451 |
|
| 452 |
#. type: SS |
| 453 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 454 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 455 |
#, no-wrap |
| 456 |
msgid "Activation on Boot" |
| 457 |
msgstr "" |
| 458 |
|
| 459 |
#. type: Plain text |
| 460 |
#: archlinux debian-unstable fedora-rawhide opensuse-tumbleweed |
| 461 |
msgid "" |
| 462 |
"Old-style daemons are usually activated exclusively on boot (and manually by " |
| 463 |
"the administrator) via SysV init scripts, as detailed in the \\m[blue]B<LSB " |
| 464 |
"Linux Standard Base Core Specification>\\m[]\\&\\s-2\\u[1]\\d\\s+2\\&. Among " |
| 465 |
"other issues, SysV init scripts have the disadvantage of involving shell " |
| 466 |
"scripts in the boot process\\&. Support for init scripts has been phased out " |
| 467 |
"in modern Linux init systems, and should not be relied upon\\&. New-style " |
| 468 |
"init systems generally use updated versions of activation, both during boot-" |
| 469 |
"up and during runtime and using more minimal service description files\\&." |
| 470 |
msgstr "" |
| 471 |
|
| 472 |
#. type: Plain text |
| 473 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 474 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 475 |
msgid "" |
| 476 |
"In systemd, if the developer or administrator wants to make sure that a " |
| 477 |
"service or other unit is activated automatically on boot, it is recommended " |
| 478 |
"to place a symlink to the unit file in the \\&.wants/ directory of either " |
| 479 |
"multi-user\\&.target or graphical\\&.target, which are normally used as boot " |
| 480 |
"targets at system startup\\&. See B<systemd.unit>(5) for details about the " |
| 481 |
"\\&.wants/ directories, and B<systemd.special>(7) for details about the two " |
| 482 |
"boot targets\\&." |
| 483 |
msgstr "" |
| 484 |
|
| 485 |
#. type: SS |
| 486 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 487 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 488 |
#, no-wrap |
| 489 |
msgid "Socket-Based Activation" |
| 490 |
msgstr "" |
| 491 |
|
| 492 |
#. type: Plain text |
| 493 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 494 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 495 |
msgid "" |
| 496 |
"In order to maximize the possible parallelization and robustness and " |
| 497 |
"simplify configuration and development, it is recommended for all new-style " |
| 498 |
"daemons that communicate via listening sockets to use socket-based " |
| 499 |
"activation\\&. In a socket-based activation scheme, the creation and binding " |
| 500 |
"of the listening socket as primary communication channel of daemons to local " |
| 501 |
"(and sometimes remote) clients is moved out of the daemon code and into the " |
| 502 |
"service manager\\&. Based on per-daemon configuration, the service manager " |
| 503 |
"installs the sockets and then hands them off to the spawned process as soon " |
| 504 |
"as the respective daemon is to be started\\&. Optionally, activation of the " |
| 505 |
"service can be delayed until the first inbound traffic arrives at the socket " |
| 506 |
"to implement on-demand activation of daemons\\&. However, the primary " |
| 507 |
"advantage of this scheme is that all providers and all consumers of the " |
| 508 |
"sockets can be started in parallel as soon as all sockets are " |
| 509 |
"established\\&. In addition to that, daemons can be restarted with losing " |
| 510 |
"only a minimal number of client transactions, or even any client request at " |
| 511 |
"all (the latter is particularly true for state-less protocols, such as DNS " |
| 512 |
"or syslog), because the socket stays bound and accessible during the " |
| 513 |
"restart, and all requests are queued while the daemon cannot process them\\&." |
| 514 |
msgstr "" |
| 515 |
|
| 516 |
#. type: Plain text |
| 517 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 518 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 519 |
msgid "" |
| 520 |
"New-style daemons which support socket activation must be able to receive " |
| 521 |
"their sockets from the service manager instead of creating and binding them " |
| 522 |
"themselves\\&. For details about the programming interfaces for this scheme " |
| 523 |
"provided by systemd, see B<sd_listen_fds>(3) and B<sd-daemon>(3)\\&. For " |
| 524 |
"details about porting existing daemons to socket-based activation, see " |
| 525 |
"below\\&. With minimal effort, it is possible to implement socket-based " |
| 526 |
"activation in addition to traditional internal socket creation in the same " |
| 527 |
"codebase in order to support both new-style and old-style init systems from " |
| 528 |
"the same daemon binary\\&." |
| 529 |
msgstr "" |
| 530 |
|
| 531 |
#. type: Plain text |
| 532 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 533 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 534 |
msgid "" |
| 535 |
"systemd implements socket-based activation via \\&.socket units, which are " |
| 536 |
"described in B<systemd.socket>(5)\\&. When configuring socket units for " |
| 537 |
"socket-based activation, it is essential that all listening sockets are " |
| 538 |
"pulled in by the special target unit sockets\\&.target\\&. It is recommended " |
| 539 |
"to place a I<WantedBy=sockets\\&.target> directive in the [Install] section " |
| 540 |
"to automatically add such a dependency on installation of a socket unit\\&. " |
| 541 |
"Unless I<DefaultDependencies=no> is set, the necessary ordering dependencies " |
| 542 |
"are implicitly created for all socket units\\&. For more information about " |
| 543 |
"sockets\\&.target, see B<systemd.special>(7)\\&. It is not necessary or " |
| 544 |
"recommended to place any additional dependencies on socket units (for " |
| 545 |
"example from multi-user\\&.target or suchlike) when one is installed in " |
| 546 |
"sockets\\&.target\\&." |
| 547 |
msgstr "" |
| 548 |
|
| 549 |
#. type: SS |
| 550 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 551 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 552 |
#, no-wrap |
| 553 |
msgid "Bus-Based Activation" |
| 554 |
msgstr "" |
| 555 |
|
| 556 |
#. type: Plain text |
| 557 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 558 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 559 |
msgid "" |
| 560 |
"When the D-Bus IPC system is used for communication with clients, new-style " |
| 561 |
"daemons should use bus activation so that they are automatically activated " |
| 562 |
"when a client application accesses their IPC interfaces\\&. This is " |
| 563 |
"configured in D-Bus service files (not to be confused with systemd service " |
| 564 |
"unit files!)\\&. To ensure that D-Bus uses systemd to start-up and maintain " |
| 565 |
"the daemon, use the I<SystemdService=> directive in these service files to " |
| 566 |
"configure the matching systemd service for a D-Bus service\\&. e\\&.g\\&.: " |
| 567 |
"For a D-Bus service whose D-Bus activation file is named " |
| 568 |
"org\\&.freedesktop\\&.RealtimeKit\\&.service, make sure to set " |
| 569 |
"I<SystemdService=rtkit-daemon\\&.service> in that file to bind it to the " |
| 570 |
"systemd service rtkit-daemon\\&.service\\&. This is needed to make sure that " |
| 571 |
"the daemon is started in a race-free fashion when activated via multiple " |
| 572 |
"mechanisms simultaneously\\&." |
| 573 |
msgstr "" |
| 574 |
|
| 575 |
#. type: SS |
| 576 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 577 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 578 |
#, no-wrap |
| 579 |
msgid "Device-Based Activation" |
| 580 |
msgstr "" |
| 581 |
|
| 582 |
#. type: Plain text |
| 583 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 584 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 585 |
msgid "" |
| 586 |
"Often, daemons that manage a particular type of hardware should be activated " |
| 587 |
"only when the hardware of the respective kind is plugged in or otherwise " |
| 588 |
"becomes available\\&. In a new-style init system, it is possible to bind " |
| 589 |
"activation to hardware plug/unplug events\\&. In systemd, kernel devices " |
| 590 |
"appearing in the sysfs/udev device tree can be exposed as units if they are " |
| 591 |
"tagged with the string \"systemd\"\\&. Like any other kind of unit, they may " |
| 592 |
"then pull in other units when activated (i\\&.e\\&. plugged in) and thus " |
| 593 |
"implement device-based activation\\&. systemd dependencies may be encoded in " |
| 594 |
"the udev database via the I<SYSTEMD_WANTS=> property\\&. See " |
| 595 |
"B<systemd.device>(5) for details\\&. Often, it is nicer to pull in services " |
| 596 |
"from devices only indirectly via dedicated targets\\&. Example: Instead of " |
| 597 |
"pulling in bluetoothd\\&.service from all the various bluetooth dongles and " |
| 598 |
"other hardware available, pull in bluetooth\\&.target from them and " |
| 599 |
"bluetoothd\\&.service from that target\\&. This provides for nicer " |
| 600 |
"abstraction and gives administrators the option to enable " |
| 601 |
"bluetoothd\\&.service via controlling a bluetooth\\&.target\\&.wants/ " |
| 602 |
"symlink uniformly with a command like B<enable> of B<systemctl>(1) instead " |
| 603 |
"of manipulating the udev ruleset\\&." |
| 604 |
msgstr "" |
| 605 |
|
| 606 |
#. type: SS |
| 607 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 608 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 609 |
#, no-wrap |
| 610 |
msgid "Path-Based Activation" |
| 611 |
msgstr "" |
| 612 |
|
| 613 |
#. type: Plain text |
| 614 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 615 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 616 |
msgid "" |
| 617 |
"Often, runtime of daemons processing spool files or directories (such as a " |
| 618 |
"printing system) can be delayed until these file system objects change " |
| 619 |
"state, or become non-empty\\&. New-style init systems provide a way to bind " |
| 620 |
"service activation to file system changes\\&. systemd implements this scheme " |
| 621 |
"via path-based activation configured in \\&.path units, as outlined in " |
| 622 |
"B<systemd.path>(5)\\&." |
| 623 |
msgstr "" |
| 624 |
|
| 625 |
#. type: SS |
| 626 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 627 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 628 |
#, no-wrap |
| 629 |
msgid "Timer-Based Activation" |
| 630 |
msgstr "" |
| 631 |
|
| 632 |
#. type: Plain text |
| 633 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 634 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 635 |
msgid "" |
| 636 |
"Some daemons that implement clean-up jobs that are intended to be executed " |
| 637 |
"in regular intervals benefit from timer-based activation\\&. In systemd, " |
| 638 |
"this is implemented via \\&.timer units, as described in " |
| 639 |
"B<systemd.timer>(5)\\&." |
| 640 |
msgstr "" |
| 641 |
|
| 642 |
#. type: SS |
| 643 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 644 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 645 |
#, no-wrap |
| 646 |
msgid "Other Forms of Activation" |
| 647 |
msgstr "" |
| 648 |
|
| 649 |
#. type: Plain text |
| 650 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 651 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 652 |
msgid "" |
| 653 |
"Other forms of activation have been suggested and implemented in some " |
| 654 |
"systems\\&. However, there are often simpler or better alternatives, or they " |
| 655 |
"can be put together of combinations of the schemes above\\&. Example: " |
| 656 |
"Sometimes, it appears useful to start daemons or \\&.socket units when a " |
| 657 |
"specific IP address is configured on a network interface, because network " |
| 658 |
"sockets shall be bound to the address\\&. However, an alternative to " |
| 659 |
"implement this is by utilizing the Linux B<IP_FREEBIND>/B<IPV6_FREEBIND> " |
| 660 |
"socket option, as accessible via I<FreeBind=yes> in systemd socket files " |
| 661 |
"(see B<systemd.socket>(5) for details)\\&. This option, when enabled, " |
| 662 |
"allows sockets to be bound to a non-local, not configured IP address, and " |
| 663 |
"hence allows bindings to a particular IP address before it actually becomes " |
| 664 |
"available, making such an explicit dependency to the configured address " |
| 665 |
"redundant\\&. Another often suggested trigger for service activation is low " |
| 666 |
"system load\\&. However, here too, a more convincing approach might be to " |
| 667 |
"make proper use of features of the operating system, in particular, the CPU " |
| 668 |
"or I/O scheduler of Linux\\&. Instead of scheduling jobs from userspace " |
| 669 |
"based on monitoring the OS scheduler, it is advisable to leave the " |
| 670 |
"scheduling of processes to the OS scheduler itself\\&. systemd provides fine-" |
| 671 |
"grained access to the CPU and I/O schedulers\\&. If a process executed by " |
| 672 |
"the service manager shall not negatively impact the amount of CPU or I/O " |
| 673 |
"bandwidth available to other processes, it should be configured with " |
| 674 |
"I<CPUSchedulingPolicy=idle> and/or I<IOSchedulingClass=idle>\\&. Optionally, " |
| 675 |
"this may be combined with timer-based activation to schedule background jobs " |
| 676 |
"during runtime and with minimal impact on the system, and remove it from the " |
| 677 |
"boot phase itself\\&." |
| 678 |
msgstr "" |
| 679 |
|
| 680 |
#. type: SH |
| 681 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 682 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 683 |
#, no-wrap |
| 684 |
msgid "INTEGRATION WITH SYSTEMD" |
| 685 |
msgstr "" |
| 686 |
|
| 687 |
#. type: SS |
| 688 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 689 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 690 |
#, no-wrap |
| 691 |
msgid "Writing systemd Unit Files" |
| 692 |
msgstr "" |
| 693 |
|
| 694 |
#. type: Plain text |
| 695 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 696 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 697 |
msgid "" |
| 698 |
"When writing systemd unit files, it is recommended to consider the following " |
| 699 |
"suggestions:" |
| 700 |
msgstr "" |
| 701 |
|
| 702 |
#. type: Plain text |
| 703 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 704 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 705 |
msgid "" |
| 706 |
"If possible, do not use the I<Type=forking> setting in service files\\&. But " |
| 707 |
"if you do, make sure to set the PID file path using I<PIDFile=>\\&. See " |
| 708 |
"B<systemd.service>(5) for details\\&." |
| 709 |
msgstr "" |
| 710 |
|
| 711 |
#. type: Plain text |
| 712 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 713 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 714 |
msgid "" |
| 715 |
"If your daemon registers a D-Bus name on the bus, make sure to use " |
| 716 |
"I<Type=dbus> in the service file if possible\\&." |
| 717 |
msgstr "" |
| 718 |
|
| 719 |
#. type: Plain text |
| 720 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 721 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 722 |
msgid "" |
| 723 |
"Make sure to set a good human-readable description string with " |
| 724 |
"I<Description=>\\&." |
| 725 |
msgstr "" |
| 726 |
|
| 727 |
#. type: Plain text |
| 728 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 729 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 730 |
msgid "" |
| 731 |
"Do not disable I<DefaultDependencies=>, unless you really know what you do " |
| 732 |
"and your unit is involved in early boot or late system shutdown\\&." |
| 733 |
msgstr "" |
| 734 |
|
| 735 |
#. type: Plain text |
| 736 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 737 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 738 |
msgid "" |
| 739 |
"Normally, little if any dependencies should need to be defined " |
| 740 |
"explicitly\\&. However, if you do configure explicit dependencies, only " |
| 741 |
"refer to unit names listed on B<systemd.special>(7) or names introduced by " |
| 742 |
"your own package to keep the unit file operating system-independent\\&." |
| 743 |
msgstr "" |
| 744 |
|
| 745 |
#. type: Plain text |
| 746 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 747 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 748 |
msgid "" |
| 749 |
"Make sure to include an [Install] section including installation information " |
| 750 |
"for the unit file\\&. See B<systemd.unit>(5) for details\\&. To activate " |
| 751 |
"your service on boot, make sure to add a I<WantedBy=multi-user\\&.target> or " |
| 752 |
"I<WantedBy=graphical\\&.target> directive\\&. To activate your socket on " |
| 753 |
"boot, make sure to add I<WantedBy=sockets\\&.target>\\&. Usually, you also " |
| 754 |
"want to make sure that when your service is installed, your socket is " |
| 755 |
"installed too, hence add I<Also=foo\\&.socket> in your service file " |
| 756 |
"foo\\&.service, for a hypothetical program foo\\&." |
| 757 |
msgstr "" |
| 758 |
|
| 759 |
#. type: SS |
| 760 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 761 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 762 |
#, no-wrap |
| 763 |
msgid "Installing systemd Service Files" |
| 764 |
msgstr "" |
| 765 |
|
| 766 |
#. type: Plain text |
| 767 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 768 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 769 |
msgid "" |
| 770 |
"At the build installation time (e\\&.g\\&. B<make install> during package " |
| 771 |
"build), packages are recommended to install their systemd unit files in the " |
| 772 |
"directory returned by B<pkg-config systemd --variable=systemdsystemunitdir> " |
| 773 |
"(for system services) or B<pkg-config systemd --variable=systemduserunitdir> " |
| 774 |
"(for user services)\\&. This will make the services available in the system " |
| 775 |
"on explicit request but not activate them automatically during boot\\&. " |
| 776 |
"Optionally, during package installation (e\\&.g\\&. B<rpm -i> by the " |
| 777 |
"administrator), symlinks should be created in the systemd configuration " |
| 778 |
"directories via the B<enable> command of the B<systemctl>(1) tool to " |
| 779 |
"activate them automatically on boot\\&." |
| 780 |
msgstr "" |
| 781 |
|
| 782 |
#. type: Plain text |
| 783 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 784 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 785 |
msgid "" |
| 786 |
"Packages using B<autoconf>(1) are recommended to use a configure script " |
| 787 |
"excerpt like the following to determine the unit installation path during " |
| 788 |
"source configuration:" |
| 789 |
msgstr "" |
| 790 |
|
| 791 |
#. type: Plain text |
| 792 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 793 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 794 |
#, no-wrap |
| 795 |
msgid "" |
| 796 |
"PKG_PROG_PKG_CONFIG()\n" |
| 797 |
"AC_ARG_WITH([systemdsystemunitdir],\n" |
| 798 |
" [AS_HELP_STRING([--with-systemdsystemunitdir=DIR], [Directory for systemd service files])],,\n" |
| 799 |
" [with_systemdsystemunitdir=auto])\n" |
| 800 |
"AS_IF([test \"x$with_systemdsystemunitdir\" = \"xyes\" -o \"x$with_systemdsystemunitdir\" = \"xauto\"], [\n" |
| 801 |
" def_systemdsystemunitdir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd)\n" |
| 802 |
msgstr "" |
| 803 |
|
| 804 |
#. type: Plain text |
| 805 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 806 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 807 |
#, no-wrap |
| 808 |
msgid "" |
| 809 |
" AS_IF([test \"x$def_systemdsystemunitdir\" = \"x\"],\n" |
| 810 |
" [AS_IF([test \"x$with_systemdsystemunitdir\" = \"xyes\"],\n" |
| 811 |
" [AC_MSG_ERROR([systemd support requested but pkg-config unable to query systemd package])])\n" |
| 812 |
" with_systemdsystemunitdir=no],\n" |
| 813 |
" [with_systemdsystemunitdir=\"$def_systemdsystemunitdir\"])])\n" |
| 814 |
"AS_IF([test \"x$with_systemdsystemunitdir\" != \"xno\"],\n" |
| 815 |
" [AC_SUBST([systemdsystemunitdir], [$with_systemdsystemunitdir])])\n" |
| 816 |
"AM_CONDITIONAL([HAVE_SYSTEMD], [test \"x$with_systemdsystemunitdir\" != \"xno\"])\n" |
| 817 |
msgstr "" |
| 818 |
|
| 819 |
#. type: Plain text |
| 820 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 821 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 822 |
msgid "" |
| 823 |
"This snippet allows automatic installation of the unit files on systemd " |
| 824 |
"machines, and optionally allows their installation even on machines lacking " |
| 825 |
"systemd\\&. (Modification of this snippet for the user unit directory is " |
| 826 |
"left as an exercise for the reader\\&.)" |
| 827 |
msgstr "" |
| 828 |
|
| 829 |
#. type: Plain text |
| 830 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 831 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 832 |
msgid "" |
| 833 |
"Additionally, to ensure that B<make distcheck> continues to work, it is " |
| 834 |
"recommended to add the following to the top-level Makefile\\&.am file in " |
| 835 |
"B<automake>(1)-based projects:" |
| 836 |
msgstr "" |
| 837 |
|
| 838 |
#. type: Plain text |
| 839 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 840 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 841 |
#, no-wrap |
| 842 |
msgid "" |
| 843 |
"AM_DISTCHECK_CONFIGURE_FLAGS = \\e\n" |
| 844 |
" --with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir)\n" |
| 845 |
msgstr "" |
| 846 |
|
| 847 |
#. type: Plain text |
| 848 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 849 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 850 |
msgid "" |
| 851 |
"Finally, unit files should be installed in the system with an automake " |
| 852 |
"excerpt like the following:" |
| 853 |
msgstr "" |
| 854 |
|
| 855 |
#. type: Plain text |
| 856 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 857 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 858 |
#, no-wrap |
| 859 |
msgid "" |
| 860 |
"if HAVE_SYSTEMD\n" |
| 861 |
"systemdsystemunit_DATA = \\e\n" |
| 862 |
" foobar\\&.socket \\e\n" |
| 863 |
" foobar\\&.service\n" |
| 864 |
"endif\n" |
| 865 |
msgstr "" |
| 866 |
|
| 867 |
#. type: Plain text |
| 868 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 869 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 870 |
msgid "" |
| 871 |
"In the B<rpm>(8) \\&.spec file, use snippets like the following to enable/" |
| 872 |
"disable the service during installation/deinstallation\\&. This makes use of " |
| 873 |
"the RPM macros shipped along systemd\\&. Consult the packaging guidelines of " |
| 874 |
"your distribution for details and the equivalent for other package " |
| 875 |
"managers\\&." |
| 876 |
msgstr "" |
| 877 |
|
| 878 |
#. type: Plain text |
| 879 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 880 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 881 |
msgid "At the top of the file:" |
| 882 |
msgstr "" |
| 883 |
|
| 884 |
#. type: Plain text |
| 885 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 886 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 887 |
#, no-wrap |
| 888 |
msgid "" |
| 889 |
"BuildRequires: systemd\n" |
| 890 |
"%{?systemd_requires}\n" |
| 891 |
msgstr "" |
| 892 |
|
| 893 |
#. type: Plain text |
| 894 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 895 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 896 |
msgid "And as scriptlets, further down:" |
| 897 |
msgstr "" |
| 898 |
|
| 899 |
#. type: Plain text |
| 900 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 901 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 902 |
#, no-wrap |
| 903 |
msgid "" |
| 904 |
"%post\n" |
| 905 |
"%systemd_post foobar\\&.service foobar\\&.socket\n" |
| 906 |
msgstr "" |
| 907 |
|
| 908 |
#. type: Plain text |
| 909 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 910 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 911 |
#, no-wrap |
| 912 |
msgid "" |
| 913 |
"%preun\n" |
| 914 |
"%systemd_preun foobar\\&.service foobar\\&.socket\n" |
| 915 |
msgstr "" |
| 916 |
|
| 917 |
#. type: Plain text |
| 918 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 919 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 920 |
#, no-wrap |
| 921 |
msgid "" |
| 922 |
"%postun\n" |
| 923 |
"%systemd_postun\n" |
| 924 |
msgstr "" |
| 925 |
|
| 926 |
#. type: Plain text |
| 927 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 928 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 929 |
msgid "" |
| 930 |
"If the service shall be restarted during upgrades, replace the \"%postun\" " |
| 931 |
"scriptlet above with the following:" |
| 932 |
msgstr "" |
| 933 |
|
| 934 |
#. type: Plain text |
| 935 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 936 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 937 |
#, no-wrap |
| 938 |
msgid "" |
| 939 |
"%postun\n" |
| 940 |
"%systemd_postun_with_restart foobar\\&.service\n" |
| 941 |
msgstr "" |
| 942 |
|
| 943 |
#. type: Plain text |
| 944 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 945 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 946 |
msgid "" |
| 947 |
"Note that \"%systemd_post\" and \"%systemd_preun\" expect the names of all " |
| 948 |
"units that are installed/removed as arguments, separated by spaces\\&. " |
| 949 |
"\"%systemd_postun\" expects no arguments\\&. " |
| 950 |
"\"%systemd_postun_with_restart\" expects the units to restart as " |
| 951 |
"arguments\\&." |
| 952 |
msgstr "" |
| 953 |
|
| 954 |
#. type: Plain text |
| 955 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 956 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 957 |
msgid "" |
| 958 |
"To facilitate upgrades from a package version that shipped only SysV init " |
| 959 |
"scripts to a package version that ships both a SysV init script and a native " |
| 960 |
"systemd service file, use a fragment like the following:" |
| 961 |
msgstr "" |
| 962 |
|
| 963 |
#. type: Plain text |
| 964 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 965 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 966 |
#, no-wrap |
| 967 |
msgid "" |
| 968 |
"%triggerun -- foobar E<lt> 0\\&.47\\&.11-1\n" |
| 969 |
"if /sbin/chkconfig --level 5 foobar ; then\n" |
| 970 |
" /bin/systemctl --no-reload enable foobar\\&.service foobar\\&.socket E<gt>/dev/null 2E<gt>&1 || :\n" |
| 971 |
"fi\n" |
| 972 |
msgstr "" |
| 973 |
|
| 974 |
#. type: Plain text |
| 975 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 976 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 977 |
msgid "" |
| 978 |
"Where 0\\&.47\\&.11-1 is the first package version that includes the native " |
| 979 |
"unit file\\&. This fragment will ensure that the first time the unit file is " |
| 980 |
"installed, it will be enabled if and only if the SysV init script is " |
| 981 |
"enabled, thus making sure that the enable status is not changed\\&. Note " |
| 982 |
"that B<chkconfig> is a command specific to Fedora which can be used to check " |
| 983 |
"whether a SysV init script is enabled\\&. Other operating systems will have " |
| 984 |
"to use different commands here\\&." |
| 985 |
msgstr "" |
| 986 |
|
| 987 |
#. type: SH |
| 988 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 989 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 990 |
#, no-wrap |
| 991 |
msgid "PORTING EXISTING DAEMONS" |
| 992 |
msgstr "" |
| 993 |
|
| 994 |
#. type: Plain text |
| 995 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 996 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 997 |
msgid "" |
| 998 |
"Since new-style init systems such as systemd are compatible with traditional " |
| 999 |
"SysV init systems, it is not strictly necessary to port existing daemons to " |
| 1000 |
"the new style\\&. However, doing so offers additional functionality to the " |
| 1001 |
"daemons as well as simplifying integration into new-style init systems\\&." |
| 1002 |
msgstr "" |
| 1003 |
|
| 1004 |
#. type: Plain text |
| 1005 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1006 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1007 |
msgid "" |
| 1008 |
"To port an existing SysV compatible daemon, the following steps are " |
| 1009 |
"recommended:" |
| 1010 |
msgstr "" |
| 1011 |
|
| 1012 |
#. type: Plain text |
| 1013 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1014 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1015 |
msgid "" |
| 1016 |
"If not already implemented, add an optional command line switch to the " |
| 1017 |
"daemon to disable daemonization\\&. This is useful not only for using the " |
| 1018 |
"daemon in new-style init systems, but also to ease debugging\\&." |
| 1019 |
msgstr "" |
| 1020 |
|
| 1021 |
#. type: Plain text |
| 1022 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1023 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1024 |
msgid "" |
| 1025 |
"If the daemon offers interfaces to other software running on the local " |
| 1026 |
"system via local B<AF_UNIX> sockets, consider implementing socket-based " |
| 1027 |
"activation (see above)\\&. Usually, a minimal patch is sufficient to " |
| 1028 |
"implement this: Extend the socket creation in the daemon code so that " |
| 1029 |
"B<sd_listen_fds>(3) is checked for already passed sockets first\\&. If " |
| 1030 |
"sockets are passed (i\\&.e\\&. when B<sd_listen_fds()> returns a positive " |
| 1031 |
"value), skip the socket creation step and use the passed sockets\\&. " |
| 1032 |
"Secondly, ensure that the file system socket nodes for local B<AF_UNIX> " |
| 1033 |
"sockets used in the socket-based activation are not removed when the daemon " |
| 1034 |
"shuts down, if sockets have been passed\\&. Third, if the daemon normally " |
| 1035 |
"closes all remaining open file descriptors as part of its initialization, " |
| 1036 |
"the sockets passed from the service manager must be spared\\&. Since new-" |
| 1037 |
"style init systems guarantee that no left-over file descriptors are passed " |
| 1038 |
"to executed processes, it might be a good choice to simply skip the closing " |
| 1039 |
"of all remaining open file descriptors if sockets are passed\\&." |
| 1040 |
msgstr "" |
| 1041 |
|
| 1042 |
#. type: Plain text |
| 1043 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1044 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1045 |
msgid "" |
| 1046 |
"Write and install a systemd unit file for the service (and the sockets if " |
| 1047 |
"socket-based activation is used, as well as a path unit file, if the daemon " |
| 1048 |
"processes a spool directory), see above for details\\&." |
| 1049 |
msgstr "" |
| 1050 |
|
| 1051 |
#. type: Plain text |
| 1052 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1053 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1054 |
msgid "" |
| 1055 |
"If the daemon exposes interfaces via D-Bus, write and install a D-Bus " |
| 1056 |
"activation file for the service, see above for details\\&." |
| 1057 |
msgstr "" |
| 1058 |
|
| 1059 |
#. type: SH |
| 1060 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1061 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1062 |
#, no-wrap |
| 1063 |
msgid "PLACING DAEMON DATA" |
| 1064 |
msgstr "" |
| 1065 |
|
| 1066 |
#. type: Plain text |
| 1067 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1068 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1069 |
msgid "" |
| 1070 |
"It is recommended to follow the general guidelines for placing package " |
| 1071 |
"files, as discussed in B<file-hierarchy>(7)\\&." |
| 1072 |
msgstr "" |
| 1073 |
|
| 1074 |
#. type: SH |
| 1075 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1076 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1077 |
#, no-wrap |
| 1078 |
msgid "NOTES" |
| 1079 |
msgstr "" |
| 1080 |
|
| 1081 |
#. type: Plain text |
| 1082 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1083 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1084 |
msgid "" |
| 1085 |
"All example codes in this page are licensed under \"MIT No Attribution\" " |
| 1086 |
"(SPDX-License-Identifier: MIT-0)\\&." |
| 1087 |
msgstr "" |
| 1088 |
|
| 1089 |
#. type: SH |
| 1090 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1091 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1092 |
#, no-wrap |
| 1093 |
msgid "SEE ALSO" |
| 1094 |
msgstr "" |
| 1095 |
|
| 1096 |
#. type: Plain text |
| 1097 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1098 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1099 |
msgid "" |
| 1100 |
"B<systemd>(1), B<sd-daemon>(3), B<sd_listen_fds>(3), B<sd_notify>(3), " |
| 1101 |
"B<daemon>(3), B<systemd.service>(5), B<file-hierarchy>(7)" |
| 1102 |
msgstr "" |
| 1103 |
|
| 1104 |
#. type: IP |
| 1105 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1106 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1107 |
#, no-wrap |
| 1108 |
msgid " 1." |
| 1109 |
msgstr "" |
| 1110 |
|
| 1111 |
#. type: Plain text |
| 1112 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1113 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1114 |
msgid "LSB recommendations for SysV init scripts" |
| 1115 |
msgstr "" |
| 1116 |
|
| 1117 |
#. type: Plain text |
| 1118 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1119 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1120 |
msgid "" |
| 1121 |
"\\%http://refspecs.linuxbase.org/LSB_3.1.1/LSB-Core-generic/LSB-Core-generic/" |
| 1122 |
"iniscrptact.html" |
| 1123 |
msgstr "" |
| 1124 |
|
| 1125 |
#. type: IP |
| 1126 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1127 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1128 |
#, no-wrap |
| 1129 |
msgid " 2." |
| 1130 |
msgstr "" |
| 1131 |
|
| 1132 |
#. type: Plain text |
| 1133 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1134 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1135 |
msgid "Apple MacOS X Daemon Requirements" |
| 1136 |
msgstr "" |
| 1137 |
|
| 1138 |
#. type: Plain text |
| 1139 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1140 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1141 |
msgid "" |
| 1142 |
"\\%https://developer.apple.com/library/mac/documentation/MacOSX/Conceptual/" |
| 1143 |
"BPSystemStartup/Chapters/CreatingLaunchdJobs.html" |
| 1144 |
msgstr "" |
| 1145 |
|
| 1146 |
#. type: TH |
| 1147 |
#: debian-trixie opensuse-leap-16-1 |
| 1148 |
#, no-wrap |
| 1149 |
msgid "systemd 257.13" |
| 1150 |
msgstr "" |
| 1151 |
|
| 1152 |
#. type: Plain text |
| 1153 |
#: debian-trixie fedora-44 mageia-cauldron opensuse-leap-16-1 |
| 1154 |
msgid "" |
| 1155 |
"Old-style daemons are usually activated exclusively on boot (and manually by " |
| 1156 |
"the administrator) via SysV init scripts, as detailed in the \\m[blue]B<LSB " |
| 1157 |
"Linux Standard Base Core Specification>\\m[]\\&\\s-2\\u[1]\\d\\s+2\\&. This " |
| 1158 |
"method of activation is supported ubiquitously on Linux init systems, both " |
| 1159 |
"old-style and new-style systems\\&. Among other issues, SysV init scripts " |
| 1160 |
"have the disadvantage of involving shell scripts in the boot process\\&. New-" |
| 1161 |
"style init systems generally use updated versions of activation, both during " |
| 1162 |
"boot-up and during runtime and using more minimal service description " |
| 1163 |
"files\\&." |
| 1164 |
msgstr "" |
| 1165 |
|
| 1166 |
#. type: TH |
| 1167 |
#: debian-unstable |
| 1168 |
#, no-wrap |
| 1169 |
msgid "systemd 261~rc3" |
| 1170 |
msgstr "" |
| 1171 |
|
| 1172 |
#. type: TH |
| 1173 |
#: fedora-44 |
| 1174 |
#, no-wrap |
| 1175 |
msgid "systemd 259.5" |
| 1176 |
msgstr "" |
| 1177 |
|
| 1178 |
#. type: TH |
| 1179 |
#: fedora-rawhide |
| 1180 |
#, no-wrap |
| 1181 |
msgid "systemd 261~rc2" |
| 1182 |
msgstr "" |
| 1183 |
|
| 1184 |
#. type: TH |
| 1185 |
#: mageia-cauldron |
| 1186 |
#, no-wrap |
| 1187 |
msgid "systemd 258.7" |
| 1188 |
msgstr "" |
| 1189 |
|
| 1190 |
#. type: TH |
| 1191 |
#: opensuse-tumbleweed |
| 1192 |
#, no-wrap |
| 1193 |
msgid "systemd 260.1" |
| 1194 |
msgstr "" |