Hi all,
We created a new VIB that adds a plugin to the esxcli command (attached).
(NOTE - the vib was created for "community"acceptance level)
the plugin will install 2 files on the system - esxcli XML file plugin (see link below on how to create one) & a warrper script that runs partedUtil and return the output, pasrsed into excpeted XML structer (esxcli command require it).
Then i packed it as a VIB and instlled it on the esxi. After i restared the ESXi i can run partedUtil command using esxcli:
# esxcli
Usage: esxcli [options] {namespace}+ {cmd} [cmd options]
Options:
--formatter=FORMATTER
Override the formatter to use for a given command. Available formatter: xml, csv, keyvalue
--debug Enable debug or internal use options
--version Display version information for the script
-?, --help Display usage information for the script
Available Namespaces:
esxcli Commands that operate on the esxcli system itself allowing users to get additional information.
fcoe VMware FCOE commands.
hardware VMKernel hardware properties and commands for configuring hardware.
hp hpnmi esxcli plugin
hpacucli HP Array Configuration Utility CLI
hpbootcfg HP Boot Configuration Utility
iscsi VMware iSCSI commands.
network Operations that pertain to the maintenance of networking on an ESX host. This includes a wide variety of
commands to manipulate virtual networking components (vswitch, portgroup, etc) as well as local host IP,
DNS and general host networking settings.
parted swp command for partedutil
sched VMKernel system properties and commands for configuring scheduling related functionality.
software Manage the ESXi software image and packages
storage VMware storage commands.
system VMKernel system properties and commands for configuring properties of the kernel core system.
vm A small number of operations that allow a user to Control Virtual Machine operations.
And this is what happen when i run it:
# esxcli parted cmd -q 'getptbl /vmfs/devices/disks/mpx.vmhba32:C0:T0:L0:8'
unknown
36 255 63 585696
I used this post on how to create the esxcli plugin:
http://www.v-front.de/2013/01/how-to-write-your-own-esxcli-plugin.html#uds-search-results
I used this documantion on how to pack it into a VIB:
http://www.virtuallyghetto.com/2012/09/creating-custom-vibs-for-esxi-50-51.html