NeedToKnowBasis
Enthusiast
Enthusiast

Creating Virtual Machines using PowerCLI based on data from CSV file

Jump to solution
I am attempting to find out how or whether it is possible to create a PowerCLI script that will handle creating Virtual Machines (VM's) within specific clusters based on a CSV file.
I have found some solutions that involve having PowerCLI read from XML files and I want to determine if CSV file data is also an option and if so, how to go about doing it.
Background: Users input the VM specification data into an Excel 'request' form, a VBA script is used to translate that data to a CSV file and I am wondering if it would be possible to have a PowerCLI script read from that resulting CSV files data to create the VM's with the specified values (to be reviewed prior to executing to ensure data is correct/relevant).
Thank you for any help you may provide
1 Solution

Accepted Solutions
Madmax01
Expert
Expert

Hello there,

sure that is possible Smiley Wink.

you could use the cmdlet  import-csv  Smiley Wink.

Import-Csv

you could just easy create the csv file and then you import it and doing youre VM Creatings based on the values inside the csv Smiley Wink.

Examples:

http://vmwaremine.com/2014/06/06/yet-another-script-deploy-multiple-vms-csv-input/#sthash.t6C1sUGI.d...

Powershell and importing .CSV files - Yellow Bricks

best regards

Max

View solution in original post

1 Reply
Madmax01
Expert
Expert

Hello there,

sure that is possible Smiley Wink.

you could use the cmdlet  import-csv  Smiley Wink.

Import-Csv

you could just easy create the csv file and then you import it and doing youre VM Creatings based on the values inside the csv Smiley Wink.

Examples:

http://vmwaremine.com/2014/06/06/yet-another-script-deploy-multiple-vms-csv-input/#sthash.t6C1sUGI.d...

Powershell and importing .CSV files - Yellow Bricks

best regards

Max

View solution in original post