Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 16 Mar 2011 13:12:15 +0200
From:      Kostik Belousov <kostikbel@gmail.com>
To:        Yamagi Burmeister <lists@yamagi.org>
Cc:        freebsd-fs@freebsd.org, mckusick@freebsd.org
Subject:   Re: Snapshots are never freed on at least 8.1 and 8.2
Message-ID:  <20110316111215.GO78089@deviant.kiev.zoral.com.ua>
In-Reply-To: <alpine.BSF.2.00.1103161145220.6622@saya.home.yamagi.org>
References:  <alpine.BSF.2.00.1103160925050.4245@saya.home.yamagi.org> <alpine.BSF.2.00.1103161145220.6622@saya.home.yamagi.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--2l/qJWwi7aEgZx1i
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Wed, Mar 16, 2011 at 12:00:19PM +0100, Yamagi Burmeister wrote:
> On Wed, 16 Mar 2011, Yamagi Burmeister wrote:
>=20
> >Hello,
> >I'm not sure if this is a bug or the expected behavior but it seems quit
> >strange. On at least FreeBSD 8.1 and 8.2 UFS2 snapshots are never freed
> >while the filesystem is mounted. Therefor you have to remount every 20
> >snapshots which is quiet a pain when using "dump -L" or similar things
> >via cron.
>=20
> Okay, I had a deeper look into this and it's some kind of PEBKAC
> (problem exists between keyboard and chair). For various reasons there
> is no "options FFS" in the kernel of this box but ufs.ko is loaded in
> /boot/loader.conf. In sys/modules/zfs/Makefile the CFLAGS are "CFLAGS+=3D
> -DSOFTUPDATES -DUFS_DIRHASH".
> But in sys/ufs/ufs/ufs_lookup.c line 1241 and line 1293 the call to
> ffs_snapgone() is hidden behind "FFS". Since FFS isn't defined when
> ufs.ko is build the call isn't compiled in, the function isn't called
> and the snapshot isn't correctly removed from the list.
> So the question is, why there's no -DFFS in the CFLAGS for ufs.ko? At
> this time snapshots are broken when ufs.ko is used.

See my other reply, I think that #ifdef line shall be removed at all.

We do not care much about ufs/ffs split for long time, and if we do,
we should introduce some operation like UFS_SNAPGONE().

--2l/qJWwi7aEgZx1i
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (FreeBSD)

iEYEARECAAYFAk2Amw8ACgkQC3+MBN1Mb4jzpQCg0GBz3zbztmyrOItlwBUJ+1i3
CSkAoI1spiMZ07jGPhISOefzvirc3cG1
=Zgej
-----END PGP SIGNATURE-----

--2l/qJWwi7aEgZx1i--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110316111215.GO78089>