From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43604) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dxewf-0007Al-4s for guix-patches@gnu.org; Thu, 28 Sep 2017 15:58:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dxewc-0002KE-4k for guix-patches@gnu.org; Thu, 28 Sep 2017 15:58:05 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:56691) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dxewc-0002K8-12 for guix-patches@gnu.org; Thu, 28 Sep 2017 15:58:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dxewb-000472-Pw for guix-patches@gnu.org; Thu, 28 Sep 2017 15:58:01 -0400 Subject: [bug#28635] [PATCH 1/2] vm: Add a minimum root size. References: <20170928205416.647d53d7@cbaines.net> In-Reply-To: <20170928205416.647d53d7@cbaines.net> Resent-Message-ID: From: Christopher Baines Date: Thu, 28 Sep 2017 20:57:53 +0100 Message-Id: <20170928195754.28688-1-mail@cbaines.net> 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: 28635@debbugs.gnu.org * gnu/system/vm.scm (qemu-image): When guessing the root-size, use a lower bound of 20 MiB, otherwise the root file system size is sometimes 0 MiB in size. --- gnu/system/vm.scm | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gnu/system/vm.scm b/gnu/system/vm.scm index 78143e4f7..d340a8563 100644 --- a/gnu/system/vm.scm +++ b/gnu/system/vm.scm @@ -304,9 +304,12 @@ the image." #:register-closures? #$register-closures? #:system-directory #$os-drv)) (root-size #$(if (eq? 'guess disk-image-size) - #~(estimated-partition-size - (map (cut string-append "/xchg/" <>) - graphs)) + #~(max + ;; Minimum 20 MiB root size + (* 20 (expt 2 20)) + (estimated-partition-size + (map (cut string-append "/xchg/" <>) + graphs))) (- disk-image-size (* 50 (expt 2 20))))) (partitions (list (partition -- 2.14.1