Sep 04 2017 10:39 PM
Community
My Global Admin account in my tenant is configured for MFA. I have installed MS Exchange Online PowerShell Module and I am able to successfully log in with MFA.
I need to perform an update using Set-MsolUserPrincipalName, however it complains I need to run Connect-MsolService first.
When I do this, I am presented with a basic sign-in box (not MFA) and it just does not work to log in using the same credentials I used with the inital login.
What am I missing here?
Regards,
Sep 04 2017 11:26 PM
Solutioni think, you are using old version Azure active directory module powershell, so you can try with new version 1.1.166.0 or 2.0
Sep 04 2017 11:30 PM
Just to add some links:
AzureAD V2 module: https://www.powershellgallery.com/packages/AzureAD/2.0.0.131
MSOnline module: https://www.powershellgallery.com/packages/MSOnline/1.1.166.0
In case you want an old-school MSI install: https://connect.microsoft.com/site1164/Downloads/DownloadDetails.aspx?DownloadID=59185
Sep 04 2017 11:50 PM
Thanks a lot for your reply.
I thought I had the latest, but I went to my Exchange Admin Center under hybrid and installed the latest. Now it seems to work fine and I am presented with the same MFA login box when I use Connect-MsolService cmdlet.
Regards,
Thomas
Sep 05 2018 04:31 AM
When I tried to run connect-msolservice, it gave me a blank screen. same with connect-azureAD.
Sep 05 2018 05:08 AM
It seems cookies are blocked on your client or some firewall things preventing you to open the window properly. Can you allow cookies and try it again?
Sep 05 2018 05:48 AM
Sep 05 2018 05:58 AM
Sep 05 2018 06:06 AM
Can you try to open login.microsoftonline.com in the browser on the affected machine? It seems something like application firewall or proxy configuration doesn't allow you to open the login window.
Sep 05 2018 06:28 AM
Sep 05 2018 06:31 AM
And this is your problem ;) change Internet Explorer cookie / security settings to allow to open pop ups, etc. I don't know your current configuration but try it on an other client/server to compare these settings.
It must be available via Internet Explorer and if this works, the login window will work as well.
Sep 18 2018 12:24 AM
Could you find the issue and did it work?
Nov 08 2018 04:48 AM
I ran into a similar issue myself recently on a PC. For me, the issue was also an outdated MSOnline package. However, I had the original 1.0 module which came via MSI. I had to uninstall 1.0 first from Control Panel before it would let me run Install-Module -Name MSOnline
I documented the process here https://supertekboy.com/2018/11/07/connect-msolservice-may-fail-when-mfa-is-enabled/
Jan 09 2019 01:10 PM
I had the same problem and Gareth your article Worked 100%
Thanks
Ash
Sep 04 2017 11:26 PM
Solutioni think, you are using old version Azure active directory module powershell, so you can try with new version 1.1.166.0 or 2.0