This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
########################################################### | |
# # | |
# VMware Virtual SAN -- Making Storage Great Again # | |
# # | |
########################################################### | |
########################################################### | |
# # | |
# The All-in-One Virtual SAN Deployment Script # | |
# # | |
# by Alan Renouf and Rawlinson # |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#################################################################################### | |
# # | |
# VMware Virtual SAN -- All Flash Automated Deployment for Stretched Cluster # | |
# # | |
#################################################################################### | |
#################################################################################### | |
# # | |
# The All-in-One and Ultimate Virtual SAN Streched Cluster Config. Script # | |
# # |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$cluster = Get-Cluster CLU1 | |
(Get-View $cluster.ExtensionData.EnvironmentBrowser).QueryConfigOptionDescriptor() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Connect-VIServer myvcenter -user Administrator -password MyPass23 | |
Function Get-VsanHclDatabase { | |
<# | |
.NOTES | |
=========================================================================== | |
Created by: Alan Renouf | |
Organization: VMware | |
Blog: http://virtu-al.net | |
Twitter: @alanrenouf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Connect-viserver 10.160.200.218 -user [email protected] -Password "Admin!23" | |
Write-Host "Downloading latest Host Client VIB" -ForegroundColor Green | |
$source = "http://download3.vmware.com/software/vmw-tools/esxui/esxui_signed.vib" | |
$Vib = "$ENV:Temp" + "\esxui_signed.vib" | |
Invoke-WebRequest $source -OutFile $Vib | |
$Vibname = $vib.split("\")[-1] | |
Get-VMHost | Foreach { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$NumberOfSnapshotsToReport = 5 | |
$EmailFrom = "[email protected]" | |
$EmailTo = "[email protected]" # Add multiple with "mail1", "mail2", "Mail3" | |
$Subject = "VMs with $NumberOfSnapshotsToReport or more snapshots" | |
$SMTPServer = "smtp.mymailserver.com" | |
Connect-VIServer 172.16.88.200 -User [email protected] -Password VMware1! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Connect-VIServer 192.168.1.200 -User [email protected] -Password VMware1! | |
$vShieldInstallFile = "C:\Temp\VMware-vShield-Manager-5.5.3-2175697.ova" | |
$vShieldName = "VCNS01" | |
$vShieldNetwork = "VM Network" | |
$vShieldIP = "192.168.1.210" | |
$vShieldSNM = "255.255.255.0" | |
$vShieldDGW = "192.168.1.1" | |
$vShieldDNS = "192.168.1.1" | |
$vShieldCluster = "Home-Cluster" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Function New-DNATRule ( | |
$EdgeGateway, | |
$ExternalNetwork, | |
$OriginalIP, | |
$OriginalPort, | |
$TranslatedIP, | |
$TranslatedPort, | |
$Protocol) { | |
$Edgeview = Search-Cloud -QueryType EdgeGateway -name $EdgeGateway | Get-CIView | |
if (!$Edgeview) { |