Does anyone know an better way then vmkfstools -t0 to find out how many blocks that has not been zeroed out (i.e written to) in a lazyzero vmdk? I need to to this on thousands of powered on VM's.
Why did powercli come to your mind? Do you have any basic idea how to do it?
Yeah move it and we will see thanks
You mentioned "I need to to this on thousands of powered on VM's" which actually "cries" for a scripted solution, and since PowerCLI is something which provides a wide range of options, and some excellent people are active in this community, I thought it might be a good idea to move this thread over to it.
Afaik the vmkfstools command uses a number of private API for it's functionality.
So I'm afraid there is no direct alternative for executing the same function from within a PowerCLI script.
You can use plink.exe from the PuTTY Suite.
That way you can run the vmkfstools command through a SSH session on an ESXi node.
In this community there are a number of samples on how to do this.
The vmkfstools was just an example..(I am very aware of plink I can't use it anyway because it requires the VM to be powerd off. i.e I need some other solution. Any ideas?