Sql connection string

broken image

Everything will be the same, but the IP’s are different – and bam, the application fails. There are times when we’ll airlift an entire application and drop it somewhere else. It’s impossible to make a fake IP address point to one in another subnet, especially if the server is being physically moved.ĭisaster recovery is a great example, and performance testing offsite is another. While server names can also change, it’s easy to make fake DNS entries for an old server name that points to the new name.

broken image

Īs a guy who’s lived through more than one IP address renumbering disaster, please believe me when I say you should never do that. If you are running a cluster, use the virtual SQL Server IP address. A server’s IP address can be used to specify either a default or named instance of a server running SQL Server.

By using an IP address instead of a DNS name, name resolution does not have to occur, reducing the amount of time it takes for a connection to be made. When you specify a server in an ADO.NET connection string, use the server’s IP address, not the server’s DNS name. In today’s SQL newsletter from I was horrified to find the following tip:

broken image