SQL远程连接在Google计算引擎上不起作用 [英] SQL remote connection not working on google compute engine

查看:90
本文介绍了SQL远程连接在Google计算引擎上不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个带有静态IP地址的google计算引擎,该引擎运行带有SQL Server 2012 Express的寡妇服务器2012. 我已按照此处 a>并设置Windows防火墙和Google防火墙,以允许端口1433上的连接.我还验证了SQL引擎正在运行. 我已经用telnet测试了端口连接,并且允许连接. 问题是我仍然无法连接到服务器. 错误:

I have a google compute engine with a static IP address running widows server 2012 with SQL server 2012 express. I have enabled SQL remote connections by following the instructions here and have setup windows firewall and google firewall to allow connections on port 1433. I also verified that SQL engine is running. I have tested the port connection with telnet and it's allowing the connection. The problem is that i still am not able to connect to the server. error:

与网络相关或特定于实例的错误发生在 建立连接..错误26错误定位服务器 指定

a network related or instance specific error occurred while establishing a connection .... error 26 error locating server specified

这是我使用的连接字符串

Here's the connection string im using

数据源= IP地址\ SQLEXPRESS;数据库= dbname;用户ID = xyz;密码= 123;"

"Data Source=IP Address\SQLEXPRESS;Database=dbname;User Id=xyz;Password=123;"

用户发布了相同的问题这里,但是我可以通过telnet服务器. 在使用AWS服务器之前,我已经使用了相同的步骤,并且一切正常.谷歌计算服务器还有其他步骤吗?

A user posted the same question here but i am able to telnet my server. I have used the same steps before with a AWS server and everything worked perfect. Is there other steps that have to be done with a google compute server ?

推荐答案

我在连接字符串中有错误. 我最终切换到Amazon AWS服务器,以下连接字符串有效.

I had an error in the connection string. I ended up switching to Amazon AWS servers and the following connection string works.

"Data Source=ec2-00-000-00-000.compute-1.amazonaws.com,PORT#;Database=test;User Id=xyz;Password=1234;"

这篇关于SQL远程连接在Google计算引擎上不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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