VMware {code} Community
pranags
Contributor
Contributor
Jump to solution

How to find the disk locations for a VM

Hi,

What is the API to find all the disk locations for a VM?

I would like to get paths for vmdk files of the VM

Thanks,

Prasad

Reply
0 Kudos
1 Solution

Accepted Solutions
dmhaynes
Enthusiast
Enthusiast
Jump to solution

The VirtualMachine managed object has a property named 'layout'.

The path to the disk files is:

layout -> disk\[] -> diskFile[]

View solution in original post

Reply
0 Kudos
2 Replies
dmhaynes
Enthusiast
Enthusiast
Jump to solution

The VirtualMachine managed object has a property named 'layout'.

The path to the disk files is:

layout -> disk\[] -> diskFile[]

Reply
0 Kudos
hrobinson
VMware Employee
VMware Employee
Jump to solution

Here you go.