From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andres Freund <andres@anarazel.de>
Cc: pgsql-hackers@postgresql.org
Subject: Re: munmap() failure due to sloppy handling of hugepage size
Date: Wed, 12 Oct 2016 16:33:38 -0400
Message-ID: <31426.1476304418@sss.pgh.pa.us> (raw)
In-Reply-To: <25C01331-B1AE-45A6-BD1F-D8AE2DE40F86@anarazel.de>
References: <31056.1476303954@sss.pgh.pa.us>
<25C01331-B1AE-45A6-BD1F-D8AE2DE40F86@anarazel.de>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
Andres Freund <andres@anarazel.de> writes:
> On October 12, 2016 1:25:54 PM PDT, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> A little bit of research suggests that on Linux the thing to do would
>> be to get the actual default hugepage size by reading /proc/meminfo and
>> looking for a line like "Hugepagesize: 2048 kB".
> We had that, but Heikki ripped it out when merging... I think you're supposed to use /sys to get the available size.
According to
https://www.kernel.org/doc/Documentation/vm/hugetlbpage.txt
looking into /proc/meminfo is the longer-standing API and thus is
likely to work on more kernel versions. Also, if you look into
/sys then you are going to see multiple possible values and it's
not clear how to choose the right one.
regards, tom lane
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, andres@anarazel.de
Subject: Re: munmap() failure due to sloppy handling of hugepage size
In-Reply-To: <31426.1476304418@sss.pgh.pa.us>
References: <31056.1476303954@sss.pgh.pa.us> <25C01331-B1AE-45A6-BD1F-D8AE2DE40F86@anarazel.de> <31426.1476304418@sss.pgh.pa.us>
* 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