You can use the zfs rollback command to discard all changes made to a file system since a specific snapshot was created. The file system reverts to its state at the time the snapshot was taken. By default, the command cannot roll back to a snapshot other than the most recent snapshot.
To roll back to an earlier snapshot, all intermediate snapshots must be destroyed. You can destroy earlier snapshots by specifying the –r option.
If clones of any intermediate snapshots exist, the –R option must be specified to destroy the clones as well.
In the following example, the tank/home/cindy file system is rolled back to the tuesday snapshot:
# zfs rollback tank/home/cindy@tuesday cannot rollback to 'tank/home/cindy@tuesday': more recent snapshots exist use '-r' to force deletion of the following snapshots: tank/home/cindy@wednesday tank/home/cindy@thursday # zfs rollback -r tank/home/cindy@tuesday
In this example, the wednesday and thursday snapshots are destroyed because you rolled back to the earlier tuesday snapshot.
# zfs list -r -t snapshot -o name,creation tank/home/cindy NAME CREATION tank/home/cindy@tuesday Fri Aug 3 15:18 2012