问题描述
我需要访问位于防火墙后面的计算机上的SQL Server,并且您使用95.95.95.33:6930这样的IP地址(而不是真实的IP地址)访问此计算机...但是,我明白了通过访问端口6930上的95.95.95.33,防火墙将请求路由到该特定计算机上。
I need to access an SQL Server that is on a machine behind a firewall and you access this machine using an ip address like 95.95.95.33:6930 (not the real ip address) ... But, you get my point that by accessing 95.95.95.33 on port 6930, the firewall routes the requests to that particular machine ...
我的问题是...如何构造与之连接的字符串访问位于地址95.95.95.33:6930的计算机,然后进一步访问端口1433或其他端口(例如8484)上的SQL Server ???
My question is ... How do you construct a connection string to access the machine at address 95.95.95.33:6930 and then further access the SQL Server on port 1433 or maybe a different port like 8484 ???
谢谢
迈克
推荐答案
那么,您就可以像这样构建连接字符串
well, you build the connection string like this
"Server=95.95.95.33,6930;database=mydb;..."
防火墙/ nat必须将其路由到SQL Server的正确机器/端口上。
the firewall/nat will have to route that to the correct machine/port of the SQL server for you.
这篇关于使用IP地址和端口号访问SQL Server ...帮助!的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!