[opensuse-factory] Introduce btrfsmaintenance package to Factory
Hi, let me introduce a new package that supplements the btrfs filesystem and aims to automate a few maintenance tasks. This means the scrub, balance, trim or defragmentation. The package comes from SLE12 where btrfs is going to be the default filesystem as well. Each of the tasks can be turned on/off and configured independently. The default config values were selected to fit the default installation profile. * scrub - go through all medatada/data and verify the checksums, default period is one month * balance - the balance command can do a lot of things, in general moves data around in big chunks, here we use it to reclaim back the space of the underused chunks so it can be allocated again according to current needs The point is to prevent some corner cases where it's not possible to eg. allocate new metadata chunks because the whole device space is reserved for all the chunks, although the total space occupied is smaller and the allocation should succeed. * trim - run TRIM on the filesystem using the 'fstrim' utility, makes sense for SSD devices. * defrag - run defrag on configured directories. This is for convenience and not necessary. There's a separate defragmentation task that happens automatically and defragments only the RPM database files in /var/lib/rpm. This is done via a zypper plugin and the defrag pass triggers at the end of the installation. This improves reading the RPM databases later, but the installation process fragments the files very quickly so it's not likely to bring a significant speedup here. Cron takes care of periodic execution of the scripts, but they can be run any time directly from /usr/share/btrfs/maintenance/, respecting the configured values in /etc/sysconfig/btrfsmaintenance. If the period is changed manually, the cron symlinks have to be refreshed, use "systemctl restart btrfsmaintenance-refresh" (or the "rcbtrfsmaintenance-refresh" shortcut). Changing the period via yast2 sysconfig editor triggers the refresh automatically. The project lives in obs://filesystems/btrfsmaintenance and I'm going to submit it to Factory. I'd like to ask volunteers to give it some testing. Feedback is welcome. Thanks, David -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org
participants (1)
-
David Sterba