From owner-freebsd-questions@FreeBSD.ORG Tue Apr 19 18:13:57 2011 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 263B7106566B for ; Tue, 19 Apr 2011 18:13:57 +0000 (UTC) (envelope-from cronfy@gmail.com) Received: from mail-iw0-f182.google.com (mail-iw0-f182.google.com [209.85.214.182]) by mx1.freebsd.org (Postfix) with ESMTP id E202E8FC08 for ; Tue, 19 Apr 2011 18:13:56 +0000 (UTC) Received: by iwn33 with SMTP id 33so6693591iwn.13 for ; Tue, 19 Apr 2011 11:13:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:from:date:message-id:subject:to :content-type; bh=g8sLLT7xB99ibpDp2BGxUY3MsgK/nxhk2pSBK/zzpQo=; b=d1ucv7eL3G7JF2mnDyZYualMGl1B4nRBmArzgFmCyXI2I0NxHx6ssYpoIpnKw2Aqas THmIdGiJVR+OZ728AounwTsyZudtkKvNN+8a+yAQMzSKKMFm6vR1PNZORPMDfJYBLB+F 5ePsGuY8D4ltp2omdRzCfW5bF0yDbipp5UKws= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:from:date:message-id:subject:to:content-type; b=IzgSlksOrbyMmTRNGhVrBMVLniPFO0RiqVJ8lkvm4DAcBhqZcn/TelqCS/YRvOhfEw J/WMRZoCmAzwbqju89kRdPr1tSLzCTl4pxjF6uoQ6401QCQ8zNYT5FAYbeU5G4EDxwp/ QQeArM7u5RGNSviIB3fM1hXbo6yt963soC1ic= Received: by 10.42.135.200 with SMTP id q8mr6262464ict.198.1303235342768; Tue, 19 Apr 2011 10:49:02 -0700 (PDT) MIME-Version: 1.0 Received: by 10.42.82.141 with HTTP; Tue, 19 Apr 2011 10:48:31 -0700 (PDT) From: cronfy Date: Tue, 19 Apr 2011 21:48:31 +0400 Message-ID: To: freebsd-questions Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: 7.3 - optimizing filesystem - cache all metadata X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Apr 2011 18:13:57 -0000 Hello! I have FreeBSD 7.3 server that is used for web sites. It performs many filesystem operations, so filesystem performance is very important. I am looking how can it be improved. I already use vfs.lookup shared=3D1, it helped me some time ago to decrease CPU time usage on filesystem operations. I also increased vfs.ufs.dirhash_maxmem to 67108864. But It still sometimes takes several seconds to ls directory that s not in the cache and fstat() calls sometimes slow when IO is high. Can filesystem performance be improved more? I think performance would benefit from increasing memory used for file metadata cache. One of the mos= t frequent operations is fstat(). If it could be possible to tell FreeBSD to keep all metadata cache in memory and never clear it, all repeating fstat() operations would become very fast. How can I see how much memory is used for filesystem cache? Is it possible to increase this memory and increase time that cache entry is keeped in the memory (probably to infinity)? Thanks in advance. --=20 =D0=9E=D0=BB=D0=B5=D0=B3 =D0=9F=D0=B5=D1=82=D1=80=D0=B0=D1=87=D0=B5=D0=B2