[systemd-devel] Reiserfs fsck and progress bar

Lennart Poettering lennart at poettering.net
Mon Feb 21 07:06:29 PST 2011

On Mon, 21.02.11 12:17, Andrey Borzenkov (arvidjaar at gmail.com) wrote:

> Last week I unintentionally simulated crash by doing "reboot -f". So I
> had chance to enjoy home which is in reiserfs to be checked.
> The problem is that nice progress bar is intermixed with messages
> "replaying transaction XXX", which makes nice progress bar not that
> nice really.
> I am not sure whether those messages come from fsck itself or from
> kernel. In any case it is something that needs be fixed.

Sounds like something to fix in reiserfsck?

Doesn't this problem kinda fix itself anyway due to the obsolescence of

> What I am also not sure about - how this progress bar game is going to
> fit into asynchronous units startup anyway? While one file system is
> being checked, something else may well be started in background, so it
> will intermix with bar, or?

Yes it will, unless the tool does some locking itself.

> P.S. I really expected reboot -f to at least sync file systems. That
> is what other Unixes do at least :)

We do call sync() before calling reboot() in reboot -f, unless you pass
--no-sync/-n. Also, afaik the reboot() syscall implicitly does that
anyway, so this is actually redundant to call from userspace.

In general syncing things doesn't have the effect of making the fs
appear "clean" on the next reboot.

You can do "systemctl reboot -f" (which is different from SysV's "reboot
-f") which has basically the same effect as sending SIGRTMIN+15 to PID
1, which triggers a slightly cleaner shutdown: daemons will still not be
stopped cleanly, but we will kill all processes and do try very hard to
unmount all remount all FS r/o, and detach DM/loop/...

So you have three options.

a) systemctl reboot        # For normal, clean shutdowns. aka "I'm Too Young To Die"
b) systemctl reboot -f     # Tougher version, which kills everything, and unmounts/remounts. aka "Hurt Me Plenty"
c) reboot -f               # Ultratough version, just calls sync() and reboot(). aka "Ultraviolence"

Hope you young kids still get those DOOM references ;-)


Lennart Poettering - Red Hat, Inc.

More information about the systemd-devel mailing list