Snapshot listing speedup.

Freddie Cash fjwcash at gmail.com
Sun Jan 22 21:44:54 UTC 2012


On Jan 22, 2012 3:26 AM, "Pawel Jakub Dawidek" <pjd at freebsd.org> wrote:
>
> If you have many snapshots and you were complaining that listing them
> takes a lot of time, you may find the commit below useful.
>
> It only works if your listing is limited to snapshot names and you want
> to sort also by snapshot name (by default snapshots are sorted by
> creation time).

Would this have any effect on the speed of an 'ls' in the .zfs/snapshot/
directory? I'm guessing not, since that would have more to do with generic
directory listings and general slowness in 'ls'. But one can dream. :)
Afterall, the 'ls' *is* just querying the name and not all of the other ZFS
properties. :D

We do most of our snapshot accesses and listing via the .zfs/snapshot/
directory, which can take several seconds before the list starts to appear
when there's a couple of hundred snapshots there.


More information about the freebsd-current mailing list