PowerShell で Microsoft Online Services 拡張コマンドレッドを利用する
Microsoft Online Services では、日々の管理や移行作業の自動化を行えるようにするために、Windows PowerShell コマンドレットを拡張してコマンド ラインから作業が行えるようになっています。Windows PowerShell スクリプトを使って Microsoft Online Services の管理を行うには、Microsoft Online Services 移行ツールや Windows PowerShell をインストールしておく必要があります。詳細は以下を参照してください。
Microsoft Online Services の拡張コマンドを PowerShell で実行できるようにするには、最初に以下のコマンドレットを実行しておきます。
add-PSSnapIn Microsoft.Exchange.Transporter
ちなみに、「移行コマンド シェル」から Microsoft Online Services 専用の Windows PowerShell スクリプトを実行する場合は、このコマンドを実行する必要はありません。
このスナップインにより、以下のコマンドが使えるようになります。
- Add-MicrosoftOnlineExchangeItem
- Add-MSOnlineUser
- Add-MSOnlineMailPermission (Update)
- Add-XsExchangeForwardingAddress
- Add-XsExchangeOnlineItem
- Clear-MSOnlineAlternateRecipient
- Disable-MSOnlinePOPAccess
- Enable-MSOnlinePOPAccess
- Enable-MSOnlineUser
- Export-TransporterBinary
- Get-ImapMailbox
- Get-ImapMailboxData
- Get-InternetMailbox
- Get-MSOnlineSubscription
- Get-MSOnlineUser
- Get-PopMailbox
- Get-PopMailboxData
- Get-XsActiveDirectoryUser
- Get-XsExchangeMailboxData
- Get-xsHostedExchangeMailbox
- Get-xsHostedExchangeMailboxData
- Import-TransporterBinary
- Move-XsExchangeMailboxToExchangeOnline
- Move-xsHostedExchangeMailboxToExchangeOnline
- Move-XsImapMailboxToExchangeOnline
- Move-XsPopMailboxToExchangeOnline
- Remove-MSOnlineMailPermission
- Remove-MSOnlineUser
- Remove-XsExchangeForwardingAddress
- Search-XsMicrosoftOnlineDirectory
- Set-MSOnlineAlternateRecipient (Update)
- Set-MSOnlineUser
- Set-MSOnlineUserPassword
- Set-MSOnlineUserPasswordNeverExpire (New)
- Set-xsMicrosoftOnlineMigrationStatus