Hi all,
Looking for pointers/suggestions. I am running some long tasks against
Exchange Online using Remote PowerShell and when a session disconnects or enters a "Broken" state, it will either exit the script (not collecting all the data we want) or pause, waiting for credentials to be input before creating a new session.
(Have tried Server 2008/PowerShell 2.0, Windows8/PowerShell 3.0, Windows 8.1/PowerShell 4.0).
Large departmental changes prevent an easy grab of objects from a specific OU, so I am looking at Get-Mailbox and Get-MailboxStatistics command-lets in particular.
Does anyone have any suggestions on how to monitor for a broken session and pick-up where it left off at, or how to optimize a code executed against the remote session as to not hit throttling (100k+ objects)? WouldGet-Recipientact as a good starting filter from the On-Premises environment before running against the PowerShell online service?
Thanks.