SYSTEMD-NOTIFY(1) systemd-notify SYSTEMD-NOTIFY(1) systemd-notify - systemd-notify [...] [=...] systemd-notify --exec [...] [=...] ; -- { ...} systemd-notify --fork [...] -- { ...} systemd-notify . . . sd_notify() . sd_notify(3). . systemd NotifyAccess= . systemd.service(5) . sd_notify() . NotifyAccess=main NotifyAccess=exec. sd_notify() NotifyAccess=all . systemd-notify . --no-block . systemd-notify sd_notify()() PID systemd-notify ( ). . PID . -- systemd-notify -- NotifyAccess=all. --pid= . : --ready . systemd-notify READY=1. sd_notify(3). --reloading . systemd-notify RELOADING=1 ( MONOTONIC_USEC= Type=notify-reload systemd.service(5) ). sd_notify(3). 253. --stopping . systemd-notify STOPPING=1. sd_notify(3). 253. --pid= PID . PID . "auto" PID systemd-notify . "self" PID systemd-notify "parent" PID -- . --pid=auto systemd-notify --pid=$PID. sd_notify(3). systemd-notify sd_notify()() PID --pid=. . PID . systemd-notify --pid= NotifyAccess=main NotifyAccess=exec . systemd-notify -- ( ) -- NotifyAccess=all . systemd.service(5) . --uid= . UNIX UID . UID . . 237. --status= . . systemd-notify STATUS=.... sd_notify(3). status systemctl(1) . --booted 0 systemd . . . sd_booted(3). systemctl(1) is-system-running. "offline" systemd . --no-block . systemd-notify systemd-notify . . 246. --exec systemd-notify . ";" ( ) . " "" systemd-notify "\;". 254. --fd= . FileDescriptorStoreMax= systemd.service(5) . systemd-notify . . bash(1) : systemd-notify --fd=4 --fd=5 4 254. --fdname= --fd= ( ). "FDNAME=". . . 254. --fork "READY=1" . : systemd-notify . sd_notify() . /dev/null . systemd-notify ( --quiet) . systemd-notify . systemd-run . systemd-notify : 1. systemd-notify "READY=1" . 2. ( ) "READY=1". : # PID=$(systemd-notify --fork -- mycommand) ... kill "$PID" unset PID 258. --quiet -q --fork. 258. -h --help . --version . 0 . 1. . : #!/bin/sh mkfifo /tmp/waldo systemd-notify --ready --status="Waiting for data..." while : ; do read -r a < /tmp/waldo systemd-notify --status="Processing $a" # Do something with $a ... systemd-notify --status="Waiting for data..." done systemd(1), systemctl(1), systemd.unit(5), systemd.service(5), sd_notify(3), sd_booted(3) 3 . . : . systemd 260.2 SYSTEMD-NOTIFY(1)