File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 23
23
foreach ($dvpgname in $DVPortgroupName ) {
24
24
$dvpg = Get-VDPortgroup - Name $dvpgname - ErrorAction SilentlyContinue
25
25
$switchVersion = ($dvpg | Get-VDSwitch ).Version
26
- if ($dvpg -and $switchVersion -eq " 6.6.0" ) {
26
+ if ($dvpg -and $switchVersion -ge " 6.6.0" ) {
27
27
$securityPolicy = $dvpg.ExtensionData.Config.DefaultPortConfig.SecurityPolicy
28
28
$macMgmtPolicy = $dvpg.ExtensionData.Config.DefaultPortConfig.MacManagementPolicy
29
29
41
41
}
42
42
$securityPolicyResults
43
43
} else {
44
- Write-Host - ForegroundColor Red " Unable to find DVPortgroup $dvpgname or VDS is not running 6.6.0"
44
+ Write-Host - ForegroundColor Red " Unable to find DVPortgroup $dvpgname or VDS is not running 6.6.0 or later "
45
45
break
46
46
}
47
47
}
@@ -92,7 +92,7 @@ Function Set-MacLearn {
92
92
foreach ($dvpgname in $DVPortgroupName ) {
93
93
$dvpg = Get-VDPortgroup - Name $dvpgname - ErrorAction SilentlyContinue
94
94
$switchVersion = ($dvpg | Get-VDSwitch ).Version
95
- if ($dvpg -and $switchVersion -eq " 6.6.0" ) {
95
+ if ($dvpg -and $switchVersion -ge " 6.6.0" ) {
96
96
$originalSecurityPolicy = $dvpg.ExtensionData.Config.DefaultPortConfig.SecurityPolicy
97
97
98
98
$spec = New-Object VMware.Vim.DVPortgroupConfigSpec
@@ -129,8 +129,8 @@ Function Set-MacLearn {
129
129
$task1 | Wait-Task | Out-Null
130
130
}
131
131
} else {
132
- Write-Host - ForegroundColor Red " Unable to find DVPortgroup $dvpgname or VDS is not running 6.6.0"
132
+ Write-Host - ForegroundColor Red " Unable to find DVPortgroup $dvpgname or VDS is not running 6.6.0 or later "
133
133
break
134
134
}
135
135
}
136
- }
136
+ }
You can’t perform that action at this time.
0 commit comments