How to check the port number for SQL Server?
There are several ways to check the port number of SQL Server.
- View through the SQL Server configuration tool:
- Open up the SQL Server Configuration Manager.
- Select SQL Server network configuration from the left-side navigation pane.
- Choose the corresponding instance in the right window, then locate the IP address and port number under the TCP/IP node.
- View through SQL Server Management Studio (SSMS):
- Open SSMS and connect to the SQL Server instance.
- Right-click on the server name and choose Properties.
- Select the link in the left navigation bar, then locate the port number in the window on the right.
- View through the query system:
- Find the port number in the SQL Server instance using the following query: SELECT DISTINCT local_net_address, local_tcp_port
FROM sys.dm_exec_connections
WHERE local_tcp_port IS NOT NULL - This will return the port number currently being used by SQL Server.