From owner-freebsd-stable@FreeBSD.ORG Wed Jan 14 14:18:58 2015 Return-Path: Delivered-To: freebsd-stable@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A408A14E for ; Wed, 14 Jan 2015 14:18:58 +0000 (UTC) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7DF2080E for ; Wed, 14 Jan 2015 14:18:58 +0000 (UTC) Received: from new-host.home (pool-173-70-85-31.nwrknj.fios.verizon.net [173.70.85.31]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 8E257B91E; Wed, 14 Jan 2015 09:18:57 -0500 (EST) Message-ID: <54B67AD1.5050609@FreeBSD.org> Date: Wed, 14 Jan 2015 09:18:57 -0500 From: John Baldwin User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:31.0) Gecko/20100101 Thunderbird/31.3.0 MIME-Version: 1.0 To: Shane Ambler , FreeBSD stable Subject: Re: Question about sysctl's References: <54B51FA0.6040307@ShaneWare.Biz> In-Reply-To: <54B51FA0.6040307@ShaneWare.Biz> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Wed, 14 Jan 2015 09:18:57 -0500 (EST) X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Jan 2015 14:18:58 -0000 On 1/13/15 8:37 AM, Shane Ambler wrote: > > I am curious about two particular sysctl's, they are described as > > vm.stats.vm.v_wire_count: Wired pages > vm.max_wired: System-wide limit to wired page count > > Now to me that sounds like v_wire_count should never get higher than > max_wired, yet today I have a v_wire_count that is ~40% above the > max_wired. > > vm.stats.vm.v_wire_count: 938417 > vm.max_wired: 662820 > > So is this an error or do these two work differently than they appear? Not all wired allocations are subject to the limit (which isn't obvious from the description). Anything that calls 'malloc()' in the kernel will use wired memory for example, and those generally aren't subject to the limit. However, user-initiated operations (like a sysctl buffer or user pages wired via mlock()) are. -- John Baldwin