From: Maxim Levitsky <maximlevitsky@gmail.com>
To: LKML <linux-kernel@vger.kernel.org>
Cc: linux-mm@kvack.org
Subject: Guaranteed allocation of huge pages (1G) using movablecore=N doesn't seem to work at all
Date: Sat, 4 Nov 2017 11:55:14 +0200 [thread overview]
Message-ID: <CACAwPwY0owut+314c5sy7jNViZqfrKy3sSf1hjLTocXefrz3xA@mail.gmail.com> (raw)
Hi!
My system has 64G of ram and I want to create 32 1G huge pages to use
in KVM virtualization,
on demand, only when VM is running.
So I booted the kernel with
'hugepagesz=1G hugepages=0 default_hugepagesz=1G movablecore=40G'
However I still can't allocate the pages reliably.
For instance this simple script is enough to make it not possible to
even allocate one 1G huge page after few dozens of iterations:
while true ; do
sudo hugeadm --enable-zone-movable --pool-pages-min 1G:0G
sudo hugeadm --enable-zone-movable --pool-pages-min 1G:60G
done
I disabled mlock systemwide (now ulimit -l shows 0), I still see 8
pages mlocked in zone 'Movable' but this is not enough to explain
this
nr_mlock 8
I do have around 64GB of swap too, but I see no even an attempt to use it.
# free
total used free shared buff/cache available
Mem: 65887928 1748344 62640276 61688 1499308 62053832
Swap: 67108860 0 67108860
Any idea about what is going on?
This was tested on 4.14.0-rc5 (my custom compiled) and on several
older kernels (4.10,4.12,4.13) from ubuntu repositories.
Disabling/enabling transparent huge pages in the kernel config didn't
make a difference.
VT-d was enabled during the tests (intel_iommu=on,igfx_off) if that
would make any difference, but no VM was started when I run the above
script, in fact I run it just after the system booted.
Best regards,
Maxim Levitsky
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next reply other threads:[~2017-11-04 9:55 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-04 9:55 Maxim Levitsky [this message]
2017-11-06 13:05 ` Michal Hocko
2017-11-06 17:03 ` Maxim Levitsky
2017-11-06 17:11 ` Michal Hocko
[not found] ` <CACAwPwZuiT9BfunVgy73KYjGfVopgcE0dknAxSLPNeJB8rkcMQ@mail.gmail.com>
[not found] ` <CACAwPwZqFRyFJhb7pyyrufah+1TfCDuzQMo3qwJuMKkp6aYd_Q@mail.gmail.com>
[not found] ` <CACAwPwbA0NpTC9bfV7ySHkxPrbZJVvjH=Be5_c25Q3S8qNay+w@mail.gmail.com>
[not found] ` <CACAwPwamD4RL9O8wujK_jCKGu=x0dBBmH9O-9078cUEEk4WsMA@mail.gmail.com>
[not found] ` <CACAwPwYKjK5RT-ChQqqUnD7PrtpXg1WhTHGK3q60i6StvDMDRg@mail.gmail.com>
[not found] ` <CACAwPwav-eY4_nt=Z7TQB8WMFg+1X5WY2Gkgxph74X7=Ovfvrw@mail.gmail.com>
[not found] ` <CACAwPwaP05FgxTp=kavwgFZF+LEGO-OSspJ4jH+Y=_uRxiVZaA@mail.gmail.com>
[not found] ` <CACAwPwY5ss_D9kj7XoLVVkQ9=KXDFCnyDzdoxkGxhJZBNFre3w@mail.gmail.com>
2017-11-06 17:36 ` Maxim Levitsky
2017-11-06 18:04 ` Michal Hocko
2017-11-06 18:13 ` Maxim Levitsky
2017-11-06 18:32 ` Michal Hocko
2017-11-06 19:31 ` Michal Hocko
2017-11-06 22:32 ` Maxim Levitsky
2017-11-07 8:20 ` Vlastimil Babka
2017-11-07 8:30 ` 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:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CACAwPwY0owut+314c5sy7jNViZqfrKy3sSf1hjLTocXefrz3xA@mail.gmail.com \
--to=maximlevitsky@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox