From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:bcc0::]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id GNNyKSwAbWDm/QAAgWs5BA (envelope-from ) for ; Wed, 07 Apr 2021 02:43:24 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id YL9EIywAbWD4FAAAB5/wlQ (envelope-from ) for ; Wed, 07 Apr 2021 00:43:24 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id A8337A1D7 for ; Wed, 7 Apr 2021 02:43:23 +0200 (CEST) Received: from localhost ([::1]:44108 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lTwHx-0000KD-Kc for larch@yhetil.org; Tue, 06 Apr 2021 20:43:21 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58580) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lTwHd-0000K2-Vj for bug-guix@gnu.org; Tue, 06 Apr 2021 20:43:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:59220) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lTwHd-0001PE-Oa for bug-guix@gnu.org; Tue, 06 Apr 2021 20:43:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lTwHd-0006Bt-MA for bug-guix@gnu.org; Tue, 06 Apr 2021 20:43:01 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#47225: QEMU warning about performance Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Wed, 07 Apr 2021 00:43:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 47225 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Leo Famulari Received: via spool by 47225-submit@debbugs.gnu.org id=B47225.161775616823774 (code B ref 47225); Wed, 07 Apr 2021 00:43:01 +0000 Received: (at 47225) by debbugs.gnu.org; 7 Apr 2021 00:42:48 +0000 Received: from localhost ([127.0.0.1]:42533 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lTwHQ-0006BO-9G for submit@debbugs.gnu.org; Tue, 06 Apr 2021 20:42:48 -0400 Received: from mail-qt1-f171.google.com ([209.85.160.171]:40762) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lTwHO-0006BA-63 for 47225@debbugs.gnu.org; Tue, 06 Apr 2021 20:42:47 -0400 Received: by mail-qt1-f171.google.com with SMTP id i19so12588229qtv.7 for <47225@debbugs.gnu.org>; Tue, 06 Apr 2021 17:42:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=stKJyCGOCu4OibouU9OXEg2v7EH38meaJ7u6SsiPpdU=; b=HD00DqfL/slzJ8u+kwkZsL/qveU+ZTIrJzy+Gmo1pw/eKOx1OPSftgGyF8S7mMNDsu EHD5l37tkdFYxux9hkxbkpP1uzz7ZrehHn4TShX63BHCb8CsqfedZ1HYKNgjCz4UVLeS 3vFxiQ6CqK1WQ8MgjF2mgadk3OsAwtDMG0BkHRcTFqsy11oB3mgPVvY2aH0Yo3VLZXyu kDkhgkFfN9GtC4u4W9B/hKX6MUhrumjrPlEvtaQzCs9qRJt5x/ZXXYJP0OZTpkbWg1nE zrMu+UmO/sWgp9etFc6kqN40qvBlihh7j0PBbMzb3F4IeMcVo8eowy0Lau3G0w7ggjpV nvRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=stKJyCGOCu4OibouU9OXEg2v7EH38meaJ7u6SsiPpdU=; b=ViFzmkYnSuDZb9K2fZKHC8ZAlBE6Mc2EX0wOuHt/Eko0ln+NmHhbSrMPQJbx0ncW5w IwTKpP8vjYiLyDf/ig8gytEIcACyNpwDjW1b+P84kDKAsbq3YYbvwIVuYNMwPtI14dWz rmYE7J2vFbawld6vXm+FmPVNqXoqzchfCqdr/ln+bQA7/RRzHCwC95i2GTDC9vcY5e1c 74zCDpXbfqQEEyCwYcRejJcpDPj8/RQ9kU5v969vH1JcN4uLJWTuv05z1riYVwUV0PRr uxAtVfPK/s5WCL8vGLrGQ98dfQGIrDQSc0Gt6JUhyJy3UdQXnU6sW1a5qw6ReybuRBNY tuBQ== X-Gm-Message-State: AOAM533vNU9crnhKKnYDZqzGfCcNlorSLCwtYPB/rKAZWyfMVFs2HxXJ ZqsCv9rMdKFkRAJboZurvuOl3zTWUYQ= X-Google-Smtp-Source: ABdhPJxpWNagFR329SUDTebRoaqaOuyspfycW3EUCQjqUfmPXVWCdm95/0y+AvuRdDCAuUQQqzTnjA== X-Received: by 2002:ac8:110f:: with SMTP id c15mr559937qtj.251.1617756160549; Tue, 06 Apr 2021 17:42:40 -0700 (PDT) Received: from hurd (dsl-149-132.b2b2c.ca. [66.158.149.132]) by smtp.gmail.com with ESMTPSA id k28sm17525949qki.101.2021.04.06.17.42.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Apr 2021 17:42:40 -0700 (PDT) From: Maxim Cournoyer References: <87zgybnl8o.fsf@gmail.com> Date: Tue, 06 Apr 2021 20:42:38 -0400 In-Reply-To: (Leo Famulari's message of "Tue, 6 Apr 2021 18:15:19 -0400") Message-ID: <87v98zncw1.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: 47225@debbugs.gnu.org Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1617756204; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=stKJyCGOCu4OibouU9OXEg2v7EH38meaJ7u6SsiPpdU=; b=bc44aqIpU6U3cR1vw7kqiUz8GxsaqIsJtKStwAQ2uqMFgGaOlHzFkeTNg0y8vz/A8W/ZYs +x1t0lgy2Glt2uOzxxWDmMQrtDCQEBQVR+4XZk4wtAeccUOjfqaxGHl5GOaVIS8EnjEFtK 6AafCXmX/dO2FPbvMESnwn/2xUKQjrZrs8k6dWfCKPSThfLJJUlqySpyaW5OM8dgjrRszg Mp9M+kS+nSVqNu5/6aFJ3sC2P6n+7bTnF0pKG3o6eh0S2M7RLfoZvqXl8gfCxwB0w6js4s yCGB12fxlvEpfv3PzdYOYLzabJCeQ/sxHuO4EKQnS3olu5RsJzpDDPYwMq1hlg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1617756204; a=rsa-sha256; cv=none; b=gloCv703KDaskNVueiqt30ZIrHLN6bLUOXOEj+uklmX1BT52/cXZdHVQeARZEDSzHev2xE yma0SGIXTsd80zhAEHfEOUQ5ONECKzq7FSNWvgxKeBTvw+aoJ7v0+N0XFdcMd72xibo4KK XQsaXNQM7m2r4FYkUxS/AjcaGGeIApBgpGEOI5+d8vDSBMX1z0YWJGw81RbV4mwcJ+78NO a3por+XBIoCm04MDLI4hH/NwQRYq47Q0qZPi2uFvuhisGfpgHmP85q+h0pH/NrVlAkUVG4 CO4B0JYBPcvbZZGiNgWJ8m0bCiEPJd0o1ysI36vrrAwOaE9a7QBVcSAh1SL16g== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=HD00DqfL; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Migadu-Spam-Score: -0.94 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=HD00DqfL; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Migadu-Queue-Id: A8337A1D7 X-Spam-Score: -0.94 X-Migadu-Scanner: scn0.migadu.com X-TUID: fiClwkTFd7zA --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi Leo! Leo Famulari writes: > On Tue, Apr 06, 2021 at 05:42:15PM -0400, Maxim Cournoyer wrote: >> From c720e68229322e5c38c0321b021e8d6430636111 Mon Sep 17 00:00:00 2001 >> From: Maxim Cournoyer >> Date: Tue, 6 Apr 2021 17:37:33 -0400 >> Subject: [PATCH] system: vm: Set a larger value for the msize option of = the 9p >> file system. >>=20 >> Fixes . >>=20 >> * gnu/system/vm.scm (mapping->file-system): Set the msize option to a va= lue of >> 100 MiB (from the default 8 KiB). >>=20 >> Reported-by: Leo Famulari > > Thanks! I'll test and push along with the next kernel update (that's > when I noticed this warning). Feel free to push sooner if you like. I hope I'm timely; I've made a revised version of the patch, that should cover more cases (and actually uses 100 MiB rather than 1 MiB :-)). Thank you, --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-system-vm-Set-a-larger-value-for-the-msize-option-of.patch Content-Transfer-Encoding: quoted-printable From=20eb600c4ffbc8016709db9471f9dc0be1d60167a7 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 6 Apr 2021 17:37:33 -0400 Subject: [PATCH] system: vm: Set a larger value for the msize option of the= 9p file system. Fixes . * gnu/system/vm.scm (%default-msize-value): New variable. (%linux-vm-file-systems): Use it as the value of the msize option. (mapping->file-system): Likewise. Reported-by: Leo Famulari =2D-- gnu/system/vm.scm | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/gnu/system/vm.scm b/gnu/system/vm.scm index 3d0935b3af..1efae7ff06 100644 =2D-- a/gnu/system/vm.scm +++ b/gnu/system/vm.scm @@ -88,6 +88,13 @@ ;;; ;;; Code: =20 +;; By default, the msize value is 8 KiB, which according to QEMU is +;; insufficient and would degrade performance. The msize value should rou= ghly +;; match the bandwidth of the system's IO (see: +;; https://wiki.qemu.org/Documentation/9psetup#msize). Use 100 MiB as a +;; conservative default. +(define %default-msize-value (* 100 (expt 2 20))) ;100 MiB + (define %linux-vm-file-systems ;; File systems mounted for 'derivation-in-linux-vm'. These are shared = with ;; the host over 9p. @@ -103,21 +110,23 @@ (type "9p") (needed-for-boot? #t) (flags '(read-only)) =2D (options "trans=3Dvirtio,cache=3Dloose") + (options (format #f "trans=3Dvirtio,cache=3Dloose,msize=3D~a" + %default-msize-value)) (check? #f)) (file-system (mount-point "/xchg") (device "xchg") (type "9p") (needed-for-boot? #t) =2D (options "trans=3Dvirtio") + (options (format #f "trans=3Dvirtio,msize=3D~a" %default-msize-v= alue)) (check? #f)) (file-system (mount-point "/tmp") (device "tmp") (type "9p") (needed-for-boot? #t) =2D (options "trans=3Dvirtio,cache=3Dloose") + (options (format #f "trans=3Dvirtio,cache=3Dloose,msize=3D~a" + %default-msize-value)) (check? #f)))) =20 (define not-config? @@ -581,7 +590,8 @@ the operating system." (type "9p") (flags (if writable? '() '(read-only))) (options (string-append "trans=3Dvirtio" =2D (if writable? "" ",cache=3Dloose"))) + (if writable? "" ",cache=3Dloose") + ",msize=3D" (number->string %default-msize-= value))) (check? #f) (create-mount-point? #t))))) =20 =2D-=20 2.31.1 --=-=-=-- --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEJ9WGpPiQCFQyn/CfEmDkZILmNWIFAmBs//8ACgkQEmDkZILm NWJu3Q/+OpFYmW1U9vZFwWtEJKh6YAeHF1hBfMkqggTl3ca/FzvDt6NtwHRUwBHK i7jeY358nyi0ti0zP0zT1btYXXNj5AnjcRpg1LnttOPAaH2bIucjlP1oLYprxRSx TeZ6Keinp/kpZlrPqANN0bnEu++Y+MvYLDxzyjmeSeTwVENC4siQXvirne0s4uAL H9+EdvVK7ph5hAhb03aWXeGdYeNsDnuGLNaEzVnXFKec7o10hX1OfM4u8zPRMqZ+ fM+aQrUvrNiI72QIKo5knI19IVRkM3L6MQRUOCH8Hhs2tFH3pp479YQu8AusGGUF wdcNtG5rPGhEwK2qVvmdKUxoiLFepEgnsEnyK7NHCTsb0+xafuOV95xjQK+95I5S hLrV9JG8NMo3LBIh+XGbGy4WjX4Qs/EXMpbLdEWzwkfb8l6rykMA4BHSj/avi9NH xf94V/NUqfZvyJgrP2PvNd6x08BPUgrZpws8Mxj4LCNk96+Nuah/QeVlIwd4D/tW MiFGX4IJ9qYnOKqV16Dr0oEhXx+8empMyuwKr216dJ76WGyrO+8zwxpgURUdhXjP g9XixEWMlfzB0mc34Mpwwo2pAX1BdhqCQT7nj3Mt1uk0Qoi0xHvm/3f5p836b7nL nXzn6/oaBM2NSvJtBI/GApatLgGv7lcBIn6dUBxja38vkZhcx3M= =xKC5 -----END PGP SIGNATURE----- --==-=-=--