Which filesystems offer snapshot functionality for users to recover data?

On Linux, btrfs is your main option for snapshots within a filesystem, but is not yet stable, though it does have some fsck and repair tools.

ZFS is another option, from Solaris. While you could in theory use this under Linux, it's mostly implemented in userland only (though there is some work on a kernel-based implementation) and is not in standard Linux distributions.

This LVM answer has some details on the pro's and con's of using LVM snapshots, and some btrfs/ZFS links. With some filesystems (ext3 and XFS), LVM will take care of freezing the FS before it takes the snapshot, but LVM snapshots can have performance problems and still have some bugs.

I don't think LVM is a great solution for your 'quick snapshot of user data' application, and btrfs/ZFS are not yet suitable [as of 2011].

Instead, you might want to look at rsnapshot, which is a user-space tool that efficiently creates snapshots using any filesystem, without using LVM. Because it uses rsync and stores the snapshots under successive directories, using hard links between different snapshots if a file has not changed, it can run surprisingly quickly even on reasonably large sets of files. It is used a lot for backups but can also be used for this sort of user-data snapshot requirement, and with a little setup can enable anyone to restore their snapshotted files, by using read-only NFS or Samba - see this HOWTO section on restoring files. Files can be restored with standard Linux tools as rsnapshot mirrors the source directory into each snapshot directory.

rsnapshot is quite flexible using its standard features, and since it's written in Perl it's quite easy to customise it, e.g. if you want to provide on-demand snapshots. The main drawbacks compared to filesystem snapshots are speed and disk space - each file that changes results in a new copy in the snapshot, whereas filesystem snapshots only copy new blocks in the file.


Just spotted THIS page on wikipedia, there's a snapshot capabilities column - just wanted people to be aware of this in the future.