fsckd daemon for inter-fsckd communication
authorDidier Roche <didrocks@ubuntu.com>
Fri, 22 May 2015 11:04:38 +0000 (13:04 +0200)
committerLuca Boccassi <bluca@debian.org>
Mon, 30 Jan 2023 01:03:48 +0000 (01:03 +0000)
commitad1eb38389442c6517e623cbfe4d1350945ce311
treefc1c93e8aeedfa2176d2d0bda2ebefb55eede8a1
parent11b44f8478f3d64f8b6c4d7d2526b4150be0b784
fsckd daemon for inter-fsckd communication

Global logic:
Add systemd-fsckd multiplexer which accepts multiple (via systemd-fsck's
/run/systemd/fsck.progress socket) fsck instances to connect to it and sends
progress report. systemd-fsckd then computes and writes to /dev/console the
number of devices currently being checked and the minimum fsck progress.

Plymouth and user interaction:
Forward the progress to plymouth and support canellation of in progress fsck.
Try to connect and send to plymouth (if running) some checked report progress,
using direct plymouth protocole.

Update message is the following:
fsckd:<num_devices>:<progress>:<string>
* num_devices corresponds to the current number of devices being checked (int)
* progress corresponds to the current minimum percentage of all devices being
  checked (float, from 0 to 100)
* string is a translated message ready to be displayed by the plymouth theme
  displaying the information above. It can be overridden by plymouth themes
  supporting i18n.

Grab in fsckd plymouth watch key Control+C, and propagate this cancel request
to systemd-fsck which will terminate fsck.

Send a message to signal to user what key we are grabbing for fsck cancel.

Message is: fsckd-cancel-msg:<string>
Where string is a translated string ready to be displayed by the plymouth theme
indicating that Control+C can be used to cancel current checks. It can be
overridden (matching only fsckd-cancel-msg prefix) for themes supporting i18n.

Misc:
systemd-fsckd stops on idle when no fsck is connected.
Add man page explaining the plymouth theme protocol, usage of the daemon
as well as the socket activation part. Adapt existing fsck man page.

Note that fsckd had lived in the upstream tree for a while, but was removed.
More information at
http://lists.freedesktop.org/archives/systemd-devel/2015-April/030175.html
-

Gbp-Pq: Topic debian
Gbp-Pq: Name fsckd-daemon-for-inter-fsckd-communication.patch
man/rules/meson.build
man/systemd-fsckd.service.xml [new file with mode: 0644]
meson.build
po/POTFILES.in
src/fsckd/fsckd.c [new file with mode: 0644]
units/meson.build
units/systemd-fsck-root.service.in
units/systemd-fsck@.service.in
units/systemd-fsckd.service.in [new file with mode: 0644]
units/systemd-fsckd.socket [new file with mode: 0644]