From owner-freebsd-hackers@FreeBSD.ORG Fri Apr 2 19:02:45 2010 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F3C45106564A for ; Fri, 2 Apr 2010 19:02:44 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id 55B328FC13 for ; Fri, 2 Apr 2010 19:02:43 +0000 (UTC) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id o32J2dX8083321 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 2 Apr 2010 22:02:39 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4) with ESMTP id o32J2dUB026173; Fri, 2 Apr 2010 22:02:39 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4/Submit) id o32J2dnr026172; Fri, 2 Apr 2010 22:02:39 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Fri, 2 Apr 2010 22:02:39 +0300 From: Kostik Belousov To: Petr Salinger Message-ID: <20100402190239.GL2415@deviant.kiev.zoral.com.ua> References: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="LQhvuUkKKd6r3A8m" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-3.8 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00, DNS_FROM_OPENWHOIS autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: freebsd-hackers@freebsd.org Subject: Re: leak of the vnodes X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 02 Apr 2010 19:02:45 -0000 --LQhvuUkKKd6r3A8m Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Apr 02, 2010 at 07:45:03PM +0200, Petr Salinger wrote: > Hi, >=20 > I have the same problem as in > http://lists.freebsd.org/pipermail/freebsd-hackers/2009-August/029227.html >=20 > During "make check" of gcc-4.3 the vfs.numvnodes goes up, > after reaching default limit 100000 the machine is stuck. >=20 > kern.maxvnodes: 100000 > kern.sigqueue.alloc_fail: 0 > kern.sigqueue.overflow: 371 > kern.sigqueue.preallocate: 1024 > kern.sigqueue.max_pending_per_proc: 128 > kern.minvnodes: 25000 > vfs.freevnodes: 22 > vfs.wantfreevnodes: 25000 > vfs.numvnodes: 100005 > debug.vnlru_nowhere: 811 >=20 > It is not on plain FreeBSD, but the GNU/kFreeBSD > changes to the kernel are minimal. >=20 > The KTR trace of KTR_VFS from 8-stable is at > http://asdfasdf.debian.net/~salinger/ktr.gz >=20 > Thanks for any hints. Is machine completely stuck, or is it makes small steps once in a second ? You could look at the "ps alx" output, or ps output from ddb. Look for the processes in the "vnlru" state. If my suspection is true, you have such processes. The typical cause is the large directory hierarchy. vnlru daemon does not reclaim the free vnodes that are sources of namecache records. You can either increase kern.maxvnodes, the default value is very conservative on amd64, where a lot of KVA is available. On the other hand, increase of the value on i386 could easily cause KVA exhaustion. Another possible workaround, if you do not need path resolutions in /proc or lsof(1), is to set sysctl vfs.vlru_allow_cache_src=3D1. --LQhvuUkKKd6r3A8m Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (FreeBSD) iEYEARECAAYFAku2P04ACgkQC3+MBN1Mb4jY5wCgz2OVZX3eL7db9OJo4aP7WWhY qEIAnA0gYOGJ1el2UNPEfM4A+1sMVizM =aGyN -----END PGP SIGNATURE----- --LQhvuUkKKd6r3A8m--