

I also had this problem when trying to connect remotely via the Hamachi VPN. I'd check your account has appropriate login rights.
#Setting up mguard vpn tunnel windows#
If Windows Authentication, could your network be using Kerberos potentially? One would think the VPN credentials would be used for the handshake. If SQL Authentication (which I assume you are using given you said username and password), are you sure the SQL instance you're connecting to has mixed mode authentication enabled? If not, you have to connect as Administrator and change the default security settings to allow SQL authentication.

Are you using SQL Authentication or Windows (Domain) authentication? If you double click TCP/IP and hit the "Advanced" tab, you can also view the Port number. You can check that TCP/IP is enabled in the RHS window. You should have four options - Shared Memory, Named Pipes, TCP/IP and VIA. Start -> Programs -> SQL Server 200x -> Configuration Tools -> SQL Server Configuration ManagerĬonnect to the machine you need then expand the Tree Item (LHS) "SQL Server Network Configuration", then pick instance. To check SQL's network configuration (requires SQL Server Client Tools installed): Obviously port 1433 (or whatever port SQL is listening on) needs to be unblocked by any firewalls between your machine and the box SQL is running on. This will also help you to check/verify the port number the SQL instance is using (in case someone changed it from the default of port 1433). Make sure SQL Server is enabled for TCP/IP (someone may have disabled it)? That also could result in you being blocked. If all of those are correct, verify the server doesn't have an IPSEC policy that restricts access to the SQL Server port via IP address. If so, you'll need to check all the firewalls on your system. Some systems have multiple firewalls (my laptop is an example). If they are, as indicated, check your firewall settings. Then you'll need to get with your networking/security folks to determine if they allow communication to that port via VPN. What you'll need to determine is what port your SQL Server is listening on. If you have a named instance, you can configure a static port and if you have a need to use Kerberos authentication/delegation, you should.

That listens on UDP/1434 and cannot be changed. How clients usually find the right port in the case of a named instance is by talking to the SQL Server Listener Service/SQL Browser. What that means is should SQL Server discover that the port is in use, it will pick another TCP port. On a named instance, unless configured differently, SQL Server listens on a dynamic TCP port. On a default instance, SQL Server listens on TCP/1433 by default.
