From owner-freebsd-current@FreeBSD.ORG Sun Jan 22 21:44:54 2012 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B9A25106566C; Sun, 22 Jan 2012 21:44:54 +0000 (UTC) (envelope-from fjwcash@gmail.com) Received: from mail-vw0-f54.google.com (mail-vw0-f54.google.com [209.85.212.54]) by mx1.freebsd.org (Postfix) with ESMTP id 52A5E8FC12; Sun, 22 Jan 2012 21:44:53 +0000 (UTC) Received: by vbbey12 with SMTP id ey12so2247730vbb.13 for ; Sun, 22 Jan 2012 13:44:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=qBUrWi4mVn/+nKyS72i0Be9qGuOn77fO/G5Cozlo5yE=; b=rqVoXTbAloKzvtkViGTAcYXNKRX1TISY8UfnHX+cm6HVOff5SrRbkPtyLJYVBnMtvr 96FPwoioiS2MNlnMp9rFBPNJhLqa2FwFzZyFFCD8etN9u08nWfS7oHiXE56Y6Nwr46e1 KUbwdQpcxcd7X/y9GwIqv4AG9qC2MJ9sf+qFY= MIME-Version: 1.0 Received: by 10.52.33.239 with SMTP id u15mr2712409vdi.49.1327268693501; Sun, 22 Jan 2012 13:44:53 -0800 (PST) Received: by 10.220.117.11 with HTTP; Sun, 22 Jan 2012 13:44:53 -0800 (PST) Received: by 10.220.117.11 with HTTP; Sun, 22 Jan 2012 13:44:53 -0800 (PST) In-Reply-To: <20120122112322.GF1723@garage.freebsd.pl> References: <201201212112.q0LLCrQn009840@svn.freebsd.org> <20120122112322.GF1723@garage.freebsd.pl> Date: Sun, 22 Jan 2012 13:44:53 -0800 Message-ID: From: Freddie Cash To: Pawel Jakub Dawidek Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-current@freebsd.org Subject: Re: Snapshot listing speedup. X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Jan 2012 21:44:54 -0000 On Jan 22, 2012 3:26 AM, "Pawel Jakub Dawidek" 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.