From owner-freebsd-questions@FreeBSD.ORG Thu Jun 5 12:31:17 2008 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 6723E1065689 for ; Thu, 5 Jun 2008 12:31:17 +0000 (UTC) (envelope-from d.hill@yournetplus.com) Received: from duane.dbq.yournetplus.com (duane.dbq.yournetplus.com [65.124.230.214]) by mx1.freebsd.org (Postfix) with ESMTP id 36DE78FC1C for ; Thu, 5 Jun 2008 12:31:17 +0000 (UTC) (envelope-from d.hill@yournetplus.com) Received: by duane.dbq.yournetplus.com (Postfix, from userid 1001) id 753C927E42B; Thu, 5 Jun 2008 12:31:16 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by duane.dbq.yournetplus.com (Postfix) with ESMTP id 6F77227E41F; Thu, 5 Jun 2008 12:31:16 +0000 (UTC) Date: Thu, 5 Jun 2008 12:31:16 +0000 (UTC) From: D Hill X-X-Sender: d.hill@duane.dbq.yournetplus.com To: Mark Tinguely In-Reply-To: <200806042346.m54NkgaE031774@casselton.net> Message-ID: References: <200806042346.m54NkgaE031774@casselton.net> User-Agent: Alpine 1.10 (BSF 962 2008-03-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: freebsd-questions@freebsd.org Subject: Re: vm.pmap.shpgperproc syslog messages 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: Thu, 05 Jun 2008 12:31:18 -0000 On Wed, 4 Jun 2008 at 18:46 -0500, tinguely@casselton.net confabulated: >> I just noticed today I'm starting to get messages in ../messages stating: >> >> Approaching the limit on PV entries, consider increasing either the >> vm.pmap.shpgperproc or the vm.pmap.pv_entry_max sysctl. >> >> I did some searching and don't really know what is going on. I did a >> search using sysctl for all pmap knobs and this is what they are >> currently: >> >> vm.pmap.pmap_collect_active: 0 >> vm.pmap.pmap_collect_inactive: 0 >> vm.pmap.pv_entry_spare: 51310 >> vm.pmap.pv_entry_allocs: 67575721858 >> vm.pmap.pv_entry_frees: 67574088800 >> vm.pmap.pc_chunk_tryfail: 0 >> vm.pmap.pc_chunk_frees: 416252902 >> vm.pmap.pc_chunk_allocs: 416262928 >> vm.pmap.pc_chunk_count: 10026 >> vm.pmap.pv_entry_count: 1633059 >> vm.pmap.shpgperproc: 500 >> vm.pmap.pv_entry_max: 6125408 >> >> I did increased vm.pmap.shpgperproc to 500 from 200 and immediately saw >> vm.pmap.pv_entry_max increase as well. >> >> This server is a Dell PowerEdge 6850 with four 3.0Gz dual core Zeon >> processors and 12Gb ram. The server's only purpose is a spam filter. It is >> running SpamAssassin, ClamAV, Postfix and MySQL. The server is pretty >> memory intensive. Active memory usually doesn't drop below 8Gb. >> SpamAssassin usually has roughly 24 children running all the time >> consuming ~120Mb per child. MySQL is currently taking ~5.5Gb. >> >> Can someone shed light on what is going on or what needs to be tweaked? > > pv_entry are entries that are used to keep track of which processes are > sharing a physical page. > > pv_entry are allocated in groups (chunks to fill a page) - 168 for the AMD64. > > The more RAM and processes that you have, the more probably that the pages > are shared in multiple processes and more pv_entrys are needed. > > It looks like you are well below the pv_entry_max with shpgperproc at 500. I figured out what was going on when the messages hit the ../messages log. I have a cronjob that executes a MySQL script to optimize tables. It was during that time when the syslog messages were logged. Since increasing vm.pmap.shpgperproc yesterday, I haven't seen anything in the logs. Thanks for the response.