5.1-R-p11 unable to "sync disks" when shutting down

Tim Kientzle kientzle at acm.org
Wed Dec 31 16:02:31 PST 2003


David Gilbert wrote:
>>>>>>"Tim" == Tim Kientzle <kientzle at acm.org> writes:
> 
> Tim> What's needed is some way for fsck to mark a filesystem as
> Tim> having a bgfsck in progress.  Then fsck -F can check for that marker.
> 
> Hrm.  Isn't this done?  Isn't there a 'special' snapshot created by
> the bgfsck process?  Or does this snapshot evaporate (have no links)?

You've exceeded my expertise with that one.  Also, using the
snapshot as a flag wouldn't be robust against errors in the snapshot
code itself.

I note that fsck_ffs sets a flag "needs foreground check"
if the background check fails.   It might suffice to change the
logic just a bit:
   * Set this flag when bg check starts
   * Clear the flag when bg check succeeds

That would ensure that a foreground check
gets done if the system rebooted during the bg
check or if the bg check crashed for any reason.

I'm not sufficiently familiar with fsck_ffs to
tackle this, but it could be a pretty simple fix.

Tim



More information about the freebsd-current mailing list