MOVE
“{Mount database on the server with preference 1 (with colors)}”
Get-MailboxDatabase | Sort Name | ForEach {$db=$_.Name; $xNow=$_.Server.Name ;$dbown=$_.ActivationPreference| Where {$_.Value -eq 1}; Write-Host $db “on” $xNow “Should be on” $dbOwn.Key -NoNewLine; If ( $xNow -ne $dbOwn.Key){Write-host ” WRONG” -ForegroundColor Red; Move-ActiveMailboxDatabase $db -ActivateOnServer $dbOwn.Key -confirm:$False} Else {Write-Host ” OK” -ForegroundColor Green}}
Verify
“{Verify if the database is mounted on the server with preference 1 (with colors)}”
Get-MailboxDatabase | Sort Name | ForEach {$db=$_.Name; $xNow=$_.Server.Name ;$dbown=$_.ActivationPreference| Where {$_.Value -eq 1}; Write-Host $db “on” $xNow “Should be on” $dbOwn.Key -NoNewLine; If ( $xNow -ne $dbOwn.Key){Write-host ” WRONG” -ForegroundColor Red; } Else {Write-Host ” OK” -ForegroundColor Green}}
'기술(MS,Web,Windows,AWS) > [MS]Exchange2013' 카테고리의 다른 글
메일(메시지) 헤더 분석편 References (0) | 2016.05.25 |
---|---|
ISAPI Filter (0) | 2016.03.11 |