Make ZFS auto-destroy snapshots when the out of space?

Kirk Strauser kirk at strauser.com
Sun May 30 22:06:21 UTC 2010


On May 29, 2010, at 9:42 PM, Dan Nelson wrote:

> If the kernel does the snapshot deleting itself, why not add a pool- 
> level
> property that sets the amount of free space at which the deletion  
> starts?
> That way you don't need the cleanup script.  Alternatively, make the
> org.freebsd:allowautodestroy property hold the trigger freespace  
> amount.
> That way you can have monthly/daily/hourly snapshots but set it so the
> hourly ones disappear first, then the dailies (by setting the destroy
> trigger slightly higher for the ones you want to expire first).


That'd definitely work. The idea was to keep as much as possible out  
of the kernel so that it wouldn't add additional complexity for people  
who don't use it (but it certainly wouldn't offend me any to find it  
in there :-) ).
-- 
Kirk Strauser






More information about the freebsd-stable mailing list