Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1YGtxp-0002GA-Np for pgsql-admin@arkaria.postgresql.org; Thu, 29 Jan 2015 18:37:14 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1YGtxp-0002BN-3r for pgsql-admin@arkaria.postgresql.org; Thu, 29 Jan 2015 18:37:13 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1YGtxn-0002BA-QT for pgsql-admin@postgresql.org; Thu, 29 Jan 2015 18:37:12 +0000 Received: from mail-yk0-x234.google.com ([2607:f8b0:4002:c07::234]) by makus.postgresql.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.80) (envelope-from ) id 1YGtxk-0000zN-7X for pgsql-admin@postgresql.org; Thu, 29 Jan 2015 18:37:09 +0000 Received: by mail-yk0-f180.google.com with SMTP id 131so14676006ykp.11 for ; Thu, 29 Jan 2015 10:37:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=lEAH5V4gvnUgGy+ltyy4KnUznRSZLsm+ksTtqKRugok=; b=lddVF9UueY4MQruDWoSrAolkiP0a+Hewb0QSyOgQSTYuakkeDxBNIqm+tbl1R73TLD UzgPwGRjEWvdrKPBwT9cx1+elrwdvRUCp7i2/NbPaUQkSK/T99RBW4d3Q3NnMh1qBP0T yxtIC85DkahSsJQs9p7gdE1F2nU0NImcFcDnO3PClRBWnTyEsufy4++aaIX2wsLoTGsA ad+ZjtZrtncBPtEhu/0IKyrEOi6Lv2j2GD1q/omni5gktoxxRR92fRsv4StM/6vC0IL/ Xjf/cJCfJAcq7aA6VJYXKba0RDuwJlspeyZILSku47GeYCm2TV2P5oNAJYbHOdY/lZg6 /0EA== X-Received: by 10.170.159.137 with SMTP id a131mr1336352ykd.82.1422556626899; Thu, 29 Jan 2015 10:37:06 -0800 (PST) Received: from [192.168.254.3] (h77.89.102.166.static.ip.windstream.net. [166.102.89.77]) by mx.google.com with ESMTPSA id w15sm5005874yhn.50.2015.01.29.10.37.05 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 29 Jan 2015 10:37:06 -0800 (PST) Message-ID: <54CA7DCC.5050209@gmail.com> Date: Thu, 29 Jan 2015 13:37:00 -0500 From: John Scalia User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: Tom Lane CC: "pgsql-admin@postgresql.org" Subject: Re: hugepage configuration for V.9.4.0 References: <54CA73CE.1050503@gmail.com> <11110.1422555496@sss.pgh.pa.us> In-Reply-To: <11110.1422555496@sss.pgh.pa.us> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -2.7 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-admin Precedence: bulk Sender: pgsql-admin-owner@postgresql.org On 1/29/2015 1:18 PM, Tom Lane wrote: > John Scalia writes: >> I'm certain that I'm no expert for this one, as I've never had to configure this parameter for anything prior, but I continue to get a startup error when I try to use this. The >> server is a VM running CentOS 6.5 with 4 Gb allocated to it. When I started setting "huge_pages = on", the server reported: >> %FATAL: could not map anonymous shared memory: Cannot allocate memory >> %HINT: this error usually means that PostgreSQL's request for a shared memory segment exceeded available memory, swap space, or huge pages. To reduce the request size (currently >> 1124876288 bytes), reduce PostgreSQL's shared memory usage, perhaps by reducing shared_buffers or max_connections. >> Further research showed that server's /sys/kernel/mm/transparent_hugepage/enabled file contained "[always] madvise never" >> As I was concerned about the "always" setting, I used "cat madvise > " to the file so it reported "always [madvise] never" I even set this in /etc/rc.local and performed a reboot. > FWIW, I think that the transparent_hugepage setting is irrelevant to this. > The whole point here is that we're explicitly asking for a hugepage memory > segment, so the OS doesn't have to try to make it transparent. > > What might be happening is that when requesting a hugepage segment, we > actually round up the request (here claimed to be 1124876288 bytes) > to the next 2MB boundary. Is it possible your kernel settings are > such that the slightly larger request fails? > > Also, there may well be request limits that apply specifically to hugepage > segments; I don't know too much about that. > > regards, tom lane > Thanks to all that responded. I really kind of figured that a 4Gb server was too small, but I'm limited to that by our virtual server configuration system. I'll look into how this kernel is configured, Tom, but is there something specific that you know of for me to examine? FWIW, I didn't build this kernel as I have to choose one from the server build page when I try to create the system. I guess I could download the sources to do a build on it, once it's running, but I'm think it's really not the worth the effort for one this small. -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-admin