From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42346) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eSIAb-0003Ic-8B for guix-patches@gnu.org; Fri, 22 Dec 2017 02:55:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eSIAY-0005eD-3i for guix-patches@gnu.org; Fri, 22 Dec 2017 02:55:05 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:38108) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eSIAX-0005e7-VF for guix-patches@gnu.org; Fri, 22 Dec 2017 02:55:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1eSIAX-00088R-KU for guix-patches@gnu.org; Fri, 22 Dec 2017 02:55:01 -0500 Subject: [bug#29409] Remove hugetlb control group on ARM32. Resent-Message-ID: References: <877euhtjkj.fsf@gmail.com> <87ind19pok.fsf@gmail.com> <20171221095752.1a018320@scratchpost.org> <87tvwk3wpk.fsf@gnu.org> From: Mathieu Othacehe In-reply-to: <87tvwk3wpk.fsf@gnu.org> Date: Fri, 22 Dec 2017 08:54:16 +0100 Message-ID: <87vagzb3kn.fsf@gmail.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Ludovic =?UTF-8?Q?Court=C3=A8s?= , Danny Milosavljevic , Tobias Geerinckx-Rice Cc: 29409@debbugs.gnu.org --=-=-= Content-Type: text/plain Hi Tobias, Danny and Ludo, Thanks for your answers! > Indeed. So actually we can probably remove it altogether. > > We could simply do that and keep the definition around for when we need > it. > > Thoughts? Seems ok to me. I also proposed a patch to move %control-groups from %base-file-systems to %elogind-file-systems. WDYT ? Thanks, Mathieu --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-file-systems-Do-not-mount-hugetlb-cgroup-filesystem.patch >From a531af25b3cffeb70e5681ef70ced564378f2db7 Mon Sep 17 00:00:00 2001 From: Mathieu Othacehe Date: Fri, 22 Dec 2017 08:42:29 +0100 Subject: [PATCH 1/2] file-systems: Do not mount hugetlb cgroup filesystem. On ARM32 without LPAE support, hugetlb control group is not supported. As it is not needed by elogind, remove it for all platforms. * gnu/system/file-systems.scm (%control-groups): Remove hugetlb from control groups platforms. --- gnu/system/file-systems.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/system/file-systems.scm b/gnu/system/file-systems.scm index 27734e892..9de465167 100644 --- a/gnu/system/file-systems.scm +++ b/gnu/system/file-systems.scm @@ -279,7 +279,7 @@ TARGET in the other system." ;; parent directory. (dependencies (list parent)))) '("cpuset" "cpu" "cpuacct" "memory" "devices" "freezer" - "blkio" "perf_event" "hugetlb"))))) + "blkio" "perf_event"))))) (define %elogind-file-systems ;; We don't use systemd, but these file systems are needed for elogind, -- 2.15.0 --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0002-file-systems-Move-control-groups-from-base-file-syst.patch >From 4a28602843a661989c687086af009481dab05eed Mon Sep 17 00:00:00 2001 From: Mathieu Othacehe Date: Fri, 22 Dec 2017 08:43:24 +0100 Subject: [PATCH 2/2] file-systems: Move %control-groups from %base-file-systems to %elogind-file-systems. * gnu/system/file-systems.scm (%base-file-systems): Move %control-groups from here, to ... (%elogind-file-systems): ... here. --- gnu/system/file-systems.scm | 63 +++++++++++++++++++++++---------------------- 1 file changed, 32 insertions(+), 31 deletions(-) diff --git a/gnu/system/file-systems.scm b/gnu/system/file-systems.scm index 9de465167..7f5afb00f 100644 --- a/gnu/system/file-systems.scm +++ b/gnu/system/file-systems.scm @@ -284,41 +284,42 @@ TARGET in the other system." (define %elogind-file-systems ;; We don't use systemd, but these file systems are needed for elogind, ;; which was extracted from systemd. - (list (file-system - (device "none") - (mount-point "/run/systemd") - (type "tmpfs") - (check? #f) - (flags '(no-suid no-dev no-exec)) - (options "mode=0755") - (create-mount-point? #t)) - (file-system - (device "none") - (mount-point "/run/user") - (type "tmpfs") - (check? #f) - (flags '(no-suid no-dev no-exec)) - (options "mode=0755") - (create-mount-point? #t)) - ;; Elogind uses cgroups to organize processes, allowing it to map PIDs - ;; to sessions. Elogind's cgroup hierarchy isn't associated with any - ;; resource controller ("subsystem"). - (file-system - (device "cgroup") - (mount-point "/sys/fs/cgroup/elogind") - (type "cgroup") - (check? #f) - (options "none,name=elogind") - (create-mount-point? #t) - (dependencies (list (car %control-groups)))))) + (append + (list (file-system + (device "none") + (mount-point "/run/systemd") + (type "tmpfs") + (check? #f) + (flags '(no-suid no-dev no-exec)) + (options "mode=0755") + (create-mount-point? #t)) + (file-system + (device "none") + (mount-point "/run/user") + (type "tmpfs") + (check? #f) + (flags '(no-suid no-dev no-exec)) + (options "mode=0755") + (create-mount-point? #t)) + ;; Elogind uses cgroups to organize processes, allowing it to map PIDs + ;; to sessions. Elogind's cgroup hierarchy isn't associated with any + ;; resource controller ("subsystem"). + (file-system + (device "cgroup") + (mount-point "/sys/fs/cgroup/elogind") + (type "cgroup") + (check? #f) + (options "none,name=elogind") + (create-mount-point? #t) + (dependencies (list (car %control-groups))))) + %control-groups)) (define %base-file-systems ;; List of basic file systems to be mounted. Note that /proc and /sys are ;; currently mounted by the initrd. - (append (list %pseudo-terminal-file-system - %shared-memory-file-system - %immutable-store) - %control-groups)) + (list %pseudo-terminal-file-system + %shared-memory-file-system + %immutable-store)) ;; File systems for Linux containers differ from %base-file-systems in that ;; they impose additional restrictions such as no-exec or need different -- 2.15.0 --=-=-=--