In this tutorial we will learn How to fix the error Cannot Open Server Requested By The Login Azure SQL which you might come across while login into the Azure SQL database.
Cannot Open Server Requested By The Login Azure SQL [Solved]: How to fix this error
To solve this error you need to update the Client IP in the firewall settings of your SQL database. To update the firewall settings, Go to the overview Page of your SQL database and select Set server Firewall. Now update the Client IP and switch the “Allow azure services and resources to access this server ” to Yes and Save.
While writing a stored procedure in AZURE SQL DB when you try to login to the Query Editor (Preview ) you might come across this error.
” Cannot Open Server Requested By The Login Azure SQL “
Let’s try to reproduce the issue and then we will go through the Solution
Step 1: Logon to Azure Portal
Step 2: Under Azure Services Click on SQL Databases
or Search for SQL database in the search area.
Once you select the SQL database, all the available Azure SQL databases under your resource group will be visible.
Select your desired SQL database and then click on the Query editor (preview) option on the left-hand menu pane as shown below.
You will see all your list of Azure SQL databases here. Click on the one that you want to use. Now click on the Query editor (preview) link from the left navigation on the SQL database page. Enter the Login Username and password and click on the Login button, you can able to see I got the below error.
Now for SQL server authentication provide the login username and password.
After providing the username and password when we click on OK, we get the following error.
Complete error message :
Cannot open server ‘ilhfnwgq7kvic’ requested by the login. Client with IP address ‘IP address is not allowed to access the server. To enable access, use the Windows Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range. It may take up to five minutes for this change to take effect. Set server firewall (ilhfnwgq7kvic)
Follow the below steps to solve the above error
Step 1: Go to the overview Page of your SQL database.
Step 2: Now click on “Set server Firewall”
Click on the Set server firewall option on the right-hand side as shown below.
Step 3: Update the Client IP in firewall Settings
- Under firewall settings provide an Under rule name, specify a rule name and specify the client IP address in the Start IP and End IP.
- Select Yes under “Allow Azure services and resources to access this server “
- Now click on Save to save the settings
Now you will get the below message. This means our firewall rules have been successfully updated.
Step 4: Try to Login again with the username and password.
Go back to the query editor in the SQL database and enter the username and password.
This time we are successfully connected as the client IP has been added in the firewall rules and we get the Query editor screen.
To log on and connect to the Azure SQL database the Client IP must be added in the Firewall rules. You can update the client IP following the preceding step-by-step guide.
We hope this tutorial on How to Solve Cannot Open Server Requested By The Login Azure SQL was helpful.
How to Check Azure Credit ( Easy Guide )
The term Get-AzureAccount is not recognized error: How to fix it
How to fix Because of Protocol Error Code 0x112d ( Easy Guide)