libvirt-cim-bounces@redhat.com wrote on 2009-03-04 20:11:54:

>
>
> yunguol@cn.ibm.com wrote:
> > # HG changeset patch
> > # User Guolian Yun <yunguol@cn.ibm.com>
> > # Date 1236166087 28800
> > # Node ID a7392e6585d9ab3a02bab006727d9c49c8479653
> > # Parent  b84b3ec0c3d74c2e3c858a0fd82ff615a94bf18b
> > [TEST]#2  XFAIL for the 'VirtualQuantity' verification when the
> guest is runing
> >
> >
> > Updates from 1 to 2:
> > This issue only hit for KVM, check for the virt type before
> determining what return.
> >
> >
> > Tested for KVM with current sources and rpm
> >
> > Signed-off-by: Guolian Yun<yunguol@cn.ibm.com>
> >
> > diff -r b84b3ec0c3d7 -r a7392e6585d9 suites/libvirt-
> cim/cimtest/VirtualSystemManagementService/09_procrasd_persist.py
> > --- a/suites/libvirt-
> cim/cimtest/VirtualSystemManagementService/09_procrasd_persist.py  
> Tue Mar 03 09:05:40 2009 -0800
> > +++ b/suites/libvirt-
> cim/cimtest/VirtualSystemManagementService/09_procrasd_persist.py  
> Wed Mar 04 03:28:07 2009 -0800
> > @@ -42,11 +42,12 @@
> >  from XenKvmLib.classes import get_typed_class, inst_to_mof
> >  from CimTest.Globals import logger
> >  from XenKvmLib.const import do_main
> > -from CimTest.ReturnCodes import FAIL, PASS
> > +from CimTest.ReturnCodes import FAIL, PASS, XFAIL_RC
> >  from XenKvmLib.rasd import get_default_rasds
> >
> >  sup_types = ['Xen', 'XenFV', 'KVM']
> >  test_dom = 'procrasd_persist_dom'
> > +libvirt_bug = '00013'
> >  
>
> The bug is due to the side effects of the libvirt API
> virDomainGetVcpus() problem.
> Hence, I have changed the bug detail "The property of 'VirtualQuantity'
> of CPU is NULL when the guest is running."
> to same on cimtest wiki.


  Thanks! This description sees more clearly.

> >  nvcpu = 3
> >  weight = 124
> > @@ -76,7 +77,7 @@
> >
> >      return PASS
> >
> > -def check_proc_sched(server, cn_name):
> > +def check_proc_sched(server, virt, cn_name):
> >      try:
> >          proc_rasd = None
> >          rasds = EnumInstances(server, cn_name, ret_cim_inst=True)
> > @@ -89,10 +90,10 @@
> >              logger.error("Did not find test RASD on server")
> >              return FAIL
> >    
> > -        if proc_rasd["VirtualQuantity"] != nvcpu:
> > +        if proc_rasd["VirtualQuantity"] != nvcpu and virt == 'KVM':
> >              logger.error("VirtualQuantity is %i, expected %i",
> >                           proc_rasd["VirtualQuantity"], nvcpu)
> > -            return FAIL
> > +            return XFAIL_RC(libvirt_bug)
> >
> >          if proc_rasd["Limit"] != limit:
> >              logger.error("Limit is %i, expected %i",
> > @@ -126,7 +127,7 @@
> >                  return status
> >      
> >              dom_define = True
> > -            status = check_proc_sched(server, prasd_cn)
> > +            status = check_proc_sched(server, virt, prasd_cn)
> >              if status != PASS:
> >                  raise Exception("CPU scheduling not set properly for "
> >                                  " defined dom: %s" % test_dom)
> > @@ -136,8 +137,8 @@
> >                  raise Exception("Unable to start %s " % test_dom)
> >
> >              dom_start = True
> > -            status = check_proc_sched(server, prasd_cn)
> > -            if status != PASS:
> > +            status = check_proc_sched(server, virt, prasd_cn)
> > +            if virt != 'KVM' and status == FAIL:
> >                  raise Exception("CPU scheduling not set properly
> for the dom: "
> >                                  "%s" % test_dom)
> >
> >
> > _______________________________________________
> > Libvirt-cim mailing list
> > Libvirt-cim@redhat.com
> > https://www.redhat.com/mailman/listinfo/libvirt-cim
> >  
>
> --
> Thanks and Regards,
> Deepti B. Kalakeri
> IBM Linux Technology Center
> deeptik@linux.vnet.ibm.com
>
> _______________________________________________
> Libvirt-cim mailing list
> Libvirt-cim@redhat.com
> https://www.redhat.com/mailman/listinfo/libvirt-cim