From 23b36d60a3cad40aae6922f8d15ac458bee96daa Mon Sep 17 00:00:00 2001 From: yomurakami Date: Thu, 20 Jul 2017 01:45:05 +0900 Subject: [PATCH 1/2] load an assembly that is not loaed by default --- Modules/Backup-VCSA/Backup-VCSA.psm1 | 1 + 1 file changed, 1 insertion(+) diff --git a/Modules/Backup-VCSA/Backup-VCSA.psm1 b/Modules/Backup-VCSA/Backup-VCSA.psm1 index f5731c0..7eab203 100644 --- a/Modules/Backup-VCSA/Backup-VCSA.psm1 +++ b/Modules/Backup-VCSA/Backup-VCSA.psm1 @@ -50,6 +50,7 @@ ) Begin { if (!($global:DefaultCisServers)){ + Add-Type -Assembly System.Windows.Forms [System.Windows.Forms.MessageBox]::Show("It appears you have not created a connection to the CisServer. You will now be prompted to enter your vCenter credentials to continue" , "Connect to CisServer") | out-null $Connection = Connect-CisServer $global:DefaultVIServer } else { From d61cfc1b67d1580a49d59b28b564e15ef0711be9 Mon Sep 17 00:00:00 2001 From: yomurakami Date: Thu, 20 Jul 2017 02:08:51 +0900 Subject: [PATCH 2/2] seat only backup is impossible. so change to common only backup fix notes --- Modules/Backup-VCSA/Backup-VCSA.psm1 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Modules/Backup-VCSA/Backup-VCSA.psm1 b/Modules/Backup-VCSA/Backup-VCSA.psm1 index 7eab203..7b790d0 100644 --- a/Modules/Backup-VCSA/Backup-VCSA.psm1 +++ b/Modules/Backup-VCSA/Backup-VCSA.psm1 @@ -32,13 +32,13 @@ If a -LocationType is not chosen, the function will default to FTP. The destination location for a backup must be an empty folder (easiest to use the get-date cmdlet in the location) -ShowProgress will give you a progressbar as well as updates in the console - -SeatBackup will only backup the config whereas -Fullbackup grabs the historical data as well + -CommonBackup will only backup the config whereas -Fullbackup grabs the historical data as well #> param ( [Parameter(ParameterSetName=’FullBackup’)] [switch]$FullBackup, - [Parameter(ParameterSetName=’SeatBackup’)] - [switch]$SeatBackup, + [Parameter(ParameterSetName=’CommonBackup’)] + [switch]$CommonBackup, [ValidateSet('FTPS', 'HTTP', 'SCP', 'HTTPS', 'FTP')] $LocationType = "FTP", $Location, @@ -57,7 +57,7 @@ $Connection = $global:DefaultCisServers } if ($FullBackup) {$parts = @("common","seat")} - if ($SeatBackup) {$parts = @("seat")} + if ($CommonBackup) {$parts = @("common")} } Process{ $BackupAPI = Get-CisService com.vmware.appliance.recovery.backup.job