![]() ![]() Restore a Deleted Mailbox With PowerShell Now we’re working with PowerShell directly in Exchange Online, even though we’re sitting at our own computer. Use the following command to open a PoSh session on Exchange Online: import-PSSession $Session -DisableNameChecking Usually this is some variation of your company’s name. Powershell-liveid is the id of your Office site. $session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri -Credential $userCredential -Authentication Basic -AllowRedirection ![]() Now we’ll create the variable $session to be used to open a connection between the local computer and Exchange Online. But you may want to learn best practices for signing PowerShell scripts too. This allows us to run our unsigned commands. Next, set the execution policy level so that we can actually do things in our session. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |