Symptoms

When you scan an Exchange Online organization using the Microsoft Exchange Organization agent, you see the following error

Error executing PowerShell command 'Connect-ExchangeOnline'. The user "userid" isn't assigned to any management roles.

Cause

This can occur when the service principal has not been configured correctly in Exchange Online and has not been assigned any management roles.


Resolution

Follow the steps in the Service Principal (Certificate) section.