svn commit: r184934 - head/sys/ufs/ffs

Greg Byshenk freebsd at byshenk.net
Fri Nov 14 01:41:38 PST 2008


On Thu, Nov 13, 2008 at 10:11:19AM -0800, Doug Ambrisko wrote:
> Kostik Belousov writes:
> | On Thu, Nov 13, 2008 at 05:40:21PM +0000, Doug Ambrisko wrote:
> | > Author: ambrisko
> | > Date: Thu Nov 13 17:40:21 2008
> | > New Revision: 184934
> | > URL: http://svn.freebsd.org/changeset/base/184934
> | > 
> | > Log:
> | >   For now on every 10 cyclinder groups flush the buffer cache to free
> | >   up space.  If the buffer cache fills up then the disk systems can
> | >   grind to a halt.  Better tuning can be figured out later.
> | >   
> | >   Tested by:	Tim, others and work
> | >   Reviewed by:	Kostik Belousov
> | >   PR:		128832
> | > 
> | > Modified:
> | >   head/sys/ufs/ffs/ffs_snapshot.c
> | > 
> | > Modified: head/sys/ufs/ffs/ffs_snapshot.c
> | > ==============================================================================
> | > --- head/sys/ufs/ffs/ffs_snapshot.c	Thu Nov 13 17:13:16 2008	(r184933)
> | > +++ head/sys/ufs/ffs/ffs_snapshot.c	Thu Nov 13 17:40:21 2008	(r184934)
> | > @@ -351,6 +351,8 @@ restart:
> | >  		if (error)
> | >  			goto out;
> | >  		bawrite(nbp);
> | > +		if (cg % 10 == 0)
> | > +			ffs_syncvnode(vp, MNT_WAIT);
> | >  	}
> | >  	/*
> | >  	 * Copy all the cylinder group maps. Although the
> | > @@ -372,6 +374,8 @@ restart:
> | >  			goto out;
> | >  		error = cgaccount(cg, vp, nbp, 1);
> | >  		bawrite(nbp);
> | > +		if (cg % 10 == 0)
> | > +			ffs_syncvnode(vp, MNT_WAIT);
> | >  		if (error)
> | >  			goto out;
> | >  	}
> | Thank you !
> | 
> | Please, MFC it for 7.1.

> I'll wait for some of the dust to settle first.
 
> Also I want to test a 7.1 machine here without any of my patches, then
> start adding some back it.  I should be able to get that mostly done
> today unless I get hit with other work stuff.  From my perspective 
> I have a couple of low risk patches that should go in but look more 
> radical.
 
FWIW, I've just tested the patch on my system described previously
7.1-PRERELEASE amd64, and my snapshots now work, where they did not
without the patch (see below).

Of course, a snapshot takes a very long time to complete, but I think
that is to be expected with filesystems that large.

Unless there is some problem I am unaware of, let me add my vote to 
the MFC column.

-greg


/dev/da1p1                  96850470    7934486   81167948     9%    /export/mail
/dev/da1p2                1937058312  974663846  807429802    55%    /export/home
/dev/da1p3                1937058312   81633990 1700459658     5%    /export/misc
/dev/da1p4                2598991534  274277272 2116794940    11%    /export/spare
[...]
/dev/md9                    96850470    7877014   81225420     9%    /export/snapshots/mail
/dev/md8                  1937058312  973516342  808577306    55%    /export/snapshots/home
/dev/md10                 1937058312   80486486 1701607162     5%    /export/snapshots/misc
/dev/md11                 2598991534  272737736 2118334476    11%    /export/snapshots/spare

# ls -l /export/*/.snapshots/*
-r--r-----  1 root  operator  2048000085176 Nov 14 09:44 /export/home/.snapshots/20081113
-r--r-----  1 root  operator   102400004296 Nov 14 08:59 /export/mail/.snapshots/20081113
-r--r-----  1 root  operator  2048000085176 Nov 14 09:30 /export/misc/.snapshots/20081113
-r--r-----  1 root  operator  2747837267536 Nov 14 10:10 /export/spare/.snapshots/20081113

-- 
greg byshenk  -  gbyshenk at byshenk.net  -  Leiden, NL


More information about the svn-src-head mailing list