Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 293210

How to change virtual disk adapter of virtual machine with perl

$
0
0

Hi

 

I have use the tool "vmcreate.pl" in the Perl SDK  to create a virtual machine on the ESXi 5.

 

I have specified the guestid to windows 2008 x64 r2, and the whole xml is the following:

 

<?xml version="1.0"?>
<Virtual-Machines>
         <Virtual-Machine>
            <Name>test_web5</Name>
                <Host>vmware16.openqrm</Host>
                <Datacenter>ha-datacenter</Datacenter>
                <Guest-Id>windows7Server64Guest</Guest-Id>
                <Datastore>bak</Datastore>
                <Disksize>10240000</Disksize>
                <Memory>512</Memory>
                <Number-of-Processor>1</Number-of-Processor>
                <Nic-Network>VM Network</Nic-Network>
                <Nic-Poweron>0</Nic-Poweron>
         </Virtual-Machine>
</Virtual-Machines>

After the tool runs, the virtual machine has been created on the ESXi server.

The problem is  that the scsi adapter of the machine is buslogic,and the machine cannot be started due to the windows server 2008 r2 cannot figure out the buslogic. I have to change the disk adapter to lsilogic manually.

 

So my question is how to change the disk adapter by perl, and any code example will be better.

 

Thank you so much!

 

Best reguard!

 

chu


Viewing all articles
Browse latest Browse all 293210

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>