Create Virtual Machine using MSVM_VirtualSystemManagementService through SOAP Message

Jan 4, 2012 at 6:00 AM

Hi

I am trying to create virtual machine using SOAP message,  executing this XML using wget, it throws error like "The WS-Management service cannot process the request because a date-time element or simple property contains child elements."

 

I placed my xml file here. Could any one have idea, please share your input either the xml is correct or not.

===================

<s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">
  <s:Header>
    <a:To>http://xxx.x.x.xxx:5985/wsman</a:To>
    <w:ResourceURI s:mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/wmi/root/virtualization/MSVM_VirtualSystemManagementService</w:ResourceURI>
    <a:ReplyTo>
         <a:Address s:mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address>
    </a:ReplyTo>
    <a:Action s:mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/wmi/root/virtualization/MSVM_VirtualSystemManagementService/DefineVirtualSystem</a:Action>
    <w:MaxEnvelopeSize s:mustUnderstand="true">153600</w:MaxEnvelopeSize>
   <a:MessageID>uuid:8C075E34-B4DA-4BB8-AAAB-B6F50584D67F</a:MessageID>
   <w:Locale s:mustUnderstand="false" xml:lang="en-US"/>
   <w:OperationTimeout>PT60.000S</w:OperationTimeout>
  <w:SelectorSet/>
  </s:Header>
 <s:Body>
 <p:DefineVirtualSystem_INPUT xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wmi/root/virtualization/MSVM_VirtualSystemManagementService">
      <p:SystemSettingData>
        <p:MSVM_VirtualSystemGlobalSettingData xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wmi/root/virtualization/MSVM_VirtualSystemGlobalSettingData">
          <p:ElementName>Venkatjava</p:ElementName>
        </p:MSVM_VirtualSystemGlobalSettingData>
      </p:SystemSettingData>
    </p:DefineVirtualSystem_INPUT>
  </s:Body>
</s:Envelope>

===============

Thanks in advance

Venkat