Connect-AzureAD vs Connect-MsolService?

My company has a hybrid O365 environment. I am writing a script for creating a user on-premise (new-aduser) and then assigning licenses.

Based on this documentation, it sounds like I can use either “Connect-AzureAD ” or “Connect-MsolService” to get the O365 user and then assign the licenses.

What are the pros and cons of each? It appears Azure-AD is the newer syntax. I am running the script on a Windows 10 machine with the appropriate modules imported, I have already tested and both connection modules seem to work.

I would prefer to use Azure-AD, however I am not sure if my company’s hybrid environment even syncs properly with Azure. I know that “new-aduser” eventually populates up to the Office 365 admin center, but from there I am not sure whether I should use the AzureAD or Msol module.

submitted by /u/jeffreymcclain
[link] [comments]

Leave a Reply