Difference between revisions of "PowerCLI Powerhsell"

From Michael's Information Zone
Jump to navigation Jump to search
(Created page with "<pre> Set-ExecutionPolicy RemoteSigned </pre>")
 
Line 1: Line 1:
 +
Allow powershell to run powercli cmdlets
 
<pre>
 
<pre>
 
Set-ExecutionPolicy RemoteSigned
 
Set-ExecutionPolicy RemoteSigned
 +
</pre>
 +
Log into the server and start using commands
 +
<pre>
 +
$cred=get-credential
 +
connect-viserver -server localhost -credential $cred
 +
get-vm
 
</pre>
 
</pre>

Revision as of 08:28, 31 May 2017

Allow powershell to run powercli cmdlets

Set-ExecutionPolicy RemoteSigned

Log into the server and start using commands

$cred=get-credential
connect-viserver -server localhost -credential $cred
get-vm