Solved

Connect to MS SQL on different subnet

Posted on 2004-10-11
8
1,202 Views
Last Modified: 2008-02-26
I have a remote hosting environment which includes two machines - a web server and an ms sql server. The sql machine uses an internal IP 192.168.0.10 and the web server has a real IP as well as an internal IP (used to connect to sql server). Using this setup its not possible to ping or connect to the sql machine remotly. Is it possible to somehow setup a way to connect to the sql server via either Enterprise manager or Query Analyzer remotely?

If this is not possible is there any other way I can connect to it? I have full control of both machines so I can make any needed changes.
0
Comment
Question by:rot299
8 Comments
 
LVL 6

Expert Comment

by:mcp111
ID: 12283346
What happens when you try to register in Enterprise manager using IP 192.168.0.10
0
 
LVL 1

Author Comment

by:rot299
ID: 12283378
I didn't try because I know my remote machine (connected via the internet, not on the same network as the web and SQL server) will not find the internal IP. Sorry if I didn't make it clear that I want to connect to the sql box over the internet/remotley.
0
 
LVL 5

Assisted Solution

by:LlamaJoe
LlamaJoe earned 250 total points
ID: 12283466
If you are connecting remotely, then you have to give the SQL server an external IP...  

or, install sql on the web box and setup a linked server to your SQL box - then connect to the Web box and use the linked server as a means to connect...

or, specify a random port north of 2000 on the Web box to be forwarded to port 1433 on the sql box, then use the client network utility on your remote machine to create an alias to this new port on the Web box and connect through the alias.(this is much easier if you have a router between the web box and the internet)

or, download the SQL Server Web Data Administrator and see if that will work on your web box... (this is enterprise manager with a web front end)
http://www.microsoft.com/downloads/details.aspx?FamilyID=C039A798-C57A-419E-ACBC-2A332CB7F959&displaylang=en

or, run terminal services on your web box and then connect

or, create a vpn connection to your web box and then your remote machine is part of that network...

or, or, or... lots of options still can be dreamt of.  It really depends on the setup of your network and what pieces are available to be mucked with.
0
 
LVL 1

Author Comment

by:rot299
ID: 12283709
I currently do connect to the sql box by connecting via terminal to the web box then accessing the sql box but wanted a more direct method. I like the idea of forwarding a port on the web box to the sql box. I will try this out.

Thanks for the info

0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 34

Accepted Solution

by:
arbert earned 250 total points
ID: 12283837
You don't have to give the SQL box and external IP address (in fact, I wouldn't recommend it).  However, you do need to be able to set up forwarding or NAT on your router/firewall to allow port 1433 to be routed to your SQL Server on the internal network.

Brett
0
 
LVL 1

Author Comment

by:rot299
ID: 12283998
Ok thanks. Can I setup the port forwarding on the web server machine or does this have to be done on the router? The only issue is that the router isn't mine although I can probably ask the owner to set the forwarding if there is no other way.

Do you have any links to information on how to set this up?
0
 
LVL 34

Expert Comment

by:arbert
ID: 12284220
You would want to set it up at the router.....

As far as how to do it, really depends on the router....Some call it port forwarding, some call it virtual servers, just depends....
0
 
LVL 1

Author Comment

by:rot299
ID: 12284233
Ok, well thanks for all the help.
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Convert column to int 13 27
Backup Job question 4 19
t-sql month question 8 42
SQL index creation taking an abnormally long time 2 18
Introduction SQL Server Integration Services can read XML files, that’s known by every BI developer.  (If you didn’t, don’t worry, I’m aiming this article at newcomers as well.) But how far can you go?  When does the XML Source component become …
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now