pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Scott Whitney <scott@journyx.com>
To: John Scalia <jayknowsunix@gmail.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: hugepage configuration for V.9.4.0
Date: Thu, 29 Jan 2015 12:02:53 -0600 (CST)
Message-ID: <409239978.198205.1422554572999.JavaMail.zimbra@mail.int.journyx.com> (raw)
In-Reply-To: <1630087617.198201.1422554556751.JavaMail.zimbra@mail.int.journyx.com>
References: <54CA73CE.1050503@gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-admin>

Usually I tweak the kernel shmmax, shmmni and shmall values in /proc/sys. 

4GB _might_ be too small, in fact, but tweaking those parameters ought to get you started at least. 

http://www.postgresql.org/docs/9.0/static/kernel-resources.html 

----- On Jan 29, 2015, at 11:54 AM, John Scalia <jayknowsunix@gmail.com> wrote: 

> 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.

> Regardless of which setting, however, I receive the same failure message. Per
> its suggestions, my settings are shared_buffers = 1024Mb and max_connections =
> 100.

> Should I reduce these values? Is a 4 Gb test server too small to use huge_pages?
> The server does run just fine with "huge_pages = try" or "off". What else
> should I be checking?
> --
> Jay

> --
> Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-admin

Journyx, Inc.
7600 Burnet Road #300
Austin, TX 78757
www.journyx.com

p 512.834.8888
f 512.834.8858
Do you receive our promotional emails? You can subscribe or unsubscribe to those emails at http://go.journyx.com/emailPreference/e/4932/714

view thread (6+ messages)  latest in thread

Message-ID: <409239978.198205.1422554572999.JavaMail.zimbra@mail.int.journyx.com>
Permalink:  ../409239978.198205.1422554572999.JavaMail.zimbra@mail.int.journyx.com/
Also on:    postgresql.org/message-id/409239978.198205.1422554572999.JavaMail.zimbra@mail.int.journyx.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: scott@journyx.com, jayknowsunix@gmail.com
  Subject: Re: hugepage configuration for V.9.4.0
  In-Reply-To: <409239978.198205.1422554572999.JavaMail.zimbra@mail.int.journyx.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox