KVM guest hangs on 'booting from hard disk' 10.10 for guest and host.

Bug #712878 reported by William King
22
This bug affects 5 people
Affects Status Importance Assigned to Milestone
VMBuilder
Incomplete
Low
Unassigned
qemu-kvm (Ubuntu)
Expired
Low
Unassigned

Bug Description

Binary package hint: kvm

The last working guest was provisioned on Jan 5th, 2011. Just tried to provisioned another guest with vmbuilder and it fails to boot.

On the host:
uname -a
Linux thedraft 2.6.35-25-server #44-Ubuntu SMP Fri Jan 21 19:09:14 UTC 2011 x86_64 GNU/Linux

head /proc/cpuinfo
processor : 0
vendor_id : AuthenticAMD
cpu family : 16
model : 9
model name : AMD Opteron(tm) Processor 6128
stepping : 1
cpu MHz : 800.000
cache size : 512 KB
physical id : 0
siblings : 8

dpkg -l |grep qemu
ii qemu-common 0.12.5+noroms-0ubuntu7.1 qemu common functionality (bios, documentation, etc)
ii qemu-kvm 0.12.5+noroms-0ubuntu7.1 Full virtualization on i386 and amd64 hardware

Revision history for this message
William King (quentusrex) wrote :

Confirmed two different hosts with different hardware.

The second server had this setup:

ii qemu-common 0.12.5+noroms-0ubuntu7 qemu common functionality (bios, documentation, etc)
ii qemu-kvm 0.12.5+noroms-0ubuntu7 Full virtualization on i386 and amd64 hardware

head /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 30
model name : Intel(R) Core(TM) i7 CPU 860 @ 2.80GHz
stepping : 5
cpu MHz : 1197.000
cache size : 8192 KB
physical id : 0
siblings : 8

Linux therabbit 2.6.35-23-server #41-Ubuntu SMP Wed Nov 24 12:12:17 UTC 2010 x86_64 GNU/Linux

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

Thanks for reporting this bug and helping to make Ubuntu better.

Are you able to boot from an install .iso, install a VM, and reboot into that working VM? In other words, is it only images built by vmbuilder which fail to boot?

Can you give us the precise vmbuilder command you are using to create the VMs which do not boot?

Revision history for this message
Brian Knoll (brianknoll) wrote :

Could you please tell us if the VMs that won't boot are SMP VMs? I know it's the SMP kernel but what I mean is, is KVM giving the VM more than one CPU? If they are SMP VMs, could you please try to make them single-CPU and try to boot them, then let us know what happens? I am seeing a bug with Linux SMP guests under KVM which causes boot failures and random hangs, and I wonder if it's related.

Revision history for this message
William King (quentusrex) wrote : Re: [Bug 712878] Re: KVM guest hangs on 'booting from hard disk' 10.10 for guest and host.

The guests were single cpu server kernel, more info tomorrow.
On Feb 5, 2011 10:55 PM, "Brian Knoll" <email address hidden> wrote:
> Could you please tell us if the VMs that won't boot are SMP VMs? I know
> it's the SMP kernel but what I mean is, is KVM giving the VM more than
> one CPU? If they are SMP VMs, could you please try to make them single-
> CPU and try to boot them, then let us know what happens? I am seeing a
> bug with Linux SMP guests under KVM which causes boot failures and
> random hangs, and I wonder if it's related.
>
> --
> You received this bug notification because you are a direct subscriber
> of the bug.
> https://bugs.launchpad.net/bugs/712878
>
> Title:
> KVM guest hangs on 'booting from hard disk' 10.10 for guest and host.
>
> Status in Virtual Machine Builder:
> New
> Status in “kvm” package in Ubuntu:
> New
>
> Bug description:
> Binary package hint: kvm
>
> The last working guest was provisioned on Jan 5th, 2011. Just tried to
> provisioned another guest with vmbuilder and it fails to boot.
>
> On the host:
> uname -a
> Linux thedraft 2.6.35-25-server #44-Ubuntu SMP Fri Jan 21 19:09:14 UTC
2011 x86_64 GNU/Linux
>
> head /proc/cpuinfo
> processor : 0
> vendor_id : AuthenticAMD
> cpu family : 16
> model : 9
> model name : AMD Opteron(tm) Processor 6128
> stepping : 1
> cpu MHz : 800.000
> cache size : 512 KB
> physical id : 0
> siblings : 8
>
> dpkg -l |grep qemu
> ii qemu-common 0.12.5+noroms-0ubuntu7.1 qemu common functionality (bios,
documentation, etc)
> ii qemu-kvm 0.12.5+noroms-0ubuntu7.1 Full virtualization on i386 and amd64
hardware
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/vmbuilder/+bug/712878/+subscribe

Revision history for this message
Brian Knoll (brianknoll) wrote :

Okay, thank you for the information. Earlier I had wondered if maybe you had shortened the cpuinfo you posted, just to keep things more compact in your bug report (which is why I asked, because the cpuinfo obviously shows single-cpu), but since that isn't the case and they really are single-CPU VMs I don't think this is the same bug as I have. Thanks again for the information!

Revision history for this message
William King (quentusrex) wrote :

I have been able to work around the issue by provisioning guests with the
virtual flavor, rather than with the server flavor.
On Feb 6, 2011 6:20 AM, "Brian Knoll" <email address hidden> wrote:
> Okay, thank you for the information. Earlier I had wondered if maybe
> you had shortened the cpuinfo you posted, just to keep things more
> compact in your bug report (which is why I asked, because the cpuinfo
> obviously shows single-cpu), but since that isn't the case and they
> really are single-CPU VMs I don't think this is the same bug as I have.
> Thanks again for the information!
>
> --
> You received this bug notification because you are a direct subscriber
> of the bug.
> https://bugs.launchpad.net/bugs/712878
>
> Title:
> KVM guest hangs on 'booting from hard disk' 10.10 for guest and host.
>
> Status in Virtual Machine Builder:
> New
> Status in “kvm” package in Ubuntu:
> New
>
> Bug description:
> Binary package hint: kvm
>
> The last working guest was provisioned on Jan 5th, 2011. Just tried to
> provisioned another guest with vmbuilder and it fails to boot.
>
> On the host:
> uname -a
> Linux thedraft 2.6.35-25-server #44-Ubuntu SMP Fri Jan 21 19:09:14 UTC
2011 x86_64 GNU/Linux
>
> head /proc/cpuinfo
> processor : 0
> vendor_id : AuthenticAMD
> cpu family : 16
> model : 9
> model name : AMD Opteron(tm) Processor 6128
> stepping : 1
> cpu MHz : 800.000
> cache size : 512 KB
> physical id : 0
> siblings : 8
>
> dpkg -l |grep qemu
> ii qemu-common 0.12.5+noroms-0ubuntu7.1 qemu common functionality (bios,
documentation, etc)
> ii qemu-kvm 0.12.5+noroms-0ubuntu7.1 Full virtualization on i386 and amd64
hardware
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/vmbuilder/+bug/712878/+subscribe

Revision history for this message
Brian Knoll (brianknoll) wrote :

Thanks for the tip. I tried that over here and it didn't help, but I think I have a different bug over here (mine is related to SMP guests), so I just filed bug 714335 to track mine.

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

@William
    If you have some time, could you go ahead and answer the questions in comment #2? Many thanks in advance.

Changed in vmbuilder:
status: New → Incomplete
affects: kvm (Ubuntu) → qemu-kvm (Ubuntu)
Changed in qemu-kvm (Ubuntu):
importance: Undecided → Low
status: New → Incomplete
Changed in vmbuilder:
importance: Undecided → Low
Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

(Marking low importance since there is a workaround.)

Revision history for this message
William King (quentusrex) wrote :

Answering all the above questions just to make sure none were missed:

q)Are you able to boot from an install .iso, install a VM, and reboot into
that working VM?
a) No, I am not able to boot from an install .iso. I might be able to look into this, but so far the systems are not configured to allow this setup.

q)In other words, is it only images built by vmbuilder which fail to boot?
a) same as above

q) Can you give us the precise vmbuilder command you are using to create the VMs which do not boot?
a)
vmbuilder kvm ubuntu --suite maverick --flavour server --arch amd64 -m 256 --addpkg emacs23-nox --addpkg command-not-found --addpkg htop --addpkg unattended-upgrades --addpkg acpid --addpkg language-pack-en --addpkg wget --addpkg openssh-server --bridge br0 --libvirt qemu:///system --debug -v --mirror http://192.168.100.229:3142/ubuntu.osuosl.org/ubuntu/ --hostname $VM_NAME --dest /mnt/kvm/virtservers/$VM_NAME --user $USER_NAME --pass $SECRET_PASS --name $USER_NAME --rootsize=4096

That is the exact line that is in the script which builds the image. The bash variables are replaced with the per instance data.

q) Could you please tell us if the VMs that won't boot are SMP VMs?
a) They were provisioned as single core VM's. And adding cores does not effect the boot issue.

-William

Revision history for this message
KarelV (k01) wrote :

I'm new to Ubuntu and vmbuilder and I am not shure whether my problem installing a new guest is related to this bug. If related, the sequence I get, could be of help.
After the line Calling hook: bootstrap, nothing happend for almost one hour and then stopped with some error reporting as given hereafter.

nnn@sss:~$ sudo vmbuilder kvm ubuntu --suite maverick --flavour virtual --arch amd64 -o --libvirt qemu:///system --hostname sweb --part vmbuilder.partition --user nnn --name nnnnnnn --pass ppppppp --bridge br1
[sudo] password for nnn:
2011-03-11 12:20:27,034 INFO : Calling hook: preflight_check
2011-03-11 12:20:27,061 INFO : Calling hook: set_defaults
2011-03-11 12:20:27,063 INFO : Calling hook: bootstrap
2011-03-11 13:18:58,705 ERROR : Process (['/usr/sbin/debootstrap', '--arch=amd64', 'maverick', '/tmp/tmpwHumhC', 'http://archive.ubuntu.com/ubuntu']) returned 1. stdout: I: Retrieving Release
E: Failed getting release file http://archive.ubuntu.com/ubuntu/dists/maverick/Release
, stderr:
Traceback (most recent call last):
  File "/usr/bin/vmbuilder", line 24, in <module>
    cli.main()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/contrib/cli.py", line 110, in main
    distro.build_chroot()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/distro.py", line 82, in build_chroot
    self.call_hooks('bootstrap')
  File "/usr/lib/python2.6/dist-packages/VMBuilder/distro.py", line 66, in call_hooks
    call_hooks(self, *args, **kwargs)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/util.py", line 165, in call_hooks
    getattr(context, func, log_no_such_method)(*args, **kwargs)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/distro.py", line 142, in bootstrap
    self.suite.debootstrap()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/dapper.py", line 269, in debootstrap
    run_cmd(*cmd, **kwargs)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/util.py", line 120, in run_cmd
    raise VMBuilderException, "Process (%s) returned %d. stdout: %s, stderr: %s" % (args.__repr__(), status, mystdout.buf, mystderr.buf)
VMBuilder.exception.VMBuilderException: Process (['/usr/sbin/debootstrap', '--arch=amd64', 'maverick', '/tmp/tmpwHumhC', 'http://archive.ubuntu.com/ubuntu']) returned 1. stdout: I: Retrieving Release
E: Failed getting release file http://archive.ubuntu.com/ubuntu/dists/maverick/Release
, stderr:
nnn@sss:~$

-Karel

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

Quoting KarelV (<email address hidden>):
> raise VMBuilderException, "Process (%s) returned %d. stdout: %s, stderr: %s" % (args.__repr__(), status, mystdout.buf, mystderr.buf)
> VMBuilder.exception.VMBuilderException: Process (['/usr/sbin/debootstrap', '--arch=amd64', 'maverick', '/tmp/tmpwHumhC', 'http://archive.ubuntu.com/ubuntu']) returned 1. stdout: I: Retrieving Release
> E: Failed getting release file http://archive.ubuntu.com/ubuntu/dists/maverick/Release

Are you behind a firewall? Can you

wget http://archive.ubuntu.com/ubuntu/dists/maverick/Release

from the command line?

Revision history for this message
KarelV (k01) wrote :

Yes, I am behind a firewall. I have internet access, e.g. apt-get opperates properly.
Also the wget command operates, it gives this sequence:

--2011-03-12 10:00:03-- http://archive.ubuntu.com/ubuntu/dists/maverick/Release
Herleiden van archive.ubuntu.com... 91.189.88.46
Verbinding maken met archive.ubuntu.com|91.189.88.46|:80... verbonden.
HTTP-verzoek is verzonden; wachten op antwoord... 200 OK
Lengte: 39772 (39K) [text/plain]
Wordt opgeslagen als: âReleaseâ

100%[===========================================================>] 39.772 --.-K/s in 0,1s

2011-03-12 10:00:23 (377 KB/s) - 'âReleaseâ' opgeslagen [39772/39772]

Revision history for this message
KarelV (k01) wrote :

I added a static Ip address in the command-line and now vmbuilder continues. I will look elsewhere to solve remaining errors.

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

@William,

I tried the exact vmbuilder command you listed but the result booted fine for me. I can't reproduce your error. It's possible that a server kernel update has fixed it. Can you still reproduce the error? Can you reproduce it when you don't use your local mirror?

@KarelV,

if you still have a problem please file a new bug, rather than commenting on this one, as I suspect you have different causes.unless you are convinced you have the exact same bug as William's.

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for qemu-kvm (Ubuntu) because there has been no activity for 60 days.]

Changed in qemu-kvm (Ubuntu):
status: Incomplete → Expired
Revision history for this message
Sergey Svishchev (svs) wrote :

Several VMs that I recently created with vmbuilder 0.12.4 on Lucid failed this way; turns out that no partition was marked bootable in the MBR.

kvm-nbd & fdisk fixed that.

Revision history for this message
Sergey Svishchev (svs) wrote :

My issue seems to be a case of bug 654723

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.