Bug 805168

Summary: seabios should not spin on cpu if started cpu count != cmos value at 0x5f
Product: Red Hat Enterprise Linux 6 Reporter: Igor Mammedov <imammedo>
Component: seabiosAssignee: Igor Mammedov <imammedo>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.3CC: areis, ehabkost, juzhang, michen, sluo, virt-maint
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: seabios-0.6.1.2-15.el6 Doc Type: Bug Fix
Doc Text:
No documentation needed.
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-06-20 12:55:14 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Halt if number of started cpus are more then expected none

Description Igor Mammedov 2012-03-20 15:55:21 UTC
Description of problem:

After bug 802033 fixed it is still possible to hang in seabios, if we try to unplug vcpus (doesn't work now).

How reproducible:
100%

Steps to Reproduce:
1. unplug vcpu
2. reboot guest
  
Actual results:
guest hangs in bios and consumes 1 vcpu by spining on it

Expected results:
guest should not spin on vcpu, halt instead.

Comment 1 Igor Mammedov 2012-03-20 16:09:32 UTC
Created attachment 571461 [details]
Halt if number of started cpus are more then expected

Comment 2 juzhang 2012-03-21 04:08:18 UTC
(In reply to comment #0)
> Description of problem:
> 
> After bug 802033 fixed it is still possible to hang in seabios, if we try to
> unplug vcpus (doesn't work now).
Since we do not support unplug vcpus,do we need to open a FRE bug about support hot unplug vcpu?.  I am wondering how qe verify this bug once this bug is fixed without unplug vcpu supported. fix me if any mistake.
> 
> How reproducible:
> 100%
> 
> Steps to Reproduce:
> 1. unplug vcpu
Would you please tell me how to fix this?  cpu_set x offline?

Comment 3 Miya Chen 2012-03-21 12:43:15 UTC
Mark qa-ack+ first.
Igor, could you please provide QE a scratch qemu build that support cpu hot-unplug to reproduce and verify this bug? Thanks.

Comment 4 Igor Mammedov 2012-03-21 13:54:07 UTC
(In reply to comment #3)
> Mark qa-ack+ first.
> Igor, could you please provide QE a scratch qemu build that support cpu
> hot-unplug to reproduce and verify this bug? Thanks.

You can use for it any brew build from qemu-kvm-0.12.1.2-2.250.el6 or later,
it has broken unplug but it will serve purpose.

Comment 5 Igor Mammedov 2012-03-21 14:42:56 UTC
(In reply to comment #4)
> (In reply to comment #3)
> > Mark qa-ack+ first.
> > Igor, could you please provide QE a scratch qemu build that support cpu
> > hot-unplug to reproduce and verify this bug? Thanks.
> 
> You can use for it any brew build from qemu-kvm-0.12.1.2-2.250.el6 or later,
> it has broken unplug but it will serve purpose.

I'm sorry for mistake, to reproduce bug with unplug you'll need qemu-kvm-0.12.1.2-2.254.el6

but you can reproduce it with plug as well if you use pre -254 qemu-kvm:
 https://bugzilla.redhat.com/show_bug.cgi?id=802033#c12

Comment 6 Igor Mammedov 2012-03-21 14:50:39 UTC
(In reply to comment #2)
> (In reply to comment #0)
> > Description of problem:
> > 
> > After bug 802033 fixed it is still possible to hang in seabios, if we try to
> > unplug vcpus (doesn't work now).
> Since we do not support unplug vcpus,do we need to open a FRE bug about support
> hot unplug vcpu?.  I am wondering how qe verify this bug once this bug is fixed
> without unplug vcpu supported. fix me if any mistake.
this fix is meant for broken unplug as it is in rhel6.3. so it wouldn't affect host even if we hit bug.

> > 
> > How reproducible:
> > 100%
> > 
> > Steps to Reproduce:
> > 1. unplug vcpu
> Would you please tell me how to fix this?  cpu_set x offline?

virsh setvcpus myguest XX --live

please don't use cpu_set directly, it can cause all sorts of havoc (at present time one should plug/unplug vcpus sequentially, and libvirt does it for you)

Comment 8 juzhang 2012-03-22 06:27:28 UTC
Hi,Igor

    Can reproduce with qemu-kvm-257 according to commet0 steps.

    Still need to confirm one thing:

     1.We still do not support unplug vcpu,right? cpu_set x offline just a method to trigger this issue, not really hot unplug vcpu,right?

Best Regards & Thanks,
Junyi

Comment 9 Igor Mammedov 2012-03-22 06:39:47 UTC
(In reply to comment #8)
>      1.We still do not support unplug vcpu,right? cpu_set x offline just a
> method to trigger this issue, not really hot unplug vcpu,right?

Yes, You are correct. "cpu_set x offline" reports unplug request to guest but:
  1. guest does nothing with it
  2. vcpu are not removed/destroyed in qemu/kvm

Comment 10 juzhang 2012-03-22 06:44:22 UTC
(In reply to comment #9)
> (In reply to comment #8)
> >      1.We still do not support unplug vcpu,right? cpu_set x offline just a
> > method to trigger this issue, not really hot unplug vcpu,right?
> 
> Yes, You are correct. "cpu_set x offline" reports unplug request to guest but:
>   1. guest does nothing with it
>   2. vcpu are not removed/destroyed in qemu/kvm
Make senses now, thanks

Best Regards & Thanks,
Junyi

Comment 13 juzhang 2012-04-20 04:58:45 UTC
Verified this issue with seabios-0.6.1.2-19.el6(bin and pm-bin) according comment0.

Results
guest works regardless hotadd/hot remove vcpu and reboot guest.

Comment 15 Eduardo Habkost 2012-04-23 18:50:57 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
No documentation needed.

Comment 17 errata-xmlrpc 2012-06-20 12:55:14 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2012-0802.html