Creating an EagerZeroedThick disk with PowerCLI

Hey…. -  that is not possible – I hear you say – well in principle you are right. Up until today…

By mistake of course – I found that there was a change made to the 5.1 release of PowerCLI – but this change has not been documented anywhere – which I think is a shame. This post is the only public reference I know of.

Up until the 5.1 release you could not create an EagerZeroedThick hard disk with PowerCLI. Let’s look at the 5.0 documentation for PowerCLI.


As you can see above the options are Thin or Thick and if you go to look at the
VirtualDiskStorageFormat – Enum you will see the that there is no EagerZeroedThick option.


The PowerCLI changelog has a new Cmdlet Move-Harddisk – which as you can see allows you to migrate a VMDK from one location to another – and if you also noticed..

5.1 New-Harddisk

Yep, EagerZeroedThick is one of the options as you can see above. The VirtualDiskStorageFormat – Enum was not updated though.

So I used this today as part of a bigger automation process to prepare some VM’s for Oracle RAC (which I will post about in the not too distant future)

get-vm $vm1 | New-HardDisk -DiskType flat -CapacityGB 2 -StorageFormat EagerZeroedThick -Datastore $dbds |New-ScsiController -Type ParaVirtual -BusSharingMode NoSharing

Which is so much easier than… (taken from Luc Deken’s post)

$vmName = <vm-name>
$vCenter = <vCenter-name>
$esxAccount = <ESX-account>
$esxPasswd = <ESX-password>

function Set-EagerZeroThick{
	param($vcName, $vmName, $hdName)

# Find ESX host for VM
	$vcHost = Connect-VIServer -Server $vcName -Credential (Get-Credential -Credential "vCenter account")
	$vmImpl = Get-VM $vmName
	if($vmImpl.PowerState -ne "PoweredOff"){
		Write-Host "Guest must be powered off to use this script !" -ForegroundColor red
		return $false

	$vm = $vmImpl | Get-View
	$esxName = (Get-View $vm.Runtime.Host).Name
# Find datastore path
	$dev = $vm.Config.Hardware.Device | where {$_.DeviceInfo.Label -eq $hdName}
		return $false
	$hdPath = $dev.Backing.FileName

# For Virtual Disk Manager we need to connect to the ESX server
	$esxHost = Connect-VIServer -Server $esxName -User $esxAccount -Password $esxPasswd

# Convert HD
	$vDiskMgr = Get-View -Id (Get-View ServiceInstance -Server $esxHost).Content.VirtualDiskManager
	$dc = Get-Datacenter -Server $esxHost | Get-View
	$taskMoRef = $vDiskMgr.EagerZeroVirtualDisk_Task($hdPath, $dc.MoRef)
	$task = Get-View $taskMoRef
	while("running","queued" -contains $task.Info.State){

	Disconnect-VIServer -Server $esxHost -Confirm:$false

# Connect to the vCenter
	Connect-VIServer -Server $vcName -Credential (Get-Credential -Credential "vCenter account")
	if($task.Info.State -eq "success"){
		return $true
		return $false

Set-EagerZeroThick $vCenter $vmName "Hard disk 1"

Ah the little things…..

I wonder what other gems are hidden deep in the bowels of PowerCLI that were not updated in the changelog/release notes?? …. What do you think ??


Do You Have What It Takes To Be A Cloud Architect?

This question is something that I have come across in a number of ways and variations over the past few months and on some occasions I have actually been asked the following:

  • Are you a cloud architect?
  • Can you build me an cloud environment like Amazon?
  • Can you explain to me over lunch how to build a cloud?

Granted, the last one made me laugh, but the rest of them are pretty valid.Build me a Cloud

A while back there was a great demand for the professional that could build a solid and sound virtual infrastructure. Don’t get me wrong – the demand is still there – very much so, but since then a new and more sophisticated skill is being asked for..  - ”Build me a cloud..

So before we can answer the first and most important question – I think it would be fair to ask what is a cloud? And the simple answer to that is – wait .. there is not simple answer to that. It will depend on who you ask. Let’s see how the big cloud players define cloud.


Cloud computing empowers IT through flexible, automated infrastructures, new on-demand service models and new levels of IT efficiency. All this allows IT to shift resources from maintaining existing systems to invest in building innovative services that drive new revenue, improve operations and advance business goals. (Source)


NIST defines five essential characteristics, three service models and four deployment models. The essential characteristics form the core of the definition. The required characteristics for any solution to be called a true “cloud” solution include:

  • On-demand self-service
  • Broad network access
  • Resource pooling
  • Rapid elasticity
  • Measured service

NIST also defines three service models, or what are sometimes called architecture layers:

  • Infrastructure as a Service (IaaS)
  • Software as a Service (SaaS)
  • Platform as a Service (PaaS)

Finally, it defines four deployment models:

  • Private Cloud
  • Community Cloud
  • Public Cloud
  • Hybrid Cloud (Source)

Cloud Computing is really about delivering IT as a Service, the idea of managing and delivering applications and services for business value and impact, as opposed to focusing on where those applications and services run or what level they run on. “What it Means” is that Cloud Computing gives companies the capability to be more flexible, more agile, in meeting the needs of the business. This is because the Cloud removes the traditional limitations and boundaries associated with allocating or moving services. Once those restriction are removed, it becomes second nature for IT to respond to specific requirements of the business. Thus, changes and optimization become part of the standard run of the business and the time that IT used to spend being reactionary can now be used to be innovative and forward thinking. (Source)


Gartner defines cloud computing as a style of computing in which scalable and elastic IT-enabled capabilities are delivered as a service using Internet technologies. (Source)

So now that we are all clear – well actually are not quite clear on what a cloud is – let us still try and define what skills are needed from someone to design a cloud solution.

So the first thing that a headhunter would look for is the letters behind someone’s name (and I think we all can safely say that this is not the right way to do it- but still)

I went on a search for which cloud certifications there are and came up with the following list.

VCDX-Cloud which is VMware’s upcoming top-level certification for those architects who can display their qualifications and expertise in designing vCloud solutions. So where was Amazon? Amazon have an Architecture course – no certification. Next up was OpenStack and Rackspace – which is only a technicians course. Microsoft and their Private Cloud Solutions Expert – but I would not really call this a architect level certification – but more of a administration level one. Last but not least – Redhat and their RHCVA – and again I see this as more of an administration exam than anything else.

So here we come back to my original question.

Do you have what it takes to be a cloud architect? Well at the moment I don’t think there is anything that can prove (or test for that matter) if an individual has those skills.

The biggest challenge I see here is that creating a cloud solution is not just creating the virtualization layer, or the storage layer, or the network layer, but also the orchestration behind it, the business model behind it, the elasticity, automation and the list really goes on and on. There is no one skill hat can be mastered here. It requires a multitude of expertise, a broad spectrum of knowledge is multiple fields, with a number of them not being virtualization related at all.

ArchitectI do think that as the market evolved more and more, the demand for such individuals will rise and so will the expertise of the professionals out there. If once upon a time there were only a handful of people that were capable of designing a robust virtual infrastructure – today, a number of years later – that handful has multiplied exponentially, this is the case with cloud architects.

The ease with which we manage and design our virtual infrastructure today will become the same for cloud infrastructures a few years in the future. It is all a matter of time.

If you would like to add your thoughts and comments on this article or which skills and expertise a cloud architect should have – please feel free to add them below.