OpenSolaris

Printable Version Enter a New Search
Bug ID 6609196
Synopsis 'zfs destroy -r' can needlessly iterate over all filesystems in pool
State 10-Fix Delivered (Fix available in build)
Category:Subcategory kernel:zfs
Keywords
Responsible Engineer Richard Morris
Reported Against
Duplicate Of
Introduced In solaris_nevada
Commit to Fix snv_84
Fixed In snv_84
Release Fixed solaris_nevada(snv_84) , solaris_10u6(s10u6_01) (Bug ID:2160891)
Related Bugs
Submit Date 25-September-2007
Last Update Date 29-April-2008
Description
"zfs destroy -r" will iterate over all filesystems for every origin snapshot to be destroyed, to determine if we are allowed to do the destroy (we aren't if there are clones that won't be destroyed).  So "zfs destroy -r" is potentially O(snaps to be destroyed * filesystems in the pool).

We should be optimistic and just search the tree to be destroyed, and verify that all origins are accounted for there.  Only if that fails should we go and search the whole pool.

(Also, the bp rewrite work will include a much faster way to get the list of clones of a given origin, which should be used once available.)
Work Around
N/A
Comments
N/A