Including port numbers in% systemroot% \ system32 \ drivers \ etc \ hosts File

Can I include port numbers in the hosts file? The reason I'm asking for is because I have sites that I'm trying to switch from one hosting server to another, and the sites point to an old SQL server that uses the standard TCP / IP port (1433). On the new server, the SQL Server port is different, and I do not want to change the connection strings for these sites.

Thanks!

+5
source share
5 answers

You can configure an alias in the SQL configuration management tool. Designed to cover just this scenario.

+6

. DNS .

+11

hosts IP- ( ). .

+2

, , .

0

-, , : hosts:

xxx.xxx.xxx.xxx  MyServer

MyServer .

SQL Server 2005 " " , "Myserver, 1234", 1234 .

Since he remembers them in the fall the next time, that was enough for me.

0
source

All Articles