I believe the question of Ned and the answers given have more far reaching consequences than has been discussed so far.
When I read this thread I thought there was an easy solution to deleting files from a snapshot by using clones instead. Clones are a writable copy so you should be able to delete files selectively. However it turns out that this is not possible: - Clones can only be made from snapshots - Snapshots can only be deleted if there is only one dataset that directly derives from them. The snapshot can not be destroyed as long as both the original file system and the clone live. And the "big file" that Ned wants to delete will still survive in the snapshot even if deleted from the clone. Example: zfs create t1 zfs snapshot t...@s1 zfs snapshot t...@s2 zfs snapshot t...@s3 zfs clone t...@s2 t2 zfs snapshot t...@s4 creates datasets with the following origin graph owned by t1: s1 <- s2 <- s3 <- t1 owned by t2: (s2) <- s4 <- t2 Any snapshot can be destroyed except s2. And t2 can be destroyed but not t1 since destroying a filesystem implicitly destroys all owned snapshots. zfs promote can be used to swap the roles of t1 and t2. Thus it seems that clones are not at all independent copies, because all copies of a filesystem are always linked via an older snapshot. Given the central role of read-only snapshots to the design, my fear would be that sharing files across independent file systems is impossible. Then again there is pool wide deduplication which seems to have no problem sharing blocks across independent filesystems. Creating a new filesystem and copying all files over should result in two filesystems sharing the same blocks. This very same result should also be achievable without having to copy the data. And with independent clones Neds use case would be possible. ZFS has created a world where setting up several filesystems even within a single users home directory is encouraged and has been made very easy. I would find it highly desirable if files could be moved across filesystem boundaries without the need to revert to a copy & remove. This is both due to the difference in performance as well as due to the waste of space if the moved file is already part of a snapshot of the old filesystem. Can somebody with more knowledge about the ZFS internals say something on the possibility of independent clones and sharing / moving between filesystems? Michael Bosch -- This message posted from opensolaris.org _______________________________________________ zfs-discuss mailing list zfs-discuss@opensolaris.org http://mail.opensolaris.org/mailman/listinfo/zfs-discuss