We help IT Professionals succeed at work.

SQL server 2005 port number (TcpPort)

yrcdba7
yrcdba7 asked
on

Experts,

I installed SQL server 2005, what TCP port number I should give to?  After I installed SQL 2005, the default TcpPort number is 1433. I also used 1433 in SQL server 2000 another production server. can I use the same TCP port number in both of SQL server 2000 and SQL server 2005?

Thank you,
Qiyi
Comment
Watch Question

Raja Jegan RSQL Server DBA & Architect, EE Solution Guide
Awarded 2009
Distinguished Expert 2018

Commented:
Yes, you can use the Default port 1433 but for Security reasons, its recommended to change the port to some other value..

>> can I use the same TCP port number in both of SQL server 2000 and SQL server 2005?

If both SQL Server 2000 and 2005 co-exists in a single machine, then you can't..
Both instances have to use different TCP/IP ports in order to work properly.
James MurrellProduct Specialist

Commented:
another point is to make sure you change any setting in your firewall programs

James

Author

Commented:
You mean one single sql server should have indivitual port number? I have three SQL server machines, all they used the same port number 1433. Is this correct?

I only set up TCP port number 1433 in firewall for SQL. is that something else I need to do in firewall? how?
Thank you,

jc
James MurrellProduct Specialist

Commented:
if all separate then its ok

if on same machine then they should be different ports

James
You can try the following script from Microsoft. It opened all the required ports for SQL and sorted out my SQL port issues completely. Also shows you all the ports SQL uses

http://support.microsoft.com/kb/839980

Just copy and paste the contents the script and then run it. Should sort you out
SQL Server DBA & Architect, EE Solution Guide
Awarded 2009
Distinguished Expert 2018
Commented:
>> I only set up TCP port number 1433 in firewall for SQL. is that something else I need to do in firewall? how?

If you are going to have Multiple instances of SQL Server in a single machine, then you need to exclude UDP Port 1434 in Windows Firewall and Start your SQL Server Browser Services..
Else it is ok.

>> You mean one single sql server should have indivitual port number? I have three SQL server machines, all they used the same port number 1433. Is this correct?

As mentioned by cs97jjm3 above, if you are going to have one instance of SQL Server in those three machines then opening same port 1433 should hold good.

But if you have two or more instances in a single machine, then you need to configure unique ports for all those three instances.