PaulieORF Posted October 22, 2004 Posted October 22, 2004 I would like to connect to a SQL Server database over the internet from a Visual Basic .NET 2003 application. I've looked around on the internet, but nothing I find cant help me. I am using a router, and for the time being I've turned off all of the firewall features. I've also set DMZ to the server's local IP. Now, using SQL Enterprise Manager, I am able to connect to the server via the local private IP address, but when I try to use my static IP (exposed to the internet) I cannot connect. Does anyone know why this is happening, and what I can do to get it working? Thanks! Quote
Administrators PlausiblyDamp Posted October 22, 2004 Administrators Posted October 22, 2004 You will need to forward the correct TCP port from the router to the SQL box (1434 by default). However this is probably a very dangerous practice as it will potentially open your SQL box up to the internet in general. Is there a particular reason you need to give access in this manner. Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
PaulieORF Posted October 22, 2004 Author Posted October 22, 2004 You will need to forward the correct TCP port from the router to the SQL box (1434 by default). However this is probably a very dangerous practice as it will potentially open your SQL box up to the internet in general. Is there a particular reason you need to give access in this manner. The reason I want to do this is because I'm writing an application for a project that I'm doing for a class in school. I would like to be able to install the application in school, and be able to connect to my SQL Server database over the internet, from my server running at home. So, I'm not all that concerned about it being exposed to the internet, since I would only have it up and running for just a few hours. Anyway, what is the deal with the ports? I've read in many places that 1433 is the port I need to forward, what's this about 1434? Do I have to forward both of these ports? Thanks. Quote
Administrators PlausiblyDamp Posted October 22, 2004 Administrators Posted October 22, 2004 Sorry 1433 is the correct port, my bad. Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
PaulieORF Posted October 23, 2004 Author Posted October 23, 2004 So what exactly am I doing wrong? Quote
PaulieORF Posted October 25, 2004 Author Posted October 25, 2004 **BUMP** So can anyone help me with this? Quote
stustarz Posted October 25, 2004 Posted October 25, 2004 Well in my experience it has always come down to a router or firewall issue. You may have already checked this but is the TCP port correctly configured on your sql server: Right click the server you are trying to broadcast, on the properties page go to the General tab and click the button at the bottom: Network Configuration. In there you should see on the right hand side the TCP/IP settings ensure the port matches the port you want to broadcast on and that the 'hide server' check is not true. Also, when connecting to the server, are you specifically referencing the port number? if you just use the IP your app might be trying to connect on port 80 (the default http port). Another idea that ive just had: in the sql server error log, there will be a line saying something like: sql server name succesfully broadcasting on port 1433 - check this appears. - just some ideas, sorry if youve checked all this already. Quote Visit: VBSourceSeek - The VB.NET sourcecode library "A mere friend will agree with you, but a real friend will argue."
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.