Using MOB, to Invoke the Method RetrieveDiskPartitionInfo, how to specify the value of devicePath, which is String[] type?
Specifying a devicePath value from a disk such as "/vmfs/devices/disks/naa.60060160ec000e007a9e03a417aede11" is not working and throws "Invalid Argument". Does it require any special XML tags around it.
devicePath specified as string[] type in the documentation -
devicePath (required) string[]
Thanks
It's actually not the devicePath that you're referencing there. It's actually physical devices that needs to be provided, take a look at this vSphere SDK for Perl script that provides an example:
=========================================================================
William Lam
VMware vExpert 2009
VMware ESX/ESXi scripts and resources at:
VMware Code Central - Scripts/Sample code for Developers and Administrators
If you find this information useful, please award points for "correct" or "helpful".
Referring to the devicePath in the MOB Browse from the URL:(not from the SDK)
https://<ESXSERVER>/mob/?moid=<storageSystemMOR>&method=retrieveDiskPartitionInfo
Thanks
Yes, I know, but you still need to pass in the right value Hence I was pointing to my script to give you and example.
Any reason you're using the MOB to perform operations? It's primarily there to help show you what some of the objects and data structures look like, would be easier to use one of the SDK's to perform some of these operations.
=========================================================================
William Lam
VMware vExpert 2009
VMware ESX/ESXi scripts and resources at:
VMware Code Central - Scripts/Sample code for Developers and Administrators
If you find this information useful, please award points for "correct" or "helpful".
One of the our customers using VSphere4.0 with ESX 3.5 is having an issue with the method retrieveDiskPartitionInfo. It was working ok earlier when the customer was using VCenter. Recently they upgraded from VCenter to VSphere4.0 and the problem started. To debug it, planning to run the method from the MOB Browser in the customer enviroment. Trying it for now in the lab. Is there special syntax/xml tags that needs to be passed for devicePath to get it working?
Thanks
Nope, it should just be a string array (e.g. )
There's a good chance the syntax may have changed from VI 3.5 to vSphere 4.0
As mentioned in my original reply, the devicePath should something like /dev/cciss/c0d0 or /dev/sda, etc. which is the full device path seen from the Service Console on classic ESX or Busybox console of ESXi.
Here's some documentation around this new naming convention - http://pubs.vmware.com/vsp40u1/wwhelp/wwhimpl/js/html/wwhelp.htm#href=install/c_disk_device_names.ht...
=========================================================================
William Lam
VMware vExpert 2009
VMware ESX/ESXi scripts and resources at:
VMware Code Central - Scripts/Sample code for Developers and Administrators
If you find this information useful, please award points for "correct" or "helpful".
How to specify the String array in the Text Field of devicePath if I have the device path as "/dev/sda" ?
Thanks
Found a document that explains how to specify the parameter values for MOB Browser.
Providing xml tag devicePath around the value works. Something like -
<devicePath>/dev/sda</devicePath>