From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Matthias G. Eckermann" Subject: Re: [RFC] btrfs auto snapshot Date: Wed, 17 Aug 2011 15:31:08 +0200 Message-ID: <20110817133108.GA24578@suse.com> References: <4E4B2452.9070407@oracle.com> Reply-To: "Matthias G. Eckermann" Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Cc: Chris Mason To: Anand Jain , linux-btrfs Return-path: In-Reply-To: <4E4B2452.9070407@oracle.com> List-ID: Hello Anand and all, On 2011-08-17 T 10:15 +0800 Anand Jain wrote: =20 > Appears that no one is working on the auto-snapshot feature for > btrfs, so here I am implementing the same. thanks for bringing this up! The group of features you are listing is indeed of high interest for people using btrfs. That said, not only have other people though about this, but a lot of your question already have been implemented in "snapper", and open source infrastructure developed as part of openSUSE and SUSE Linux Enterprise. Please see: http://en.opensuse.org/Portal:Snapper http://en.opensuse.org/openSUSE:Snapper_install http://lizards.opensuse.org/2011/04/01/introducing-snapper/ Source code is here: http://gitorious.org/opensuse/snapper "snapper" will be part of openSUSE 12.1 and SUSE Linux Enterprise 11 Service Pack 2, and is available as part of the respective Beta releases and Milestones already. snapper's concept in short: - shared library to make the functionality available to other tools as well - libsnapper is implemented on top of the btrfsprogs - cmdline tool "snapper" - global configuration file /etc/sysconfig/snapper - one configuration file per subvolume to be snapshotted /etc/snapper/configs/ I call this a "single configuration" going forward. Here also policies for time based snapshotting and cleanup are to be configured. - Integration into SUSE's management framework (YaST2/zypper), however, "snapper" should work independent of those, i.e. usable on other distributions easily. > Below is a draft on the feature list. Any comments / questions / > suggestions are welcome, please do let me know. Let me go through the single features quickly and list the matching snapper functionality. =20 > btrfs auto snapshot feature will include: > Initially: > - configurable timely snapshots Yes. Configured per single configuration > - uses services and crontab to schedule Yes. > - Gnome integration I more see a need for integration into systems management frameworks. > - snapshot rollback and cleanups Yes. Rules for cleanups (time based, number of snapshots) per single configuration. > - snapshot trashing based on available space // not yet done. > - snapshot destination will be subvol/.btrfs/snapshot@