Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion bestpractices.ps1
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
#Enter the following required parameters. Log folder directory is just and example, change as needed.
#If a specific cluster is to be targeted change "*" to "CLUSTER_NAME".
#Put all entries inside the quotes:
#**********************************
$vcenter = ""
$vcuser = ""
$vcpass = ""
$vccluster = "*"
$logfolder = "C:\folder\folder\etc\"
#**********************************

Expand Down Expand Up @@ -110,7 +112,7 @@ catch
add-content $logfile ('Connected to vCenter at ' + $vcenter)
add-content $logfile '----------------------------------------------------------------------------------------------------'

$hosts= get-vmhost
$hosts= get-cluster -Name $vccluster | get-vmhost

add-content $logfile "Iterating through all ESXi hosts..."

Expand Down