具有IP地址的客户端不允许访问服务器Azure SQL数据库 [英] Client with IP address is not allowed to access the server Azure SQL database

查看:340
本文介绍了具有IP地址的客户端不允许访问服务器Azure SQL数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试连接到免费试用帐户的Azure SQL数据库时,遇到以下错误.谁能帮助我在免费试用帐户中设置规则?我看不到任何设置它们的选项.

I am facing the below error when I try to connect to the Azure SQL database of my free trial account. Can anyone help me how to set rules in my free trial account? I don't see any option to set them.

Cannot open server 'ccaausprddb001' requested by the login. Client with
IP address '125.16.236.150' 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. 
ClientConnectionId:f1ce6d56-c321-4458-a8dc-507f40e24108
com.microsoft.sqlserver.jdbc.SQLServerException: Cannot open server 'ccaausprddb001' requested by the login. Client with IP address '125.16.236.150' 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.

推荐答案

这可以通过配置SQL数据库所在的Azure SQL Server的防火墙来解决.我正在使用新的Microsoft Azure门户.请查看下面的屏幕截图, 请记住,您需要配置防火墙并管理SQL Server(而不是SQL数据库)中的IP地址.

This can be solved by configuring the Firewall of the Azure SQL Server where the SQL database resides. I am using the new Microsoft Azure Portal. Please see the screenshot below, Remember, you need to configure the Firewall and manage the IP addresses in SQL Server, not the SQL database.

一旦选择了SQL Server,

Once you have selected the SQL Server,

  • 点击设置->防火墙
  • 将要求您添加新规则.
  • 添加名称并输入要访问的IP地址(或范围) 数据库.注意:Azure会自动检测您当前的IP.
  • Click the Settings -> Firewall
  • You will be requested Add a new Rule.
  • Add a name and enter the IP address(or the range) that will access the database. note: Azure automatically detects your current IP.

等待5分钟,您就可以开始了.我希望这会有所帮助.

Wait for 5 minutes and you are ready to go. I hope this helps.

这篇关于具有IP地址的客户端不允许访问服务器Azure SQL数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆