all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Christopher Baines <mail@cbaines.net>
To: Ricardo Wurmus <rekado@elephly.net>
Cc: help-guix@gnu.org
Subject: Re: Performance issues with /gnu/store in virtual machines
Date: Sun, 20 Aug 2017 11:22:09 +0100	[thread overview]
Message-ID: <20170820112209.56847394@cbaines.net> (raw)
In-Reply-To: <87wp5ywr1j.fsf@elephly.net>

[-- Attachment #1: Type: text/plain, Size: 1548 bytes --]

On Sun, 20 Aug 2017 11:02:16 +0200
Ricardo Wurmus <rekado@elephly.net> wrote:

> Hi Chris,
> 
> > So I was trying out using VMs created through Guix for more things,
> > particularly as they can be run as part of derivations, e.g. the
> > system tests for Guix.
> >
> > However, I'm seeing anything that does I/O performing very poorly
> > compared with the host system.  
> 
> (I’m not using VMs as KVM doesn’t work on my laptop.)
> 
> Have you tried specifying “virtio” drivers for the virtual disks?  I
> don’t think they are the default and I’m hopeful that with virtio
> drivers I/O performance will be comparable.

I think I may already be using virtio, at least that is what is
specified as the trans option for the mount in the VM? I think this is
the relevant bit from the vm start script:

  -virtfs local,path="/gnu/store",security_model=none,mount_tag="TAG_gnu_store"

This is how the mount shows up in the vm:

  TAG_gnu_store on /gnu/store type 9p (ro,relatime,sync,dirsync,trans=virtio)


One thing I have just tried, is adding the cache=loose option in (by
directly editing the mapping->file-system procedure in (gnu system
vm)). For my really quick test [1], this did increase the initial
runtime from ~8 to ~11 seconds, but subsequent runs were down to ~5
seconds from the original ~8.

5 seconds though, is still 16 times longer than the ~0.3 seconds this
command takes to run on the host, so it's still slow by comparison.

1: time find /gnu/store/*-guile* -name guile | wc -l

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 963 bytes --]

  reply	other threads:[~2017-08-20 10:22 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-17 20:05 Performance issues with /gnu/store in virtual machines Christopher Baines
2017-08-20  9:02 ` Ricardo Wurmus
2017-08-20 10:22   ` Christopher Baines [this message]
2017-08-22 10:11 ` Ludovic Courtès
2017-08-22 11:20   ` Christopher Baines
2017-08-22 14:35     ` Ludovic Courtès
2017-08-22 12:51   ` 宋文武
2017-08-22 14:33     ` Ludovic Courtès

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=20170820112209.56847394@cbaines.net \
    --to=mail@cbaines.net \
    --cc=help-guix@gnu.org \
    --cc=rekado@elephly.net \
    /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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.