Forum Discussion
Connect -MsolService does not work with MFA
- Sep 04, 2017
i 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
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
When I tried to run connect-msolservice, it gave me a blank screen. same with connect-azureAD.
- Aawesh SayyedSep 05, 2018Copper ContributorI was able to fix it by running the below commands in PS ISE as admin:
Find-Module MSOnline
Install-Module MSOnline
Import-Module msonline
Connect-MsolService- Nov 08, 2018
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/
- AshromJan 09, 2019Copper Contributor
I had the same problem and Gareth your article Worked 100%
Thanks
Ash
- Sep 05, 2018
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?
- Aawesh SayyedSep 05, 2018Copper ContributorThanks for the reply!!!
I tried it on the server where i am still facing the issue. its still the same.- Sep 05, 2018
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.