Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 31 May 2010 09:48:16 -0400
From:      Paul Mather <paul@gromit.dlib.vt.edu>
To:        David Magda <dmagda@ee.ryerson.ca>
Cc:        FreeBSD-STABLE Mailing List <freebsd-stable@freebsd.org>
Subject:   Re: Make ZFS auto-destroy snapshots when the out of space?
Message-ID:  <7B30E5C6-07F9-4B61-9F09-1615D21F6461@gromit.dlib.vt.edu>
In-Reply-To: <19664824-1B23-4E5F-BC12-BB4D59A9C8AA@ee.ryerson.ca>
References:  <4C017419.9010909@strauser.com> <4632C12D-2B1E-4073-B2C9-E9D15C212EF1@ee.ryerson.ca> <F5E2E18E-A870-4600-9D4C-D0BE9BF68CF1@strauser.com> <19664824-1B23-4E5F-BC12-BB4D59A9C8AA@ee.ryerson.ca>

next in thread | previous in thread | raw e-mail | index | archive | help
On May 30, 2010, at 10:35 PM, David Magda wrote:

> An event framework would certainly be helpful in a general sense =
(Linux has event(3) AFAIK), and that could certainly be useful for =
purging snapshots during resource constrained situations. But even if we =
don't have it, I doubt a fork(2) from cron(8) and a statfs(2) would be =
onerous on a system. :)

Devd already receives several ZFS-based events (failed vdev, I/O error, =
checksum mismatch, etc.), so perhaps it would be useful to add another, =
e.g., "space" which is set to be triggered when a pool attains a certain =
percentage full.  This could default to 100%, but be capable of being =
set lower by an associated kernel sysctl.  You could then have any =
auto-pruning/snapshot management script triggered from devd.  (You'd =
probably also have to figure out some kind of throttling mechanism for =
this devd event, too.)

Cheers,

Paul.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?7B30E5C6-07F9-4B61-9F09-1615D21F6461>