VMware Cloud Community
gregchait
Enthusiast
Enthusiast

Quick vMA CLI question... host's datastores...

Hello

I am wondering if there is a quick and easy command for me to view the contents of the /vmfs folder of a host. I know I would run a simple ls if I was on a console, but in vMA this is not the case. I have to figure there's a way to do it... any help?

(working with ESXi 4.1 & vMA 4.1)

Greg C.

0 Kudos
2 Replies
lamw
Community Manager
Community Manager

Take a look at using the vSphere SDK for Perl Utilities which is bundled with vMA - http://www.vmware.com/support/developer/viperltoolkit/viperl41/doc/vsperl_util_index.html

You'll want to use dsbrowse.pl which allows you to list contents of a given VMFS volume and it's directories.

=========================================================================

William Lam

VMware vExpert 2009,2010

VMware VCP3,4

VMware VCAP4-DCA

VMware scripts and resources at:

Twitter: @lamw

Getting Started with the vMA (tips/tricks)

Getting Started with the vSphere SDK for Perl

VMware Code Central - Scripts/Sample code for Developers and Administrators

VMware Developer Community

If you find this information useful, please award points for "correct" or "helpful".

dcoz
Hot Shot
Hot Shot

another option is the vifs command. This will list the datastores and the -D option will list the contents of the datastore

Hope this helps

Dougie