Amazing connection, powercli + vsphere cli

Now that was a very very very good post from Robert. You can check this post and his blog at
Once you create this function ‘Add-vCLIfunction’ and run it, you can easly run ‘functions’ from vSphere CLI. This is very very very useful.
All of those perl scripts from vsphere cli will become available for us like a function. Well we can just now simply type ‘vifs’ and bam! One thing worth mentioning here, it does not do the ‘powercli’ ‘powershell’ style output 😉 don’t forget about this, this is not an object. Basically we are still executing perl scripts, so the output is just simple text. But still you receive functions from vSphere CLI.
$a=vicfg-nics -l –server myHost1
$a|get-member -> string[]
Quick example:
I want to download quickly hostd.log from esx box
vifs –server myHost.Local -g /host/hostd.log c:\hostd.log
All sorts of things using vifs:

One thought on “Amazing connection, powercli + vsphere cli

  1. Thanks for sharing a Good trick, But whenever I use perl script under power shell It keeps on executing. It should execute once only!! Your help will be appreciated.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s