How to create Azure SQL Admin and can access with "Active Directory-Universal with MFA Support" authentication from SSMS

 To access Azure SQL Database from SSMS through "Active Directory-Universal with MFA Support" authentication please follow the below steps.

1) Create an user Azure Active Directory level with MFA authentication.

a) Search Azure Active Directory in market place

b) Click add user so you can see the below image.

c) Provide initial password and create the user.


d) Now in the below image test user has been created
2) Add this test user to Directory Readers and Directory Writers role and also Global Administraor though the below image does not show it you can add it without missing. Please see the image. Chose those two roles and click on Add button and refresh. And choose authentication method too.


b) Now you could see test user allocated those two roles. and very important to access Azure Active directory users.



c) Now go to authentication provide users or your phone number(if you working at home for practice)
after providing the phone number with +91 XXXXXXXXXX click on save button.



3) Now go to SQL Server(search as 'SQL Server' in market place) not Azure SQL database. Set above user as Admin at SQL Server level. And go to "Azure Active Directory"  under settings tab and Set admin, after you click on set admin it will open another windows and provide your test user in search and the admin should be the above test users that we have created and click save button.


4) Now capture your Azure SQL Server info from SQL Server


5) Now open SQL Server management studio and provide Azure SQL Server name as mentioned below. And also notice you might get error or it will still shows progress without any progress

6) At this stage what you have to do is go to azure portal  switch user and it will ask for MFA authenticating and for new password, provide all those and after that come back to SSMS again access the server , this time it should work.










Comments

Popular posts from this blog

System.Data.SqlClient.SqlException (0x80131904): Execution Timeout Expired. The timeout period elapsed prior to completion of the operation or the server is not responding. ---> System.ComponentModel.Win32Exception (0x80004005): The wait operation timed out

Always On FailOver Events

Transparent Data Encryption(TDE) with Master Key and Certificate in SQL Server