[systemd-devel] fsckd needs to go

Martin Pitt martin.pitt at ubuntu.com
Fri May 22 05:23:42 PDT 2015

Hello Lennart,

sorry for the late answer, got stuck in different things in the past
two weeks..

Lennart Poettering [2015-04-28 17:33 +0200]:
> On Fri, 03.04.15 14:58, Lennart Poettering (lennart at poettering.net) wrote:
> > systemd-fsckd would try to connect to some AF_UNIX/SOCK_STREAM socket
> > in the fs, after forking and before execing fsck in the child, and
> > pass the connected socket to fsck via the -C switch. If the socket is
> > not connectable it would avoid any -C switch. With this simple change
> > you can make this work for you: simply write a daemon (outside of
> > systemd) that listens on that sockets and reads the progress data from
> > it. Using SO_PEERCRED you can query which fsck PID this is from and
> > use it to kill it. You could even add this to ply natively if you
> > wish, since it's kinda strange to bump this all off another daemon in
> > the middle, unnecessarily.
> I implemented this now, and removed fsckd in the progress. The
> progress data is now available on /run/systemd/fsck.progress which
> should be an AF_UNIX/SOCK_STREAM socket.

Great, thanks! This works fine, it's very similar to what Didier did
before. I. e. fsckd essentially works almost unmodified (except for
adjusting the socket path).

So we'll maintain that patch downstream now. It makes maintaining
translations harder, but so be it.

> Please test this, I only did some artifical testing myself, since I
> don't use file systems that require fsck anymore myself.

Neither do I, but there's always test/mocks/fsck which works very



Martin Pitt                        | http://www.piware.de
Ubuntu Developer (www.ubuntu.com)  | Debian Developer  (www.debian.org)

More information about the systemd-devel mailing list