LKML Archive on
help / color / mirror / Atom feed
From: Alex Richman <>
Subject: mlock() confusing 1 half of system RAM limit
Date: Fri, 1 Jun 2018 10:53:57 +0100	[thread overview]
Message-ID: <> (raw)


I'm seeing a 1/2 of system RAM limit when calling mlock().  mlock(2) says:
 > ENOMEM (Linux 2.4 and earlier) the calling process tried to lock more 
than half of RAM.
Which implies to me that the 1 half of system RAM limit should be only 
Linux 2.4 and earlier, but I'm running linux 4.4.127 and still seeing 
the limit.

This is on a system with 66007168 KB total memory, locking 33794621440 
bytes works, locking 33795653632 bytes does not work.

Anyone know if this is the man pages or the kernel or something unrelated?

More details here:

- Alex.

Alex Richman
GB Labs
2 Orpheus House,
Calleva park,
Tel:+44 (0)118 455 5000

The information contained in this message and any attachment may be proprietary, confidential and privileged.
If the reader of this message is not the intended recipient, or an employee or agent responsible for delivering
this message to the intended recipient, you are hereby notified that any dissemination, distribution or copying
of this communication is strictly prohibited. If you received this communication in error, please contact me immediately,
and delete the communication (including attachments, if applicable) from any computer or network system.

             reply	other threads:[~2018-06-01 10:23 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-01  9:53 Alex Richman [this message]
2018-06-01 11:44 ` Michal Hocko
2018-06-01 12:26   ` Alex Richman
2018-06-01 13:05     ` Michal Hocko
2018-06-01 13:24       ` Alex Richman
2018-06-01 13:41         ` Michal Hocko

Reply instructions:

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

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

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \
    --subject='Re: mlock() confusing 1 half of system RAM limit' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).