0 Replies Latest reply on Jul 17, 2017 9:20 AM by nikubanov

    Modify VM Hardware During instantiation

    nikubanov Lurker

      Hello, dear community!

       

      We faced with the problem of changing the Virtual Hardware VM section (CPU/RAM) during the template instantiation. Seems to do all like documentation says but the template instantiates with it's default params of CPU and RAM.

       

      Here is example of XML request we've done

       

      <?xml version="1.0" encoding="UTF-8"?>
      <vcloud:RecomposeVAppParams
              xmlns:ovf="http://schemas.dmtf.org/ovf/envelope/1"
              xmlns:vcloud="http://www.vmware.com/vcloud/v1.5"
              powerOn="false">
          <vcloud:SourcedItem>
              <vcloud:Source href="https://myhost.com/api/vAppTemplate/vm-7498f8b7-09e6-4474-bdc0-50e2b411b790"/>
              <vcloud:VmGeneralParams>
                  <vcloud:Name>NEW-XX8</vcloud:Name>
                  <vcloud:NeedsCustomization>true</vcloud:NeedsCustomization>
              </vcloud:VmGeneralParams>
              <vcloud:InstantiationParams>
                  <ovf:VirtualHardwareSection
                          xmlns:vssd="http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_VirtualSystemSettingData"
                          xmlns:rasd="http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_ResourceAllocationSettingData"
                          xmlns:vmw="http://www.vmware.com/schema/ovf"
                          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                          ovf:transport=""
                          vcloud:type="application/vnd.vmware.vcloud.virtualHardwareSection+xml"
                          vcloud:href="https://myhost.com/api/vApp/vm-7498f8b7-09e6-4474-bdc0-50e2b411b790/virtualHardwareSection/" >
                      <ovf:Info>Virtual hardware requirements</ovf:Info>
                      <ovf:Item>
                          <rasd:AllocationUnits>byte * 2^20</rasd:AllocationUnits>
                          <rasd:Description>Memory Size</rasd:Description>
                          <rasd:ElementName>5120 MB of memory</rasd:ElementName>
                          <rasd:InstanceID>5</rasd:InstanceID>
                          <rasd:Reservation>0</rasd:Reservation>
                          <rasd:ResourceType>4</rasd:ResourceType>
                          <rasd:VirtualQuantity>5120</rasd:VirtualQuantity>
                          <rasd:Weight>0</rasd:Weight>
                      </ovf:Item>
                  </ovf:VirtualHardwareSection>
              </vcloud:InstantiationParams>
          </vcloud:SourcedItem>
      </vcloud:RecomposeVAppParams>
      

       

      Would be very pleased for helping..