Re: Giving up on x buffers - losing files

From: Arjan van Leeuwen (avleeuwen_at_piwebs.com)
Date: 06/30/04

  • Next message: Valentin Nechayev: "Re: Jiffies"
    Date: Wed, 30 Jun 2004 11:55:37 +0200
    To: "Don Lewis" <truckman@freebsd.org>
    
    

    On Tue, 29 Jun 2004 03:29:59 -0700 (PDT), Don Lewis <truckman@FreeBSD.org>
    wrote:

    > On 26 Jun, Don Lewis wrote:
    >> On 26 Jun, Arjan van Leeuwen wrote:
    <snip>
    >
    > I managed to get motivated and crank out the patch below. I'm still not
    > sure why the sync command seems to prevent the problem, but the sync
    > code in boot() seems to be unable to flush the buffers to disk.
    >
    > The way this patch works is that the syncer kernel thread is not
    > immediately terminated at kernel shutdown time. Instead, the syncer
    > thread is told to speed up and run through its work queue a few times
    > before terminating.
    >
    > One minor issue that I noticed but haven't yet figured out is that even
    > after the only items remaining on the syncer work list are the syncer
    > vnodes for each of the mount points, something is occasionally putting
    > the disk device vnode back on the work list. I suspect that when the
    > file system is getting synced, it is dirtying the superblock or summary
    > info.
    >
    > With this patch, the syncer takes noticeably longer to shut down, but
    > the final sync done by boot() finishes either immediately or within two
    > iterations, even after running mergemaster.
    >
    <snip patch>

    Yes, this works for me too. Is there any chance that this can be
    committed? It may slow down shutdown a bit, but if I have to choose
    between that and losing (important) files, you can give me a longer
    shutdown any time :).

    Arjan

    -- 
    Using Opera's revolutionary e-mail client: http://www.opera.com/m2/
    _______________________________________________
    freebsd-current@freebsd.org mailing list
    http://lists.freebsd.org/mailman/listinfo/freebsd-current
    To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"
    

  • Next message: Valentin Nechayev: "Re: Jiffies"

    Relevant Pages