unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* speed of qemu vms
@ 2017-10-24 19:30 Hartmut Goebel
  2017-10-24 21:00 ` Leo Famulari
  2017-10-25  6:28 ` Christopher Baines
  0 siblings, 2 replies; 8+ messages in thread
From: Hartmut Goebel @ 2017-10-24 19:30 UTC (permalink / raw)
  To: guix-devel

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

Hello,

for testing I used to build VM using "guix system vm …" and the machines
are, well, reacting slowly:

Plasma start up: 80 sec.

Menu: 36 sec

When I tried a Vm created with "guix system vm-image …" the machine is
much quicker:

Plasma start up:  25 sec.

Menu: immediately.

This is a huge contrast, so I wonder what is the reason for this. Any
ideas? And any ideas how to speed up the first variant?

-- 
Regards
Hartmut Goebel

| Hartmut Goebel          | h.goebel@crazy-compilers.com               |
| www.crazy-compilers.com | compilers which you thought are impossible |


[-- Attachment #2: 0xBF773B65.asc --]
[-- Type: application/pgp-keys, Size: 14855 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: speed of qemu vms
  2017-10-24 19:30 speed of qemu vms Hartmut Goebel
@ 2017-10-24 21:00 ` Leo Famulari
  2017-10-25  6:28 ` Christopher Baines
  1 sibling, 0 replies; 8+ messages in thread
From: Leo Famulari @ 2017-10-24 21:00 UTC (permalink / raw)
  To: Hartmut Goebel; +Cc: guix-devel

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

On Tue, Oct 24, 2017 at 09:30:06PM +0200, Hartmut Goebel wrote:
> Hello,
> 
> for testing I used to build VM using "guix system vm …" and the machines
> are, well, reacting slowly:
> 
> Plasma start up: 80 sec.
> 
> Menu: 36 sec
> 
> When I tried a Vm created with "guix system vm-image …" the machine is
> much quicker:
> 
> Plasma start up:  25 sec.
> 
> Menu: immediately.
> 
> This is a huge contrast, so I wonder what is the reason for this. Any
> ideas? And any ideas how to speed up the first variant?

The two methods are pretty different "under the hood".

`guix system vm` shares the store with the host machine using virtio. By
default, only 256 MB of RAM is allocated for the system. I recommend
inspecting the script that is created by `guix system vm` to see what it
does.

`guix system vm-image`, on the other hand, is a full virtual machine
image, with its own store.

It's hard to give specific feedback without more information about the
host machine(s) and other details of the environment.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: speed of qemu vms
  2017-10-24 19:30 speed of qemu vms Hartmut Goebel
  2017-10-24 21:00 ` Leo Famulari
@ 2017-10-25  6:28 ` Christopher Baines
  2017-10-27  0:22   ` Ludovic Courtès
  2017-10-27  7:43   ` Hartmut Goebel
  1 sibling, 2 replies; 8+ messages in thread
From: Christopher Baines @ 2017-10-25  6:28 UTC (permalink / raw)
  To: Hartmut Goebel; +Cc: guix-devel

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

On Tue, 24 Oct 2017 21:30:06 +0200
Hartmut Goebel <h.goebel@crazy-compilers.com> wrote:

> Hello,
> 
> for testing I used to build VM using "guix system vm …" and the machines
> are, well, reacting slowly:
> 
> Plasma start up: 80 sec.
> 
> Menu: 36 sec
> 
> When I tried a Vm created with "guix system vm-image …" the machine is
> much quicker:
> 
> Plasma start up:  25 sec.
> 
> Menu: immediately.
> 
> This is a huge contrast, so I wonder what is the reason for this. Any
> ideas? And any ideas how to speed up the first variant?

I'm guessing that the issue with the first variant is the same that I
was coming up against here [1].

1: https://lists.gnu.org/archive/html/help-guix/2017-08/msg00064.html

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

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: speed of qemu vms
  2017-10-25  6:28 ` Christopher Baines
@ 2017-10-27  0:22   ` Ludovic Courtès
  2017-10-27  7:08     ` Hartmut Goebel
  2017-10-27  7:43   ` Hartmut Goebel
  1 sibling, 1 reply; 8+ messages in thread
From: Ludovic Courtès @ 2017-10-27  0:22 UTC (permalink / raw)
  To: Christopher Baines; +Cc: guix-devel

Hello!

Christopher Baines <mail@cbaines.net> skribis:

> On Tue, 24 Oct 2017 21:30:06 +0200
> Hartmut Goebel <h.goebel@crazy-compilers.com> wrote:
>
>> Hello,
>> 
>> for testing I used to build VM using "guix system vm …" and the machines
>> are, well, reacting slowly:
>> 
>> Plasma start up: 80 sec.
>> 
>> Menu: 36 sec

[...]

> I'm guessing that the issue with the first variant is the same that I
> was coming up against here [1].
>
> 1: https://lists.gnu.org/archive/html/help-guix/2017-08/msg00064.html

It could be that, but given the figures you give, are you sure KVM is
enabled on your system, Hartmut?  Does /dev/kvm exist?

Ludo’.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: speed of qemu vms
  2017-10-27  0:22   ` Ludovic Courtès
@ 2017-10-27  7:08     ` Hartmut Goebel
  2017-10-27  7:43       ` Chris Marusich
  0 siblings, 1 reply; 8+ messages in thread
From: Hartmut Goebel @ 2017-10-27  7:08 UTC (permalink / raw)
  To: Ludovic Courtès, Christopher Baines; +Cc: guix-devel

Am 27.10.2017 um 02:22 schrieb Ludovic Courtès:
> It could be that, but given the figures you give, are you sure KVM is
> enabled on your system, Hartmut?  Does /dev/kvm exist?

Yes, /dev/kvm exists. Anything else to check?

crw-rw-rw-+ 1 root kvm 10, 232 Okt 20 00:29 /dev/kvm

-- 
Regards
Hartmut Goebel

| Hartmut Goebel          | h.goebel@crazy-compilers.com               |
| www.crazy-compilers.com | compilers which you thought are impossible |

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: speed of qemu vms
  2017-10-25  6:28 ` Christopher Baines
  2017-10-27  0:22   ` Ludovic Courtès
@ 2017-10-27  7:43   ` Hartmut Goebel
  1 sibling, 0 replies; 8+ messages in thread
From: Hartmut Goebel @ 2017-10-27  7:43 UTC (permalink / raw)
  To: Christopher Baines; +Cc: guix-devel

Am 25.10.2017 um 08:28 schrieb Christopher Baines:
> I'm guessing that the issue with the first variant is the same that I
> was coming up against here [1].
>
> 1: https://lists.gnu.org/archive/html/help-guix/2017-08/msg00064.html

Maybe – I did not find time yet to measure it.

As suggested in that thread I replaced unionfs with overlayfs but the
perfomrance gain is minimal.

-- 
Regards
Hartmut Goebel

| Hartmut Goebel          | h.goebel@crazy-compilers.com               |
| www.crazy-compilers.com | compilers which you thought are impossible |

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: speed of qemu vms
  2017-10-27  7:08     ` Hartmut Goebel
@ 2017-10-27  7:43       ` Chris Marusich
  2017-10-27  8:34         ` Hartmut Goebel
  0 siblings, 1 reply; 8+ messages in thread
From: Chris Marusich @ 2017-10-27  7:43 UTC (permalink / raw)
  To: Hartmut Goebel; +Cc: guix-devel

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

Hartmut Goebel <h.goebel@crazy-compilers.com> writes:

> Am 27.10.2017 um 02:22 schrieb Ludovic Courtès:
>> It could be that, but given the figures you give, are you sure KVM is
>> enabled on your system, Hartmut?  Does /dev/kvm exist?
>
> Yes, /dev/kvm exists. Anything else to check?
>
> crw-rw-rw-+ 1 root kvm 10, 232 Okt 20 00:29 /dev/kvm

Does the qemu process have access to kvm?  In addition to the user/group
ID of the process, you might also check the file ACLs using getfacl
(available in the "acl" package).  If you don't have access, maybe KVM
isn't being used.

-- 
Chris

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: speed of qemu vms
  2017-10-27  7:43       ` Chris Marusich
@ 2017-10-27  8:34         ` Hartmut Goebel
  0 siblings, 0 replies; 8+ messages in thread
From: Hartmut Goebel @ 2017-10-27  8:34 UTC (permalink / raw)
  To: Chris Marusich; +Cc: guix-devel

Am 27.10.2017 um 09:43 schrieb Chris Marusich:
> Does the qemu process have access to kvm?  …  If you don't have access, maybe KVM
> isn't being used.

Yes, the qemu-process is started with my user and my user is member of
group kvm, which has read-write-access to /dev/kvm. Additionally my user
has read-write-access to /dev/kvm.

But am unsure who this contributes to the huge difference in runtime. If
the qemu process does not have access to kvm, then *both* types of VMs
would be affected in the same way, would they?

-- 
Regards
Hartmut Goebel

| Hartmut Goebel          | h.goebel@crazy-compilers.com               |
| www.crazy-compilers.com | compilers which you thought are impossible |

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2017-10-27  8:34 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-24 19:30 speed of qemu vms Hartmut Goebel
2017-10-24 21:00 ` Leo Famulari
2017-10-25  6:28 ` Christopher Baines
2017-10-27  0:22   ` Ludovic Courtès
2017-10-27  7:08     ` Hartmut Goebel
2017-10-27  7:43       ` Chris Marusich
2017-10-27  8:34         ` Hartmut Goebel
2017-10-27  7:43   ` Hartmut Goebel

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).