简体   繁体   English

无法从本地网络远程登录到Azure VM

[英]Can't telnet to Azure VM from local network

I have a azure cloud cluster with an sql availability (2 sql machines and one quorum) group and a listener on port 51101. The cluster also contains several other VMs, all on the same virtual network. 我有一个带有sql可用性(2台sql机和一个quorum)组的Azure云群集,并且在端口51101上有一个侦听器。该群集还包含其他几个VM,所有VM都在同一虚拟网络上。

I'm having problem connecting to the listener, and the problem is not SQL specific, since I can't even telnet to the port. 我在连接到侦听器时遇到问题,并且该问题不是特定于SQL的,因为我什至无法远程登录到端口。 The weird thing is that this happens only when connecting from a machine on the same virtual network. 奇怪的是,仅当从同一虚拟网络上的计算机进行连接时才会发生这种情况。 If I try to connect from my local non-azure machine, everything works fine. 如果我尝试从本地非Azure计算机连接,则一切正常。 It also works if it's an azure machine on a different network. 如果它是另一台网络上的天蓝色机器,它也可以工作。

Here's what I have: - Firewall rules for the port. 这是我所拥有的:-端口的防火墙规则。 I even tried disabling the firewall completely on all the machines 我什至尝试在所有机器上完全禁用防火墙

  • The port has a load balanced endpoint on the Azure portal. 该端口在Azure门户上具有负载平衡的终结点。 Note that the same problem applies to all the ports that were open by default by Azure (RDP and WinRmHttps) - I can telnet to those ports from my machine, but not from a machine on the Virtual Network. 请注意,相同的问题也适用于Azure默认情况下打开的所有端口(RDP和WinRmHttps)-我可以从我的计算机远程登录到那些端口,但不能从虚拟网络上的计算机远程登录到这些端口。

  • I can reach the SQL intance directly (If I use the instance name instead of the listener) 我可以直接到达SQL实例(如果我使用实例名称而不是侦听器)

Here's my virtual network configuration: 这是我的虚拟网络配置:

网络配置

Any suggestions for the cause of the problem, or some ways to debug this are welcome. 欢迎提供任何有关问题原因的建议或一些调试方法。

Just in case anyone runs into this, I found the answer here : 万一有人遇到这个问题,我在这里找到了答案:

Keep in mind that your application, in case is deployed in Azure, cannot reside in the same Cloud Service with SQL Server VMs otherwise routing in Azure will fail: it's highly recommended to use a dedicated Cloud Service containing only the SQL Server VM; 请记住,如果您的应用程序部署在Azure中,则不能与SQL Server VM驻留在同一个Cloud Service中,否则在Azure中的路由将失败:强烈建议使用仅包含SQL Server VM的专用Cloud Service。

Once I put the connecting machine on a separate service, everything worked. 将连接机器放在单独的服务上后,一切正常。

Try these standard techniques for debugging listeners: http://www.eraofdata.com/verifying-and-troubleshooting-sql-server-listener-connectivity/ Azure won't treat them any differently if you are using a Virtual Network and a single Cloud Service. 尝试使用以下标准技术调试侦听器: http: //www.eraofdata.com/verifying-and-troubleshooting-sql-server-listener-connectivity/如果您使用的是虚拟网络和一个虚拟网络,则Azure不会对它们进行任何区别云服务。

Have you don't a netstat on the machine the listener is on to see if anything is listening on that TCP port? 您是否没有在监听器所在的计算机上设置netstat来查看该TCP端口上是否正在监听任何内容?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM