====== Cmdlets for protecting Microsoft Exchange server data (TDP exchange) ======
PowerShell 3 or later is required
The following table identifies the cmdlets that are available for use to protect Microsoft Exchange server data (Cmdlets to protect Microsoft Exchange Server data).
Enter the following commands to load PowerShell Modules:
import-module .\FmModuleExc.dll
import-module .\FmModuleMMC.dll
Or to use the cmdlets in these modules any time you start Windows PowerShell, add the following lines to your profile:
$path = (get-itemproperty -path "HKLM:\SOFTWARE\IBM\TDPExchange\
currentversion\mmc" -ea SilentlyContinue).path
if ($null -ne $path)
{
dir "$path\fmmodule*.dll" | select -expand fullname | import-module
-force -Global
}
^Cmdlet name^Related command-line interface command^Short description^
| Add-DpExcPolicy | tdpexcc create policy | Create a policy for FlashCopy® Manager for Microsoft Exchange Server. |
| Backup-DpExcComponent | tdpexcc backup | Back up a Microsoft Exchange database. |
| Copy-DpExcPolicy | tdpexcc copy policy | Copy an existing policy. |
| Dismount-DpExcBackup | tdpexcc unmount backup | Dismounts a backup. |
| Get-DpExcBackup | tdpexcc query tsm * | Query backups. |
| Get-DpExcComponent | tdpexcc query exchange | Query the Exchange Server for all databases that are available for backup. |
| Get-DpExcConfig | tdpexcc query tdp | Displays configuration information. |
| Get-DpExcConnection | tdpexcc query tsm | Query a list of the current values set in the configuration file for Tivoli® Storage Manager. |
| Get-DpExcInformation | tdpexcc query exchange | Query general local Exchange Server information. |
| Get-DpExcMailboxLocationHistory | | Query the mailbox location history. |
| Get-DpExcManagedCapacity | tdpexcc query managedcapacity | Query managed capacity for Microsoft Exchange Server. |
| Get-DpExcPolicy | tdpexcc query policy | Displays policy information. |
| Mount-DpExcBackup | tdpexcc mount backup | Mounts a backup to provide access to the files that the backup contains. |
| Remove-DpExcBackup | tdpexcc delete backup | Removes the backup. |
| Remove-DpExcPolicy | tdpexcc delete policy | Deletes the policy. |
| Reset-DpExcTsmPassword | tdpexcc changetsmpassword | Change the Tivoli Storage Manager password used by Data Protection for Exchange. |
| Restore-DpExcBackup | tdpexcc restore | Restore a backup. |
| Restore-DpExcMailbox | tdpexcc restore mailbox | Restore a mailbox. |
| Set-DpExcConfig | tdpexcc set paramname | Set the application configuration parameters in a configuration file. |
| Set-DpExcPolicy | tdpexcc update policy | Update a policy. |
To view the details about a specific cmdlet, run the Get-Help cmdlet with the cmdlet name. For example:
Get-Help Backup-DpExcComponent
To continue the example, to see examples for the cmdlet, enter:
get-help Backup-DpExcComponent -examples
For more information, enter:
get-help Backup-DpExcComponent -detailed
For technical information, enter:
get-help Backup-DpExcComponent -full
To go to the information center, enter:
get-help Backup-DpExcComponent -online
For information about a specific parameter, enter:
help Backup-DpExcComponent -Parameter backupdestination
To display the help in a separate window, include the -showwindow parameter with the help command.
Example of script
**listbackup.ps1**
cd "C:\Program Files\TSM-EXCH\FlashCopyManager"
import-module .\FmModuleExc.dll
import-module .\FmModuleFs.dll
import-module .\FmModuleMMC.dll
import-module .\FmModuleSQL.dll
Get-DpExcBackup|export-csv -NoTypeInformation -LiteralPath "C:\LogFiles\Tsm-EXCH\backuplist.csv"
remove-item ("\\filesrv01\d$\Reports\Exchange_backup\Backup_"+ $env:hostname +".csv") -Confirm:$false
Copy-Item "C:\LogFiles\Tsm-EXCH\backuplist.csv" ("\\filesrv01\d$\Reports\Exchange_backup\Backup_"+ $env:hostname +".csv")