Received: by 10.223.164.221 with SMTP id h29csp371036wrb; Fri, 3 Nov 2017 16:33:10 -0700 (PDT) X-Google-Smtp-Source: ABhQp+QjB52IYBNyPR9PeJUJhWbA2lq+BWCWzyGl2RfloZgSTLaXrG20L7/KKNSQQmNZ8Tm6yy5z X-Received: by 10.98.219.134 with SMTP id f128mr9084670pfg.85.1509751990515; Fri, 03 Nov 2017 16:33:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1509751990; cv=none; d=google.com; s=arc-20160816; b=lonaXsJoZsx3fOyto3DScSCyhf9lFUd6NLRh2EPDnnV1BFt7aNb10dZDanUN7ktRMi FHKrtDlQjb4PxRjmSB3//GPLzbua33zYxtVFSvJ01Z0O0fDMoNY810SM4zJJ9uA6frLs TcjEFK3GYqhAhYoyeKJE3l76EgAX3yqx1+bXYNWknPPGd9F2mc+emck1wOUjUItd6/R0 K9t/FUZzAO7HOwC0l/Wqju/LwIscRfadxO0bBgMsJQhV4bsURGeErFiQPEd7RERDwpWz tLWXDqE5gt5Rh5qlvOXNNZlyqpeZhjLhzc/V1IJIbNoi2WnftOTkqXEc2UM0olHyYi4H 8Waw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:subject:message-id:date:from :mime-version:dkim-signature:arc-authentication-results; bh=TJGT+vyclcQQrYMzVdwj9Nela9pWzDAAi1Q3OrZO8Nw=; b=TjtI+/ir6T2iKY5w4Dbk9ii6udY8v0IkdY4d8o7kU2amuO5YFcfuiDPhHYYxTh8TQe 5aeWLbso89ky9t1gvRQxupBH7f3w7aKuVtwX2dX3FnTH4JvkhTyPQJjCsMgz3Z8v5EUl XxRGsmjPJd+dmCD9omaVDV9ZpjUsrRLr8PvJ1peO5Dn5nqMxdYwBShN+9pO/cXWGBZaB xfa83ZaY0T/c2iELPXPPbIGLPglanLVTWez1HMU808DfV/V1UrCGI3QSDVHzt9JS2YXr /SGUuVmkfhGDmVPt7usWJ4YopXU6BjECqBSw01E0bhvBI0JYChAeXUBbG9AF7pn6vXUj 4qFw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=JYEWCOKN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y2si6869382pgo.89.2017.11.03.16.32.57; Fri, 03 Nov 2017 16:33:10 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=JYEWCOKN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756018AbdKCXbf (ORCPT + 92 others); Fri, 3 Nov 2017 19:31:35 -0400 Received: from mail-ua0-f172.google.com ([209.85.217.172]:57259 "EHLO mail-ua0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752472AbdKCXbe (ORCPT ); Fri, 3 Nov 2017 19:31:34 -0400 Received: by mail-ua0-f172.google.com with SMTP id n22so2989732uaj.13 for ; Fri, 03 Nov 2017 16:31:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=TJGT+vyclcQQrYMzVdwj9Nela9pWzDAAi1Q3OrZO8Nw=; b=JYEWCOKNUl2HtN+cZF6SWyfz2izV66Gej/O4qS6A9Er2WhzWozAcYDfqju6cOjZG7L 5uUIc7tajncd/WD8Yd2nYTCmvKtMCnOx4F1p0hUyp+z5Vm+s85eGLSp99pyDKk/KF80P qgS7lxP5jiCHWlQTSbmiWHMiYHDENmMgIgE/hgph5jIoA2goTU6HKHdyoc/2RU+lEtBj HYFSy/PqHxSkRi3exX2M8sdZ+N7yulsgL+ORP4/TRYC0vtrNSnmOlmuniqTzTkhmjhBN BMMgwTaqykJ4E5w800Ljma+pr1icB2/EcqobBLmm+C63ak4DLkqWnEOwlhgPEfIzsW9I IZbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=TJGT+vyclcQQrYMzVdwj9Nela9pWzDAAi1Q3OrZO8Nw=; b=DrcW5+EoEKeNKcxfwUZRLKstu72bbByfZyvWpgaiOWgz64upKJKg3d9TPpXUuUuMTD 48NKeQ+eO1EIq02kHR/h2I9v6hoRe/ysqH3AA78ouHFwSVFJKjxveIIMzc5LskU6JyUl rgN1Ui5bpywI+SnMyX8lGdzuxLforJ6t/1db11HkqdDgZUjE6nDBCFxAb7r2U8hVe8Qh wSC3njJINzUtnZ7510y+PdqZgM9KikhUfTZr8ruJ+4NqHnuixmPjR5/9T3UW7czm7mFw Pb8jvL/KhDjRfJSPrwhLbXbgKueY++G72NsgCubVIa9zQhHvORClit2zpfse/QJdgLN3 dYqg== X-Gm-Message-State: AMCzsaUDpcypr4seYuCYHCQ3iUAXcCPwNbaP7hFhlgZHmRgJaltwK9Aa 7JdTN6Rsbt4cLD2EOXfW0hLrxRFdhqrVJUzaeqrScg== X-Received: by 10.176.3.46 with SMTP id 43mr7422464uat.55.1509751893329; Fri, 03 Nov 2017 16:31:33 -0700 (PDT) MIME-Version: 1.0 Received: by 10.103.115.66 with HTTP; Fri, 3 Nov 2017 16:31:12 -0700 (PDT) From: Maxim Levitsky Date: Sat, 4 Nov 2017 01:31:12 +0200 Message-ID: Subject: Collapse all Print all In new window Guaranteed allocation of huge pages (1G) using movablecore=N doesn't seem to work at all. To: LKML Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 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) is 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 From 1583088099702011897@xxx Fri Nov 03 23:07:41 +0000 2017 X-GM-THRID: 1583088099702011897 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread