<br><tt><font size=2>libvirt-cim-bounces@redhat.com wrote on 2008-09-27
05:53:39:<br>
<br>
> >      options = main.options<br>
> > -    keys = ['Name', 'CreationClassName']<br>
> > -    try:<br>
> > -        host_sys = enumclass.enumerate(options.ip,
'HostSystem', <br>
> keys, options.virt)[0]<br>
> > -    except Exception:<br>
> > -        logger.error(Globals.CIM_ERROR_ENUMERATE
% host_sys.<br>
> CreationClassName)<br>
> > -        return FAIL<br>
> > +    ret, linux_cs = check_sblim(options.ip, options.virt)<br>
> > +    if ret == PASS:<br>
> > +        host_sys = linux_cs<br>
> > +    else:<br>
> > +        keys = ['Name', 'CreationClassName']<br>
> > +        try:<br>
> > +            host_sys = enumclass.enumerate(options.ip,
<br>
> 'HostSystem', keys, options.virt)[0]<br>
> > +        except Exception:<br>
> > +            logger.error(Globals.CIM_ERROR_ENUMERATE
% host_sys.<br>
> CreationClassName)<br>
> > +            return FAIL<br>
> <br>
> With Deepti's patch, you can use get_host_info() instead.<br>
> <br>
> >      servicelist = {"ResourcePoolConfigurationService"
: "RPCS", <br>
> >                  
  "VirtualSystemManagementService" : "ManagementService",<br>
> >                  
  "VirtualSystemMigrationService" : "MigrationService"}<br>
> > @@ -67,7 +72,8 @@ def main():<br>
> >          ccn = assoc_host[0].keybindings['CreationClassName']<br>
> >          name = assoc_host[0].keybindings['Name']<br>
> >          <br>
> > -        if ccn != get_typed_class(options.virt,
"HostSystem"):<br>
> > +        if ccn != get_typed_class(options.virt,
"HostSystem")\<br>
> > +          and ccn != 'Linux_ComputerSystem':<br>
> <br>
> Instead of using HostSystem and Linux_ComputerSystem here, you can
use <br>
> the host_sys CreationClassName.<br>
> </font></tt>
<br><tt><font size=2>  Good catch.</font></tt>
<br><tt><font size=2>  Thanks!</font></tt>
<br><tt><font size=2><br>
> -- <br>
> Kaitlin Rupert<br>
> IBM Linux Technology Center<br>
> kaitlin@linux.vnet.ibm.com<br>
> <br>
> _______________________________________________<br>
> Libvirt-cim mailing list<br>
> Libvirt-cim@redhat.com<br>
> https://www.redhat.com/mailman/listinfo/libvirt-cim<br>
</font></tt>