guest boots up too slowly

Bug #855633 reported by Yongjie Ren
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
QEMU
Fix Released
Undecided
Unassigned

Bug Description

qemu.git (memory/queue branch) commit: 6cc7686696f73ae87cadef4450776a488b0e0c8b
or qemu.git (master branch) commit: 8843cf40c0f482949e6ae9d0119e45d6b96fe890
kvm.git commit: 7f914d61cd2156e34a7852462bb4932621f33a34

It will costs about 180 seconds to booting up a rhel6 guest. But when I use qemu.git with commit edbb7c0, the rhel6 guest can boot up in about 50 seconds. I did the comparative test in the same box and using the same command line to create a guest.
I found this bug in memory/queue branch of qemu.git on September 21st. As some codes in memory branch were merged into master branch, the master tree of qemu.git also has this issue now.

I found the following log in master tree. And that merger maybe introduced this issue in master tree.
commit 36f490b176afab3096e9c2877b365354f67e269d
Merge: ebffe2a 0d95952
Author: Anthony Liguori <email address hidden>
Date: Fri Oct 14 10:44:52 2011 -0500

    Merge remote-tracking branch 'qemu-kvm-tmp/memory/batch' into staging

Reproduce steps:
----------------
1.with latest qemu.git master tree, to create a guest: qemu-system-x86_64 -m 1024 -smp 2 -hda /root/rhel6.img
(It maybe cost about 180 seconds to boot up.)

Revision history for this message
Yongjie Ren (yongjie-ren) wrote :

sorry, the right command to reproduce is 'qemu-system-x86_64 -m 1024 -smp 2 -hda /root/rhel6.img'. I missed the '-hda' in the bug description.

Revision history for this message
Avi Kivity (avi-redhat) wrote :

Could not reproduce - RHEL 6 boots up snappily for me.

Is it an overall slowdown, or is a specific part of the boot slower? (may need to remove 'rhgb' and 'quiet' from the boot command line).

Make sure that 'info kvm' returns 'enabled'.

Revision history for this message
Yongjie Ren (yongjie-ren) wrote :

Eh? I can reproduce very easily and it always has this issue in the qemu.git upstream in the past two weeks. I used rhel5u5, rhel6, rhel6u1 or any other images as guest, and met the same issue. And this is not a platform specific issue. It can be reproduced in Westmere-EP and Sandybrige-EP platforms (I often test kvm on the two platforms.)
‘info kvm' doesn't return 'enabled' in my box. When we didn't have many bugs and all of our test cases passed in the past, 'info kvm' din't return 'enabled' either. Seems that there's no info document for kvm in my box all the time.
And for guest, there's no 'rhgb' or 'quiet' in the boot command line.
From my eyes, I see the guest is not overall slowdown. I redirect the boot log to serial port. The boot serial log of rhel6u1 guest is attached.
For the attached boot log,
before this line "scsi 1:0:0:0: CD-ROM", seems not so slow, and after that, boot slower.
but after this line "Starting udev: udev: starting version 147", it's very very slow and I can see it just print one line after another line with my eyes.
BTW, shutting down guest is also much slower than before.

Revision history for this message
Yongjie Ren (yongjie-ren) wrote :

I used the default 'memory/queue' branch when I filed this bug.
The master tree doesn't have these two bugs, and I'll mark the bugs as invalid.
Mark as invalid.

Changed in qemu:
status: New → Invalid
Revision history for this message
Yongjie Ren (yongjie-ren) wrote :

I found this bug in memory/queue branch of qemu.git on September 21st. As some codes in memory branch were merged into master branch, the master tree of qemu.git also has this issue now.

description: updated
description: updated
Changed in qemu:
status: Invalid → New
Revision history for this message
Yongjie Ren (yongjie-ren) wrote :

This is because kvm is not enabled when starting guest by default even if I add KVM support when configuring qemu.
Now it got fixed by the following commit.

author Marcelo Tosatti <email address hidden>
Thu, 27 Oct 2011 20:34:42 +0800 (10:34 -0200)
committer Marcelo Tosatti <email address hidden>
Thu, 27 Oct 2011 20:34:42 +0800 (10:34 -0200)
commit 7879db7e9c09b92d9af1c143fbe2cc212ec89e4b
Revert "qemu-kvm: set default accelerator via target.conf"

This reverts commit a5c40eb1aa929a03157252db7337bc4ddd2435be.

Jan says:

"Unless you fully install qemu, that conf is not picked up (or an older
version is used). I'd still like to see this working with qemu started
from a build directory..."

Signed-off-by: Marcelo Tosatti <email address hidden>

Changed in qemu:
status: New → Fix Released
Revision history for this message
Yongjie Ren (yongjie-ren) wrote :

It's the same reason as the following bug.
https://bugs.launchpad.net/qemu/+bug/882358

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.